1 // Copyright 2014 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_ANDROID_BANNERS_APP_BANNER_SETTINGS_HELPER_H_
6 #define CHROME_BROWSER_ANDROID_BANNERS_APP_BANNER_SETTINGS_HELPER_H_
10 #include "base/macros.h"
14 } // namesapce content
18 // Utility class for reading and updating ContentSettings for app banners.
19 class AppBannerSettingsHelper {
21 // Checks if a URL is allowed to show a banner for the given package.
22 static bool IsAllowed(content::WebContents* web_contents,
23 const GURL& origin_url,
24 const std::string& package_name);
26 // Blocks a URL from showing a banner for the given package.
27 static void Block(content::WebContents* web_contents,
28 const GURL& origin_url,
29 const std::string& package_name);
32 DISALLOW_COPY_AND_ASSIGN(AppBannerSettingsHelper);
35 #endif // CHROME_BROWSER_ANDROID_BANNERS_APP_BANNER_SETTINGS_HELPER_H_