Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 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 | 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_CONTENT_SETTING_BUBBLE_CONTENTS_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_CONTENT_SETTING_BUBBLE_CONTENTS_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_CONTENT_SETTING_BUBBLE_CONTENTS_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_CONTENT_SETTING_BUBBLE_CONTENTS_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| 11 #include "base/macros.h" | 11 #include "base/macros.h" |
| 12 #include "components/content_settings/core/common/content_settings_types.h" | 12 #include "components/content_settings/core/common/content_settings_types.h" |
| 13 #include "content/public/browser/web_contents_observer.h" | 13 #include "content/public/browser/web_contents_observer.h" |
| 14 #include "content/public/common/media_stream_request.h" | 14 #include "content/public/common/media_stream_request.h" |
| 15 #include "ui/views/bubble/bubble_delegate.h" | 15 #include "ui/views/bubble/bubble_delegate.h" |
| 16 #include "ui/views/controls/button/button.h" | 16 #include "ui/views/controls/button/button.h" |
| 17 #include "ui/views/controls/button/menu_button_listener.h" | 17 #include "ui/views/controls/button/menu_button_listener.h" |
| 18 #include "ui/views/controls/link_listener.h" | 18 #include "ui/views/controls/link_listener.h" |
| 19 | 19 |
| 20 class ContentSettingBubbleModel; | 20 class ContentSettingBubbleModel; |
| 21 class ContentSettingMediaMenuModel; | 21 class ContentSettingMediaMenuModel; |
| 22 class Profile; | 22 class Profile; |
| 23 | 23 |
| 24 namespace chrome { | |
| 25 class ContentSettingBubbleViewsBridge; | |
| 26 } | |
| 27 | |
| 24 namespace ui { | 28 namespace ui { |
| 25 class SimpleMenuModel; | 29 class SimpleMenuModel; |
| 26 } | 30 } |
| 27 | 31 |
| 28 namespace views { | 32 namespace views { |
| 29 class LabelButton; | 33 class LabelButton; |
| 30 class MenuButton; | 34 class MenuButton; |
| 31 class MenuRunner; | 35 class MenuRunner; |
| 32 class RadioButton; | 36 class RadioButton; |
| 33 } | 37 } |
| (...skipping 27 matching lines...) Expand all Loading... | |
| 61 const std::string& label); | 65 const std::string& label); |
| 62 | 66 |
| 63 protected: | 67 protected: |
| 64 // views::BubbleDelegateView: | 68 // views::BubbleDelegateView: |
| 65 void Init() override; | 69 void Init() override; |
| 66 | 70 |
| 67 private: | 71 private: |
| 68 class Favicon; | 72 class Favicon; |
| 69 struct MediaMenuParts; | 73 struct MediaMenuParts; |
| 70 | 74 |
| 75 friend class chrome::ContentSettingBubbleViewsBridge; | |
|
tapted
2016/01/12 22:02:42
nit: it's subtle why this is needed. Although it r
Elly Fong-Jones
2016/01/13 16:44:09
Done.
| |
| 76 | |
| 71 typedef std::map<views::Link*, int> ListItemLinks; | 77 typedef std::map<views::Link*, int> ListItemLinks; |
| 72 typedef std::map<views::MenuButton*, MediaMenuParts*> MediaMenuPartsMap; | 78 typedef std::map<views::MenuButton*, MediaMenuParts*> MediaMenuPartsMap; |
| 73 | 79 |
| 74 // content::WebContentsObserver: | 80 // content::WebContentsObserver: |
| 75 void DidNavigateMainFrame( | 81 void DidNavigateMainFrame( |
| 76 const content::LoadCommittedDetails& details, | 82 const content::LoadCommittedDetails& details, |
| 77 const content::FrameNavigateParams& params) override; | 83 const content::FrameNavigateParams& params) override; |
| 78 | 84 |
| 79 // views::ButtonListener: | 85 // views::ButtonListener: |
| 80 void ButtonPressed(views::Button* sender, const ui::Event& event) override; | 86 void ButtonPressed(views::Button* sender, const ui::Event& event) override; |
| (...skipping 20 matching lines...) Expand all Loading... | |
| 101 views::Link* manage_link_; | 107 views::Link* manage_link_; |
| 102 views::Link* learn_more_link_; | 108 views::Link* learn_more_link_; |
| 103 views::LabelButton* close_button_; | 109 views::LabelButton* close_button_; |
| 104 scoped_ptr<views::MenuRunner> menu_runner_; | 110 scoped_ptr<views::MenuRunner> menu_runner_; |
| 105 MediaMenuPartsMap media_menus_; | 111 MediaMenuPartsMap media_menus_; |
| 106 | 112 |
| 107 DISALLOW_IMPLICIT_CONSTRUCTORS(ContentSettingBubbleContents); | 113 DISALLOW_IMPLICIT_CONSTRUCTORS(ContentSettingBubbleContents); |
| 108 }; | 114 }; |
| 109 | 115 |
| 110 #endif // CHROME_BROWSER_UI_VIEWS_CONTENT_SETTING_BUBBLE_CONTENTS_H_ | 116 #endif // CHROME_BROWSER_UI_VIEWS_CONTENT_SETTING_BUBBLE_CONTENTS_H_ |
| OLD | NEW |