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

Side by Side Diff: chrome/browser/ui/cocoa/notifications/balloon_view.mm

Issue 10825447: chrome/browser should build on the x86_64 architecture (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Rebased on the updated trunk. Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "chrome/browser/ui/cocoa/notifications/balloon_view.h" 5 #include "chrome/browser/ui/cocoa/notifications/balloon_view.h"
6 6
7 #import <Cocoa/Cocoa.h> 7 #import <Cocoa/Cocoa.h>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/memory/scoped_nsobject.h" 10 #include "base/memory/scoped_nsobject.h"
11 #import "chrome/browser/ui/cocoa/notifications/balloon_controller.h" 11 #import "chrome/browser/ui/cocoa/notifications/balloon_controller.h"
12 #import "third_party/GTM/AppKit/GTMNSBezierPath+RoundRect.h" 12 #import "third_party/GTM/AppKit/GTMNSBezierPath+RoundRect.h"
13 13
14 namespace { 14 namespace {
15 15
16 const int kRoundedCornerSize = 6; 16 const int kRoundedCornerSize = 6;
17 17
18 } // namespace 18 } // namespace
19 19
20 @implementation BalloonWindow 20 @implementation BalloonWindow
21 - (id)initWithContentRect:(NSRect)contentRect 21 - (id)initWithContentRect:(NSRect)contentRect
22 styleMask:(unsigned int)aStyle 22 styleMask:(NSUInteger)aStyle
23 backing:(NSBackingStoreType)bufferingType 23 backing:(NSBackingStoreType)bufferingType
24 defer:(BOOL)flag { 24 defer:(BOOL)flag {
25 self = [super initWithContentRect:contentRect 25 self = [super initWithContentRect:contentRect
26 styleMask:NSBorderlessWindowMask 26 styleMask:NSBorderlessWindowMask
27 backing:NSBackingStoreBuffered 27 backing:NSBackingStoreBuffered
28 defer:NO]; 28 defer:NO];
29 // Using NSModalPanelWindowLevel (8) rather then NSStatusWindowLevel (25) 29 // Using NSModalPanelWindowLevel (8) rather then NSStatusWindowLevel (25)
30 // ensures notification balloons on top of regular windows, but below 30 // ensures notification balloons on top of regular windows, but below
31 // popup menus which are at NSPopUpMenuWindowLevel (101) and Spotlight 31 // popup menus which are at NSPopUpMenuWindowLevel (101) and Spotlight
32 // drop-out, which is at NSStatusWindowLevel-2 (23) for OSX 10.6/7. 32 // drop-out, which is at NSStatusWindowLevel-2 (23) for OSX 10.6/7.
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 - (void)mouseDown:(NSEvent*)event { 92 - (void)mouseDown:(NSEvent*)event {
93 [NSApp preventWindowOrdering]; 93 [NSApp preventWindowOrdering];
94 // Continue bubbling the event up the chain of responders. 94 // Continue bubbling the event up the chain of responders.
95 [super mouseDown:event]; 95 [super mouseDown:event];
96 } 96 }
97 97
98 - (BOOL)acceptsFirstMouse:(NSEvent*)event { 98 - (BOOL)acceptsFirstMouse:(NSEvent*)event {
99 return YES; 99 return YES;
100 } 100 }
101 @end 101 @end
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/history_overlay_controller.mm ('k') | third_party/mozilla/NSWorkspace+Utils.m » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698