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

Unified Diff: chrome/browser/ui/panels/panel_titlebar_view_cocoa.mm

Issue 9129013: Panel Overflow on Mac. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: cr feedback Created 8 years, 10 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
Index: chrome/browser/ui/panels/panel_titlebar_view_cocoa.mm
diff --git a/chrome/browser/ui/panels/panel_titlebar_view_cocoa.mm b/chrome/browser/ui/panels/panel_titlebar_view_cocoa.mm
index 31b1dfcb783f3d372dadaf64cd763825d04e1e18..c3ff9d4fba400b489f6a9ec2c062f300129bfc30 100644
--- a/chrome/browser/ui/panels/panel_titlebar_view_cocoa.mm
+++ b/chrome/browser/ui/panels/panel_titlebar_view_cocoa.mm
@@ -545,6 +545,14 @@ static NSEvent* MakeMouseEvent(NSEventType type,
}
}
+- (int)iconOnlyWidthInScreenCoordinates {
+ int width = kIconAndTextPadding * 2;
+ if (!icon_)
+ return width;
+
+ return width + NSWidth([self convertRect:[icon_ frame] toView:nil]);
+}
+
// (Private/TestingAPI)
- (PanelWindowControllerCocoa*)controller {
return controller_;

Powered by Google App Engine
This is Rietveld 408576698