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

Side by Side Diff: ui/views/widget/native_widget_mac.mm

Issue 2158653002: Linux UI: Add IsVisibleOnAllWorkspaces() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add more mac impls Created 4 years, 5 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 unified diff | Download patch
« no previous file with comments | « ui/views/widget/native_widget_mac.h ('k') | ui/views/widget/native_widget_private.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "ui/views/widget/native_widget_mac.h" 5 #include "ui/views/widget/native_widget_mac.h"
6 6
7 #import <Cocoa/Cocoa.h> 7 #import <Cocoa/Cocoa.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 445 matching lines...) Expand 10 before | Expand all | Expand 10 after
456 } 456 }
457 457
458 bool NativeWidgetMac::IsAlwaysOnTop() const { 458 bool NativeWidgetMac::IsAlwaysOnTop() const {
459 return gfx::IsNSWindowAlwaysOnTop(GetNativeWindow()); 459 return gfx::IsNSWindowAlwaysOnTop(GetNativeWindow());
460 } 460 }
461 461
462 void NativeWidgetMac::SetVisibleOnAllWorkspaces(bool always_visible) { 462 void NativeWidgetMac::SetVisibleOnAllWorkspaces(bool always_visible) {
463 gfx::SetNSWindowVisibleOnAllWorkspaces(GetNativeWindow(), always_visible); 463 gfx::SetNSWindowVisibleOnAllWorkspaces(GetNativeWindow(), always_visible);
464 } 464 }
465 465
466 bool NativeWidgetMac::IsVisibleOnAllWorkspaces() const {
467 return false;
468 }
469
466 void NativeWidgetMac::Maximize() { 470 void NativeWidgetMac::Maximize() {
467 NOTIMPLEMENTED(); // See IsMaximized(). 471 NOTIMPLEMENTED(); // See IsMaximized().
468 } 472 }
469 473
470 void NativeWidgetMac::Minimize() { 474 void NativeWidgetMac::Minimize() {
471 NSWindow* window = GetNativeWindow(); 475 NSWindow* window = GetNativeWindow();
472 // Calling performMiniaturize: will momentarily highlight the button, but 476 // Calling performMiniaturize: will momentarily highlight the button, but
473 // AppKit will reject it if there is no miniaturize button. 477 // AppKit will reject it if there is no miniaturize button.
474 if ([window styleMask] & NSMiniaturizableWindowMask) 478 if ([window styleMask] & NSMiniaturizableWindowMask)
475 [window performMiniaturize:nil]; 479 [window performMiniaturize:nil];
(...skipping 282 matching lines...) Expand 10 before | Expand all | Expand 10 after
758 [[ViewsNSWindowCloseAnimator alloc] initWithWindow:window]; 762 [[ViewsNSWindowCloseAnimator alloc] initWithWindow:window];
759 } 763 }
760 764
761 - (void)animationDidEnd:(NSAnimation*)animation { 765 - (void)animationDidEnd:(NSAnimation*)animation {
762 [window_ close]; 766 [window_ close];
763 [animation_ setDelegate:nil]; 767 [animation_ setDelegate:nil];
764 [self release]; 768 [self release];
765 } 769 }
766 770
767 @end 771 @end
OLDNEW
« no previous file with comments | « ui/views/widget/native_widget_mac.h ('k') | ui/views/widget/native_widget_private.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698