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

Unified Diff: chrome/browser/ui/cocoa/panels/panel_window_controller_cocoa.h

Issue 23918002: Switch to doing user-resizing via system for panels on Mac (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Patch Created 7 years, 3 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/cocoa/panels/panel_window_controller_cocoa.h
diff --git a/chrome/browser/ui/cocoa/panels/panel_window_controller_cocoa.h b/chrome/browser/ui/cocoa/panels/panel_window_controller_cocoa.h
index 6627170482f46b3f2fb0e77f78d008d6e7287c67..601dda1da8d169a392f903eefa373c79a78c5c40 100644
--- a/chrome/browser/ui/cocoa/panels/panel_window_controller_cocoa.h
+++ b/chrome/browser/ui/cocoa/panels/panel_window_controller_cocoa.h
@@ -15,6 +15,7 @@
#include "base/memory/scoped_ptr.h"
#import "chrome/browser/ui/cocoa/chrome_browser_window.h"
#include "chrome/browser/ui/panels/panel.h"
+#import "ui/base/cocoa/tracking_area.h"
class PanelCocoa;
@class PanelTitlebarViewCocoa;
@@ -42,12 +43,16 @@ class PanelCocoa;
// window over other application windows due to panels having a higher
// priority NSWindowLevel, so we distinguish between the two scenarios.
BOOL activationRequestedByPanel_;
- base::scoped_nsobject<NSView> overlayView_;
+
+ BOOL userResizing_;
+ ui::ScopedCrTrackingArea trackingArea_;
}
// Load the window nib and do any Cocoa-specific initialization.
- (id)initWithPanel:(PanelCocoa*)window;
+- (Panel*)panel;
+
- (void)webContentsInserted:(content::WebContents*)contents;
- (void)webContentsDetached:(content::WebContents*)contents;
@@ -134,8 +139,9 @@ class PanelCocoa;
// Adjusts NSWindowCollectionBehavior based on whether panel is always on top.
- (void)updateWindowCollectionBehavior;
-// Turns on user-resizable corners/sides indications and enables live resize.
-- (void)enableResizeByMouse:(BOOL)enable;
+// Updates the tracking area per the window size change. This is needed in
+// order to receive the NSMouseMoved notification.
+- (void)updateTrackingArea;
// Turns on/off shadow effect around the window shape.
- (void)showShadow:(BOOL)show;

Powered by Google App Engine
This is Rietveld 408576698