OLD | NEW |
---|---|
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 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_DESKTOP_MEDIA_PICKER_VIEWS_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_DESKTOP_MEDIA_PICKER_VIEWS_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_DESKTOP_MEDIA_PICKER_VIEWS_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_DESKTOP_MEDIA_PICKER_VIEWS_H_ |
7 | 7 |
8 #include "chrome/browser/media/desktop_media_list_observer.h" | 8 #include "chrome/browser/media/desktop_media_list_observer.h" |
9 #include "chrome/browser/media/desktop_media_picker.h" | 9 #include "chrome/browser/media/desktop_media_picker.h" |
10 #include "ui/views/window/dialog_delegate.h" | 10 #include "ui/views/window/dialog_delegate.h" |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
111 class DesktopMediaPickerDialogView : public views::DialogDelegateView { | 111 class DesktopMediaPickerDialogView : public views::DialogDelegateView { |
112 public: | 112 public: |
113 DesktopMediaPickerDialogView(content::WebContents* parent_web_contents, | 113 DesktopMediaPickerDialogView(content::WebContents* parent_web_contents, |
114 gfx::NativeWindow context, | 114 gfx::NativeWindow context, |
115 DesktopMediaPickerViews* parent, | 115 DesktopMediaPickerViews* parent, |
116 const base::string16& app_name, | 116 const base::string16& app_name, |
117 const base::string16& target_name, | 117 const base::string16& target_name, |
118 scoped_ptr<DesktopMediaList> media_list); | 118 scoped_ptr<DesktopMediaList> media_list); |
119 ~DesktopMediaPickerDialogView() override; | 119 ~DesktopMediaPickerDialogView() override; |
120 | 120 |
121 views::View* GetInitiallyFocusedView() override; | |
Peter Kasting
2015/09/23 22:43:57
This should be in the list of DialogDelegateView o
gyzhou
2015/09/23 23:43:40
This is an override for DialogDelegate
Done.
| |
122 | |
121 // Called by parent (DesktopMediaPickerViews) when it's destroyed. | 123 // Called by parent (DesktopMediaPickerViews) when it's destroyed. |
122 void DetachParent(); | 124 void DetachParent(); |
123 | 125 |
124 // Called by DesktopMediaListView. | 126 // Called by DesktopMediaListView. |
125 void OnSelectionChanged(); | 127 void OnSelectionChanged(); |
126 void OnDoubleClick(); | 128 void OnDoubleClick(); |
127 | 129 |
128 // views::View overrides. | 130 // views::View overrides. |
129 gfx::Size GetPreferredSize() const override; | 131 gfx::Size GetPreferredSize() const override; |
130 void Layout() override; | 132 void Layout() override; |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
178 | 180 |
179 // The |dialog_| is owned by the corresponding views::Widget instance. | 181 // The |dialog_| is owned by the corresponding views::Widget instance. |
180 // When DesktopMediaPickerViews is destroyed the |dialog_| is destroyed | 182 // When DesktopMediaPickerViews is destroyed the |dialog_| is destroyed |
181 // asynchronously by closing the widget. | 183 // asynchronously by closing the widget. |
182 DesktopMediaPickerDialogView* dialog_; | 184 DesktopMediaPickerDialogView* dialog_; |
183 | 185 |
184 DISALLOW_COPY_AND_ASSIGN(DesktopMediaPickerViews); | 186 DISALLOW_COPY_AND_ASSIGN(DesktopMediaPickerViews); |
185 }; | 187 }; |
186 | 188 |
187 #endif // CHROME_BROWSER_UI_VIEWS_DESKTOP_MEDIA_PICKER_VIEWS_H_ | 189 #endif // CHROME_BROWSER_UI_VIEWS_DESKTOP_MEDIA_PICKER_VIEWS_H_ |
OLD | NEW |