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

Unified Diff: ash/wm/workspace/frame_maximize_button.h

Issue 10825327: Adding unit tests for maximize menu (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 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: ash/wm/workspace/frame_maximize_button.h
diff --git a/ash/wm/workspace/frame_maximize_button.h b/ash/wm/workspace/frame_maximize_button.h
index 4c55da17c9dc5ef37d0c79d8f130d462ba295a5a..8c6693a6c5132d39113df04d47bc6a16f540ed3c 100644
--- a/ash/wm/workspace/frame_maximize_button.h
+++ b/ash/wm/workspace/frame_maximize_button.h
@@ -63,6 +63,17 @@ class ASH_EXPORT FrameMaximizeButton : public views::ImageButton,
virtual ui::GestureStatus OnGestureEvent(
const views::GestureEvent& event) OVERRIDE;
+ // Unit test overwrite: Change the UI delay used for the bubble show up.
+ void set_bubble_appearance_delay_ms(int bubble_appearance_delay_ms) {
+ bubble_appearance_delay_ms_ = bubble_appearance_delay_ms;
+ }
+
+ // Unit test accessor for the maximize bubble.
+ MaximizeBubbleController* maximizer() { return maximizer_.get(); }
+
+ // Unit test to see if phantom window is open.
+ bool phantom_window_open() { return phantom_window_.get() != NULL; }
+
private:
class EscapeEventFilter;
@@ -136,6 +147,9 @@ class ASH_EXPORT FrameMaximizeButton : public views::ImageButton,
scoped_ptr<MaximizeBubbleController> maximizer_;
+ // The delay of the bubble appearance.
+ int bubble_appearance_delay_ms_;
+
DISALLOW_COPY_AND_ASSIGN(FrameMaximizeButton);
};

Powered by Google App Engine
This is Rietveld 408576698