| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_PERMISSION_SELECTOR_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_PERMISSION_SELECTOR_VIEW_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_PERMISSION_SELECTOR_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_PERMISSION_SELECTOR_VIEW_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 public: | 33 public: |
| 34 PermissionSelectorView(const GURL& url, | 34 PermissionSelectorView(const GURL& url, |
| 35 const WebsiteSettingsUI::PermissionInfo& permission); | 35 const WebsiteSettingsUI::PermissionInfo& permission); |
| 36 | 36 |
| 37 void AddObserver(PermissionSelectorViewObserver* observer); | 37 void AddObserver(PermissionSelectorViewObserver* observer); |
| 38 | 38 |
| 39 void PermissionChanged(const WebsiteSettingsUI::PermissionInfo& permission); | 39 void PermissionChanged(const WebsiteSettingsUI::PermissionInfo& permission); |
| 40 | 40 |
| 41 protected: | 41 protected: |
| 42 // Overridden from views::View. | 42 // Overridden from views::View. |
| 43 virtual void ChildPreferredSizeChanged(View* child) OVERRIDE; | 43 virtual void ChildPreferredSizeChanged(View* child) override; |
| 44 | 44 |
| 45 private: | 45 private: |
| 46 virtual ~PermissionSelectorView(); | 46 virtual ~PermissionSelectorView(); |
| 47 | 47 |
| 48 // Model for the permission's menu. | 48 // Model for the permission's menu. |
| 49 scoped_ptr<PermissionMenuModel> menu_model_; | 49 scoped_ptr<PermissionMenuModel> menu_model_; |
| 50 | 50 |
| 51 views::ImageView* icon_; // Owned by the views hierachy. | 51 views::ImageView* icon_; // Owned by the views hierachy. |
| 52 internal::PermissionMenuButton* menu_button_; // Owned by the views hierachy. | 52 internal::PermissionMenuButton* menu_button_; // Owned by the views hierachy. |
| 53 | 53 |
| 54 ObserverList<PermissionSelectorViewObserver, false> observer_list_; | 54 ObserverList<PermissionSelectorViewObserver, false> observer_list_; |
| 55 | 55 |
| 56 DISALLOW_COPY_AND_ASSIGN(PermissionSelectorView); | 56 DISALLOW_COPY_AND_ASSIGN(PermissionSelectorView); |
| 57 }; | 57 }; |
| 58 | 58 |
| 59 #endif // CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_PERMISSION_SELECTOR_VIEW_H_ | 59 #endif // CHROME_BROWSER_UI_VIEWS_WEBSITE_SETTINGS_PERMISSION_SELECTOR_VIEW_H_ |
| OLD | NEW |