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

Side by Side Diff: chrome/browser/cocoa/status_bubble_mac.mm

Issue 146043: Change status bubble so that it expands to accommodate URL's that are abridge... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 6 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
« no previous file with comments | « chrome/browser/cocoa/status_bubble_mac.h ('k') | chrome/browser/gtk/status_bubble_gtk.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 (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/cocoa/status_bubble_mac.h" 5 #include "chrome/browser/cocoa/status_bubble_mac.h"
6 6
7 #include "app/gfx/text_elider.h" 7 #include "app/gfx/text_elider.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "base/sys_string_conversions.h" 9 #include "base/sys_string_conversions.h"
10 #include "googleurl/src/gurl.h" 10 #include "googleurl/src/gurl.h"
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 offset_ = 0; 185 offset_ = 0;
186 [[window_ contentView] setStyle:STYLE_STANDARD]; 186 [[window_ contentView] setStyle:STYLE_STANDARD];
187 [window_ setFrame:window_frame display:YES]; 187 [window_ setFrame:window_frame display:YES];
188 } 188 }
189 } 189 }
190 190
191 void StatusBubbleMac::UpdateDownloadShelfVisibility(bool visible) { 191 void StatusBubbleMac::UpdateDownloadShelfVisibility(bool visible) {
192 NOTIMPLEMENTED(); 192 NOTIMPLEMENTED();
193 } 193 }
194 194
195 void StatusBubbleMac::SetBubbleWidth(int width) {
196 NOTIMPLEMENTED();
197 }
198
195 void StatusBubbleMac::Create() { 199 void StatusBubbleMac::Create() {
196 if (window_) 200 if (window_)
197 return; 201 return;
198 202
199 NSRect rect = [parent_ frame]; 203 NSRect rect = [parent_ frame];
200 rect.size.height = kWindowHeight; 204 rect.size.height = kWindowHeight;
201 rect.size.width = static_cast<int>(kWindowWidthPercent * rect.size.width); 205 rect.size.width = static_cast<int>(kWindowWidthPercent * rect.size.width);
202 // TODO(avi):fix this for RTL 206 // TODO(avi):fix this for RTL
203 window_ = [[NSWindow alloc] initWithContentRect:rect 207 window_ = [[NSWindow alloc] initWithContentRect:rect
204 styleMask:NSBorderlessWindowMask 208 styleMask:NSBorderlessWindowMask
(...skipping 115 matching lines...) Expand 10 before | Expand all | Expand 10 after
320 324
321 NSDictionary* textDict = [NSDictionary dictionaryWithObjectsAndKeys: 325 NSDictionary* textDict = [NSDictionary dictionaryWithObjectsAndKeys:
322 textFont, NSFontAttributeName, 326 textFont, NSFontAttributeName,
323 textShadow, NSShadowAttributeName, 327 textShadow, NSShadowAttributeName,
324 nil]; 328 nil];
325 [content_ drawAtPoint:NSMakePoint(kTextPositionX, kTextPositionY) 329 [content_ drawAtPoint:NSMakePoint(kTextPositionX, kTextPositionY)
326 withAttributes:textDict]; 330 withAttributes:textDict];
327 } 331 }
328 332
329 @end 333 @end
OLDNEW
« no previous file with comments | « chrome/browser/cocoa/status_bubble_mac.h ('k') | chrome/browser/gtk/status_bubble_gtk.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698