OLD | NEW |
| (Empty) |
1 // Copyright (c) 2011 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. | |
4 | |
5 #ifndef CHROME_BROWSER_UI_GTK_OPTIONS_MANAGED_PREFS_BANNER_GTK_H_ | |
6 #define CHROME_BROWSER_UI_GTK_OPTIONS_MANAGED_PREFS_BANNER_GTK_H_ | |
7 #pragma once | |
8 | |
9 #include <gtk/gtk.h> | |
10 | |
11 #include "chrome/browser/policy/managed_prefs_banner_base.h" | |
12 | |
13 // Constructs and maintains a GTK widget displaying a warning banner. The banner | |
14 // is displayed on the preferences dialog whenever there are options that are | |
15 // not settable by the user due to policy. | |
16 class ManagedPrefsBannerGtk : public policy::ManagedPrefsBannerBase { | |
17 public: | |
18 ManagedPrefsBannerGtk(PrefService* prefs, OptionsPage page); | |
19 virtual ~ManagedPrefsBannerGtk() { } | |
20 | |
21 GtkWidget* banner_widget() { return banner_widget_; } | |
22 | |
23 protected: | |
24 // Update widget visibility. | |
25 virtual void OnUpdateVisibility(); | |
26 | |
27 private: | |
28 // Construct the widget. | |
29 void InitWidget(); | |
30 | |
31 GtkWidget* banner_widget_; | |
32 | |
33 DISALLOW_COPY_AND_ASSIGN(ManagedPrefsBannerGtk); | |
34 }; | |
35 | |
36 #endif // CHROME_BROWSER_UI_GTK_OPTIONS_MANAGED_PREFS_BANNER_GTK_H_ | |
OLD | NEW |