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

Unified Diff: chrome/browser/ui/panels/panel_strip.h

Issue 9403035: Refactor intra-strip panel drags by introducing PanelDragController. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix per 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_strip.h
diff --git a/chrome/browser/ui/panels/panel_strip.h b/chrome/browser/ui/panels/panel_strip.h
index 7cd7f875c4d119ae31ccba5e62764a2890eaada4..30d4ca3f812c9a6ee25b8ce5873627731761de87 100644
--- a/chrome/browser/ui/panels/panel_strip.h
+++ b/chrome/browser/ui/panels/panel_strip.h
@@ -62,6 +62,16 @@ class PanelStrip {
virtual void MinimizePanel(Panel* panel) = 0;
virtual void RestorePanel(Panel* panel) = 0;
+ // Returns true if |panel| is draggable.
+ virtual bool CanDragPanel(const Panel* panel) const = 0;
+
+ // Drags |panel| in the bounds of this strip.
+ virtual void StartDraggingPanel(Panel* panel) = 0;
+ // |delta_x| and |delta_y| denotes how much the mouse has been moved since
+ // last time when DragPanel or StartDraggingPanel is called.
+ virtual void DragPanel(Panel* panel, int delta_x, int delta_y) = 0;
+ virtual void EndDraggingPanel(Panel* panel, bool cancelled) = 0;
+
protected:
explicit PanelStrip(Type type);
virtual ~PanelStrip();

Powered by Google App Engine
This is Rietveld 408576698