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

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 trybot 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..a09b6a93deb30b4670ae6e9d9d5601f0937a18c4 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(Panel* panel) const = 0;
+
+ // Drags |panel| in the bounds of this strip.
+ virtual void StartDraggingPanel(Panel* panel) = 0;
+ // |delta_x| and |delta_y| are the offset from the last mouse position when
+ // DragPanel or StartDraggingPanel is called.
jennb 2012/02/16 22:31:00 Not sure I understand the comment because there's
jianli 2012/02/16 23:05:52 We only care about how much the mouse has been mov
+ virtual void DragPanel(int delta_x, int delta_y) = 0;
+ virtual void EndDraggingPanel(bool cancelled) = 0;
+
protected:
explicit PanelStrip(Type type);
virtual ~PanelStrip();

Powered by Google App Engine
This is Rietveld 408576698