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

Unified Diff: ui/views/widget/native_widget_mac.mm

Issue 1291763005: [MacViews] Use NSTitledWindowMask for window modal dialogs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/widget/native_widget_mac.mm
diff --git a/ui/views/widget/native_widget_mac.mm b/ui/views/widget/native_widget_mac.mm
index c5546ea187898ce84721791b8be94accbd550ab0..067e9ea461b1fc4574c82dda9b701b4ac6bcba77 100644
--- a/ui/views/widget/native_widget_mac.mm
+++ b/ui/views/widget/native_widget_mac.mm
@@ -38,6 +38,11 @@ namespace views {
namespace {
NSInteger StyleMaskForParams(const Widget::InitParams& params) {
+ // If the widget is modal, it will be displayed as a sheet. This only works
tapted 2015/08/19 09:02:14 nit: widget -> Widget (and perhaps "only works" ->
jackhou1 2015/08/20 00:01:36 Done.
+ // if it has NSTitledWindowMask.
tapted 2015/08/19 09:02:14 nit: perhaps worth adding "(e.g. with NSBorderless
jackhou1 2015/08/20 00:01:36 Done.
+ if (params.delegate->GetModalType() == ui::MODAL_TYPE_WINDOW)
tapted 2015/08/19 09:02:14 params.delegate && ... (params.delegate can be n
jackhou1 2015/08/20 00:01:36 Done.
+ return NSTitledWindowMask;
+
// TODO(tapted): Determine better masks when there are use cases for it.
if (params.remove_standard_frame)
return NSBorderlessWindowMask;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698