Small style fix

This commit is contained in:
Cheng Zhao 2015-11-20 13:06:42 +08:00
parent c1d6d68783
commit 8e2faba8f7
2 changed files with 9 additions and 11 deletions

View file

@ -259,14 +259,12 @@ bool ScopedDisableResize::disable_resize_ = false;
return [children filteredArrayUsingPredicate:predicate];
}
- (BOOL)canBecomeMainWindow
{
return !self.disableKeyOrMainWindow;
- (BOOL)canBecomeMainWindow {
return !self.disableKeyOrMainWindow;
}
- (BOOL)canBecomeKeyWindow
{
return !self.disableKeyOrMainWindow;
- (BOOL)canBecomeKeyWindow {
return !self.disableKeyOrMainWindow;
}
@end
@ -394,7 +392,7 @@ NativeWindowMac::NativeWindowMac(
if (windowType == "desktop") {
[window_ setLevel:kCGDesktopWindowLevel - 1];
[window_ setDisableKeyOrMainWindow: YES];
[window_ setDisableKeyOrMainWindow:YES];
[window_ setCollectionBehavior:
(NSWindowCollectionBehaviorCanJoinAllSpaces |
NSWindowCollectionBehaviorStationary |

View file

@ -71,11 +71,11 @@ It creates a new `BrowserWindow` with native properties as set by the `options`.
* On Linux, possible types are `desktop`, `dock`, `toolbar`, `splash`,
`notification`.
* On OS X, possible types are `desktop`, `textured`. The `textured` type adds
metal gradient appearance (NSTexturedBackgroundWindowMask). The `desktop`
metal gradient appearance (`NSTexturedBackgroundWindowMask`). The `desktop`
type places the window at the desktop background window level
(kCGDesktopWindowLevel - 1). Note that desktop window will not receive focus,
keyboard or mouse events, but you can use `globalShortcut` to receive input
sparingly.
(`kCGDesktopWindowLevel - 1`). Note that desktop window will not receive
focus, keyboard or mouse events, but you can use `globalShortcut` to receive
input sparingly.
* `titleBarStyle` String, OS X - specifies the style of window title bar.
This option is supported on OS X 10.10 Yosemite and newer. There are three
possible values: