Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7422)

Unified Diff: chrome/browser/ui/views/desktop_capture/desktop_media_picker_views.cc

Issue 2785683003: views: implement width snapping for DialogDelegateViews (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/desktop_capture/desktop_media_picker_views.cc
diff --git a/chrome/browser/ui/views/desktop_capture/desktop_media_picker_views.cc b/chrome/browser/ui/views/desktop_capture/desktop_media_picker_views.cc
index 8667fee5fdbdefa0deff8ac226903beb92c52267..a129926d59b75be98b2d44f346ca1f533f36be0d 100644
--- a/chrome/browser/ui/views/desktop_capture/desktop_media_picker_views.cc
+++ b/chrome/browser/ui/views/desktop_capture/desktop_media_picker_views.cc
@@ -274,15 +274,15 @@ void DesktopMediaPickerDialogView::DetachParent() {
parent_ = nullptr;
}
-gfx::Size DesktopMediaPickerDialogView::GetPreferredSize() const {
- static const size_t kDialogViewWidth = 600;
- return gfx::Size(kDialogViewWidth, GetHeightForWidth(kDialogViewWidth));
-}
-
ui::ModalType DesktopMediaPickerDialogView::GetModalType() const {
return ui::MODAL_TYPE_CHILD;
}
+gfx::Size DesktopMediaPickerDialogView::GetUnsnappedPreferredSize() const {
+ static const size_t kDialogViewWidth = 600;
Peter Kasting 2017/03/30 00:35:34 Another case that needs a bug in the spreadsheet a
+ return gfx::Size(kDialogViewWidth, GetHeightForWidth(kDialogViewWidth));
+}
+
base::string16 DesktopMediaPickerDialogView::GetWindowTitle() const {
return l10n_util::GetStringUTF16(IDS_DESKTOP_MEDIA_PICKER_TITLE);
}

Powered by Google App Engine
This is Rietveld 408576698