| 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_CAPTURE_DESKTOP_MEDIA_PICKER_VIEWS_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_DESKTOP_CAPTURE_DESKTOP_MEDIA_PICKER_VIEWS_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_DESKTOP_CAPTURE_DESKTOP_MEDIA_PICKER_VIEWS_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_DESKTOP_CAPTURE_DESKTOP_MEDIA_PICKER_VIEWS_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "chrome/browser/media/desktop_media_picker.h" | 9 #include "chrome/browser/media/desktop_media_picker.h" |
| 10 #include "ui/views/controls/label.h" | 10 #include "ui/views/controls/label.h" |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 61 | 61 |
| 62 void OnMediaListRowsChanged(); | 62 void OnMediaListRowsChanged(); |
| 63 | 63 |
| 64 DesktopMediaListView* GetMediaListViewForTesting() const; | 64 DesktopMediaListView* GetMediaListViewForTesting() const; |
| 65 DesktopMediaSourceView* GetMediaSourceViewForTesting(int index) const; | 65 DesktopMediaSourceView* GetMediaSourceViewForTesting(int index) const; |
| 66 views::Checkbox* GetCheckboxForTesting() const; | 66 views::Checkbox* GetCheckboxForTesting() const; |
| 67 int GetIndexOfSourceTypeForTesting( | 67 int GetIndexOfSourceTypeForTesting( |
| 68 content::DesktopMediaID::Type source_type) const; | 68 content::DesktopMediaID::Type source_type) const; |
| 69 views::TabbedPane* GetPaneForTesting() const; | 69 views::TabbedPane* GetPaneForTesting() const; |
| 70 | 70 |
| 71 static const int kThumbnailWidth = 160; | |
| 72 static const int kThumbnailHeight = 100; | |
| 73 static const int kThumbnailMargin = 10; | |
| 74 static const int kLabelHeight = 40; | |
| 75 static const int kListItemWidth = kThumbnailMargin * 2 + kThumbnailWidth; | |
| 76 static const int kListItemHeight = | |
| 77 kThumbnailMargin * 2 + kThumbnailHeight + kLabelHeight; | |
| 78 static const int kListColumns = 3; | |
| 79 static const int kTotalListWidth = kListColumns * kListItemWidth; | |
| 80 | |
| 81 private: | 71 private: |
| 82 void SwitchSourceType(int index); | 72 void SwitchSourceType(int index); |
| 83 | 73 |
| 84 DesktopMediaPickerViews* parent_; | 74 DesktopMediaPickerViews* parent_; |
| 85 | 75 |
| 86 views::Label* description_label_; | 76 views::Label* description_label_; |
| 87 | 77 |
| 88 views::Checkbox* audio_share_checkbox_; | 78 views::Checkbox* audio_share_checkbox_; |
| 89 | 79 |
| 90 views::TabbedPane* pane_; | 80 views::TabbedPane* pane_; |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 | 113 |
| 124 // The |dialog_| is owned by the corresponding views::Widget instance. | 114 // The |dialog_| is owned by the corresponding views::Widget instance. |
| 125 // When DesktopMediaPickerViews is destroyed the |dialog_| is destroyed | 115 // When DesktopMediaPickerViews is destroyed the |dialog_| is destroyed |
| 126 // asynchronously by closing the widget. | 116 // asynchronously by closing the widget. |
| 127 DesktopMediaPickerDialogView* dialog_; | 117 DesktopMediaPickerDialogView* dialog_; |
| 128 | 118 |
| 129 DISALLOW_COPY_AND_ASSIGN(DesktopMediaPickerViews); | 119 DISALLOW_COPY_AND_ASSIGN(DesktopMediaPickerViews); |
| 130 }; | 120 }; |
| 131 | 121 |
| 132 #endif // CHROME_BROWSER_UI_VIEWS_DESKTOP_CAPTURE_DESKTOP_MEDIA_PICKER_VIEWS_H_ | 122 #endif // CHROME_BROWSER_UI_VIEWS_DESKTOP_CAPTURE_DESKTOP_MEDIA_PICKER_VIEWS_H_ |
| OLD | NEW |