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

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

Issue 8892020: Make Panel tests faster by reducing time intervals in tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years 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.cc
diff --git a/chrome/browser/ui/panels/panel_strip.cc b/chrome/browser/ui/panels/panel_strip.cc
index 976588a38d08bc63c53ee4c5dc4bf47d7776335c..27d5e1ba483dcede7125bad3261c6fcd77f34f60 100644
--- a/chrome/browser/ui/panels/panel_strip.cc
+++ b/chrome/browser/ui/panels/panel_strip.cc
@@ -142,7 +142,8 @@ void PanelStrip::AddPanel(Panel* panel) {
base::Bind(&PanelStrip::DelayedMovePanelToOverflow,
base::Unretained(this),
panel),
- kMoveNewPanelToOverflowDelayMilliseconds);
+ PanelManager::AdjustTimeInterval(
+ kMoveNewPanelToOverflowDelayMilliseconds));
}
#endif
panel->Initialize(gfx::Rect(x, y, width, height));
@@ -498,13 +499,9 @@ void PanelStrip::BringUpOrDownTitlebars(bool bring_up) {
// On some OSes, the interaction with native Taskbars/Docks may be improved
// if the panels do not go back to minimized state too fast. For example,
- // it makes it possible to hit the titlebar on OSX if Dock has Magnifying
- // enabled - the panels stay up for a while after Dock magnification effect
- // stops covering the panels.
- //
- // Another example would be taskbar in auto-hide mode on Linux. In this mode
- // taskbar will cover the panel in title hover mode, leaving it up for a few
- // seconds would allow the user to be able to click on it.
+ // with a taskbar in auto-hide mode, the taskbar will cover the panel in
+ // title-only mode which appears on hover. Leaving it up for a little longer
+ // would allow the user to be able to click on it.
//
// Currently, no platforms use both delays.
DCHECK(task_delay_milliseconds == 0);
@@ -523,7 +520,7 @@ void PanelStrip::BringUpOrDownTitlebars(bool bring_up) {
FROM_HERE,
base::Bind(&PanelStrip::DelayedBringUpOrDownTitlebarsCheck,
titlebar_action_factory_.GetWeakPtr()),
- task_delay_milliseconds);
+ PanelManager::AdjustTimeInterval(task_delay_milliseconds));
}
void PanelStrip::DelayedBringUpOrDownTitlebarsCheck() {
« no previous file with comments | « chrome/browser/ui/panels/panel_slide_animation.cc ('k') | chrome/browser/ui/panels/panel_window_controller_cocoa.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698