Switch global error menu icon to vectorized MD asset
[chromium-blink-merge.git] / chrome / browser / engagement / site_engagement_helper.h
blobc3883d5cf41a1363e67469f1c0e0bcf2d7635844
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #ifndef CHROME_BROWSER_ENGAGEMENT_SITE_ENGAGEMENT_HELPER_H_
6 #define CHROME_BROWSER_ENGAGEMENT_SITE_ENGAGEMENT_HELPER_H_
8 #include "base/macros.h"
9 #include "content/public/browser/web_contents_observer.h"
10 #include "content/public/browser/web_contents_user_data.h"
12 namespace content {
13 class WebContents;
16 class GURL;
18 // Per-WebContents class to handle updating the site engagement scores for
19 // origins as the user navigates.
20 class SiteEngagementHelper
21 : public content::WebContentsObserver,
22 public content::WebContentsUserData<SiteEngagementHelper> {
23 public:
24 ~SiteEngagementHelper() override;
26 private:
27 explicit SiteEngagementHelper(content::WebContents* web_contents);
28 friend class content::WebContentsUserData<SiteEngagementHelper>;
30 // content::WebContentsObserver overrides.
31 void DidStartNavigationToPendingEntry(
32 const GURL& url,
33 content::NavigationController::ReloadType reload_type) override;
35 DISALLOW_COPY_AND_ASSIGN(SiteEngagementHelper);
38 #endif // CHROME_BROWSER_ENGAGEMENT_SITE_ENGAGEMENT_HELPER_H_