| OLD | NEW |
| 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 "base/i18n/time_formatting.h" | 5 #include "base/i18n/time_formatting.h" |
| 6 #include "base/memory/scoped_ptr.h" | 6 #include "base/memory/scoped_ptr.h" |
| 7 #include "chrome/browser/extensions/extension_service.h" | 7 #include "chrome/browser/extensions/extension_service.h" |
| 8 #include "chrome/browser/profiles/profile.h" | 8 #include "chrome/browser/profiles/profile.h" |
| 9 #include "chrome/browser/ui/browser_window.h" | 9 #include "chrome/browser/ui/browser_window.h" |
| 10 #include "chrome/browser/ui/panels/base_panel_browser_test.h" | 10 #include "chrome/browser/ui/panels/base_panel_browser_test.h" |
| (...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 236 panel1->SetExpansionState(Panel::TITLE_ONLY); | 236 panel1->SetExpansionState(Panel::TITLE_ONLY); |
| 237 EXPECT_FALSE(panel_manager->ShouldBringUpTitlebars( | 237 EXPECT_FALSE(panel_manager->ShouldBringUpTitlebars( |
| 238 0, 0)); | 238 0, 0)); |
| 239 browser_view1->OnTitlebarMousePressed(panel1->GetBounds().origin()); | 239 browser_view1->OnTitlebarMousePressed(panel1->GetBounds().origin()); |
| 240 EXPECT_EQ(Panel::TITLE_ONLY, panel1->expansion_state()); | 240 EXPECT_EQ(Panel::TITLE_ONLY, panel1->expansion_state()); |
| 241 browser_view1->OnTitlebarMouseDragged( | 241 browser_view1->OnTitlebarMouseDragged( |
| 242 panel1->GetBounds().origin().Subtract(gfx::Point(5, 5))); | 242 panel1->GetBounds().origin().Subtract(gfx::Point(5, 5))); |
| 243 EXPECT_EQ(Panel::TITLE_ONLY, panel1->expansion_state()); | 243 EXPECT_EQ(Panel::TITLE_ONLY, panel1->expansion_state()); |
| 244 EXPECT_TRUE(panel_manager->ShouldBringUpTitlebars( | 244 EXPECT_TRUE(panel_manager->ShouldBringUpTitlebars( |
| 245 0, 0)); | 245 0, 0)); |
| 246 browser_view1->OnTitlebarMouseReleased(); | 246 browser_view1->OnTitlebarMouseReleased(panel::NO_MODIFIER); |
| 247 | 247 |
| 248 ClosePanelAndWaitForNotification(panel1); | 248 ClosePanelAndWaitForNotification(panel1); |
| 249 ClosePanelAndWaitForNotification(panel2); | 249 ClosePanelAndWaitForNotification(panel2); |
| 250 ClosePanelAndWaitForNotification(panel3); | 250 ClosePanelAndWaitForNotification(panel3); |
| 251 } | 251 } |
| 252 | 252 |
| 253 void TestChangeAutoHideTaskBarThickness() { | 253 void TestChangeAutoHideTaskBarThickness() { |
| 254 PanelManager* manager = PanelManager::GetInstance(); | 254 PanelManager* manager = PanelManager::GetInstance(); |
| 255 DockedPanelStrip* docked_strip = manager->docked_strip(); | 255 DockedPanelStrip* docked_strip = manager->docked_strip(); |
| 256 int initial_starting_right_position = docked_strip->StartingRightPosition(); | 256 int initial_starting_right_position = docked_strip->StartingRightPosition(); |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 476 IN_PROC_BROWSER_TEST_F(PanelBrowserViewTest, | 476 IN_PROC_BROWSER_TEST_F(PanelBrowserViewTest, |
| 477 MinimizeAndRestoreOnAutoHideTaskBar) { | 477 MinimizeAndRestoreOnAutoHideTaskBar) { |
| 478 TestMinimizeAndRestore(true); | 478 TestMinimizeAndRestore(true); |
| 479 } | 479 } |
| 480 | 480 |
| 481 IN_PROC_BROWSER_TEST_F(PanelBrowserViewTest, | 481 IN_PROC_BROWSER_TEST_F(PanelBrowserViewTest, |
| 482 ChangeAutoHideTaskBarThickness) { | 482 ChangeAutoHideTaskBarThickness) { |
| 483 TestChangeAutoHideTaskBarThickness(); | 483 TestChangeAutoHideTaskBarThickness(); |
| 484 } | 484 } |
| 485 #endif | 485 #endif |
| OLD | NEW |