Chromium Code Reviews| 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 111 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 122 void DetachParent(); | 122 void DetachParent(); |
| 123 | 123 |
| 124 // Called by DesktopMediaListView. | 124 // Called by DesktopMediaListView. |
| 125 void OnSelectionChanged(); | 125 void OnSelectionChanged(); |
| 126 void OnDoubleClick(); | 126 void OnDoubleClick(); |
| 127 | 127 |
| 128 // views::View overrides. | 128 // views::View overrides. |
| 129 gfx::Size GetPreferredSize() const override; | 129 gfx::Size GetPreferredSize() const override; |
| 130 void Layout() override; | 130 void Layout() override; |
| 131 | 131 |
| 132 // views::DialogDelegate overrides. | |
| 133 views::View* GetInitiallyFocusedView() override; | |
|
Peter Kasting
2015/09/24 04:10:25
You don't directly subclass DialogDelegate; you ge
gyzhou
2015/10/02 18:51:26
Done.
| |
| 134 | |
| 132 // views::DialogDelegateView overrides. | 135 // views::DialogDelegateView overrides. |
| 133 ui::ModalType GetModalType() const override; | 136 ui::ModalType GetModalType() const override; |
| 134 base::string16 GetWindowTitle() const override; | 137 base::string16 GetWindowTitle() const override; |
| 135 bool IsDialogButtonEnabled(ui::DialogButton button) const override; | 138 bool IsDialogButtonEnabled(ui::DialogButton button) const override; |
| 136 base::string16 GetDialogButtonLabel(ui::DialogButton button) const override; | 139 base::string16 GetDialogButtonLabel(ui::DialogButton button) const override; |
| 137 bool Accept() override; | 140 bool Accept() override; |
| 138 void DeleteDelegate() override; | 141 void DeleteDelegate() override; |
| 139 | 142 |
| 140 void OnMediaListRowsChanged(); | 143 void OnMediaListRowsChanged(); |
| 141 | 144 |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 178 | 181 |
| 179 // The |dialog_| is owned by the corresponding views::Widget instance. | 182 // The |dialog_| is owned by the corresponding views::Widget instance. |
| 180 // When DesktopMediaPickerViews is destroyed the |dialog_| is destroyed | 183 // When DesktopMediaPickerViews is destroyed the |dialog_| is destroyed |
| 181 // asynchronously by closing the widget. | 184 // asynchronously by closing the widget. |
| 182 DesktopMediaPickerDialogView* dialog_; | 185 DesktopMediaPickerDialogView* dialog_; |
| 183 | 186 |
| 184 DISALLOW_COPY_AND_ASSIGN(DesktopMediaPickerViews); | 187 DISALLOW_COPY_AND_ASSIGN(DesktopMediaPickerViews); |
| 185 }; | 188 }; |
| 186 | 189 |
| 187 #endif // CHROME_BROWSER_UI_VIEWS_DESKTOP_MEDIA_PICKER_VIEWS_H_ | 190 #endif // CHROME_BROWSER_UI_VIEWS_DESKTOP_MEDIA_PICKER_VIEWS_H_ |
| OLD | NEW |