| 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 "ash/common/system/web_notification/web_notification_tray.h" | 5 #include "ash/common/system/web_notification/web_notification_tray.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "ash/common/shelf/wm_shelf.h" | 10 #include "ash/common/shelf/wm_shelf.h" |
| (...skipping 394 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 405 EXPECT_EQ(SHELF_AUTO_HIDE_HIDDEN, shelf->GetAutoHideState()); | 405 EXPECT_EQ(SHELF_AUTO_HIDE_HIDDEN, shelf->GetAutoHideState()); |
| 406 int bottom_auto_hidden = GetPopupWorkAreaBottom(); | 406 int bottom_auto_hidden = GetPopupWorkAreaBottom(); |
| 407 shelf->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_NEVER); | 407 shelf->SetAutoHideBehavior(SHELF_AUTO_HIDE_BEHAVIOR_NEVER); |
| 408 | 408 |
| 409 // Put |widget| into fullscreen without forcing the shelf to hide. Currently, | 409 // Put |widget| into fullscreen without forcing the shelf to hide. Currently, |
| 410 // this is used by immersive fullscreen and forces the shelf to be auto | 410 // this is used by immersive fullscreen and forces the shelf to be auto |
| 411 // hidden. | 411 // hidden. |
| 412 WmLookup::Get() | 412 WmLookup::Get() |
| 413 ->GetWindowForWidget(widget.get()) | 413 ->GetWindowForWidget(widget.get()) |
| 414 ->GetWindowState() | 414 ->GetWindowState() |
| 415 ->set_shelf_mode_in_fullscreen( | 415 ->set_hide_shelf_when_fullscreen(false); |
| 416 ash::wm::WindowState::SHELF_AUTO_HIDE_VISIBLE); | |
| 417 widget->SetFullscreen(true); | 416 widget->SetFullscreen(true); |
| 418 RunAllPendingInMessageLoop(); | 417 RunAllPendingInMessageLoop(); |
| 419 | 418 |
| 420 // The work area for auto-hidden status of fullscreen is a bit larger | 419 // The work area for auto-hidden status of fullscreen is a bit larger |
| 421 // since it doesn't even have the 3-pixel width. | 420 // since it doesn't even have the 3-pixel width. |
| 422 EXPECT_EQ(SHELF_AUTO_HIDE_HIDDEN, shelf->GetAutoHideState()); | 421 EXPECT_EQ(SHELF_AUTO_HIDE_HIDDEN, shelf->GetAutoHideState()); |
| 423 int bottom_fullscreen_hidden = GetPopupWorkAreaBottom(); | 422 int bottom_fullscreen_hidden = GetPopupWorkAreaBottom(); |
| 424 EXPECT_EQ(bottom_auto_hidden, bottom_fullscreen_hidden); | 423 EXPECT_EQ(bottom_auto_hidden, bottom_fullscreen_hidden); |
| 425 | 424 |
| 426 // Move the mouse cursor at the bottom, which shows the shelf. | 425 // Move the mouse cursor at the bottom, which shows the shelf. |
| (...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 507 EXPECT_FALSE(tray->draw_background_as_active()); | 506 EXPECT_FALSE(tray->draw_background_as_active()); |
| 508 | 507 |
| 509 generator.ReleaseTouch(); | 508 generator.ReleaseTouch(); |
| 510 EXPECT_FALSE(tray->draw_background_as_active()); | 509 EXPECT_FALSE(tray->draw_background_as_active()); |
| 511 EXPECT_FALSE(tray->IsMessageCenterBubbleVisible()); | 510 EXPECT_FALSE(tray->IsMessageCenterBubbleVisible()); |
| 512 } | 511 } |
| 513 | 512 |
| 514 #endif // OS_CHROMEOS | 513 #endif // OS_CHROMEOS |
| 515 | 514 |
| 516 } // namespace ash | 515 } // namespace ash |
| OLD | NEW |