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

Side by Side Diff: ash/shelf/shelf_layout_manager_unittest.cc

Issue 2562413003: Changes threshold frequency for investigation (based on video in the bug) (Closed)
Patch Set: Changes threshold frequency for investigation (fxed a test and reworked math) Created 4 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 unified diff | Download patch
« no previous file with comments | « ash/common/shelf/wm_shelf.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ash/common/shelf/shelf_layout_manager.h" 5 #include "ash/common/shelf/shelf_layout_manager.h"
6 6
7 #include "ash/aura/wm_shelf_aura.h" 7 #include "ash/aura/wm_shelf_aura.h"
8 #include "ash/aura/wm_window_aura.h" 8 #include "ash/aura/wm_window_aura.h"
9 #include "ash/common/accelerators/accelerator_controller.h" 9 #include "ash/common/accelerators/accelerator_controller.h"
10 #include "ash/common/accelerators/accelerator_table.h" 10 #include "ash/common/accelerators/accelerator_table.h"
(...skipping 566 matching lines...) Expand 10 before | Expand all | Expand 10 after
577 // Swipe-up to hide. This should have no effect because there are no visible 577 // Swipe-up to hide. This should have no effect because there are no visible
578 // windows. 578 // windows.
579 end = below_start - delta; 579 end = below_start - delta;
580 generator.GestureScrollSequenceWithCallback( 580 generator.GestureScrollSequenceWithCallback(
581 below_start, end, kTimeDelta, kNumScrollSteps, 581 below_start, end, kTimeDelta, kNumScrollSteps,
582 base::Bind(&ShelfDragCallback::ProcessScroll, 582 base::Bind(&ShelfDragCallback::ProcessScroll,
583 base::Unretained(&handler))); 583 base::Unretained(&handler)));
584 EXPECT_EQ(SHELF_AUTO_HIDE, shelf->GetVisibilityState()); 584 EXPECT_EQ(SHELF_AUTO_HIDE, shelf->GetVisibilityState());
585 EXPECT_EQ(SHELF_AUTO_HIDE_SHOWN, shelf->GetAutoHideState()); 585 EXPECT_EQ(SHELF_AUTO_HIDE_SHOWN, shelf->GetAutoHideState());
586 EXPECT_EQ(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS, shelf->auto_hide_behavior()); 586 EXPECT_EQ(SHELF_AUTO_HIDE_BEHAVIOR_ALWAYS, shelf->auto_hide_behavior());
587
588 // Avoid a CHECK that makes sure SetAutoHideBehavior is not called too
589 // frequently. This is to help investigate http://crbug.com/665093 .
590 shelf->count_auto_hide_changes_ = 0;
587 } 591 }
588 592
589 // Need to be implemented. http://crbug.com/111279. 593 // Need to be implemented. http://crbug.com/111279.
590 #if defined(OS_WIN) 594 #if defined(OS_WIN)
591 #define MAYBE_SetVisible DISABLED_SetVisible 595 #define MAYBE_SetVisible DISABLED_SetVisible
592 #else 596 #else
593 #define MAYBE_SetVisible SetVisible 597 #define MAYBE_SetVisible SetVisible
594 #endif 598 #endif
595 // Makes sure SetVisible updates work area and widget appropriately. 599 // Makes sure SetVisible updates work area and widget appropriately.
596 TEST_F(ShelfLayoutManagerTest, MAYBE_SetVisible) { 600 TEST_F(ShelfLayoutManagerTest, MAYBE_SetVisible) {
(...skipping 1248 matching lines...) Expand 10 before | Expand all | Expand 10 after
1845 // Open keyboard in sticky mode. 1849 // Open keyboard in sticky mode.
1846 kb_controller->ShowKeyboard(true); 1850 kb_controller->ShowKeyboard(true);
1847 layout_manager->OnKeyboardBoundsChanging(keyboard_bounds()); 1851 layout_manager->OnKeyboardBoundsChanging(keyboard_bounds());
1848 1852
1849 // Work area should be changed. 1853 // Work area should be changed.
1850 EXPECT_NE(orig_work_area, 1854 EXPECT_NE(orig_work_area,
1851 display::Screen::GetScreen()->GetPrimaryDisplay().work_area()); 1855 display::Screen::GetScreen()->GetPrimaryDisplay().work_area());
1852 } 1856 }
1853 1857
1854 } // namespace ash 1858 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/shelf/wm_shelf.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698