| 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/wm/shelf_layout_manager.h" | 5 #include "ash/wm/shelf_layout_manager.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "ash/launcher/launcher.h" | 9 #include "ash/launcher/launcher.h" |
| 10 #include "ash/screen_ash.h" | 10 #include "ash/screen_ash.h" |
| (...skipping 524 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 535 Shell* shell = Shell::GetInstance(); | 535 Shell* shell = Shell::GetInstance(); |
| 536 if (shell->GetAppListTargetVisibility()) | 536 if (shell->GetAppListTargetVisibility()) |
| 537 return AUTO_HIDE_SHOWN; | 537 return AUTO_HIDE_SHOWN; |
| 538 | 538 |
| 539 if (shell->system_tray() && shell->system_tray()->should_show_launcher()) | 539 if (shell->system_tray() && shell->system_tray()->should_show_launcher()) |
| 540 return AUTO_HIDE_SHOWN; | 540 return AUTO_HIDE_SHOWN; |
| 541 | 541 |
| 542 if (launcher_ && launcher_->IsShowingMenu()) | 542 if (launcher_ && launcher_->IsShowingMenu()) |
| 543 return AUTO_HIDE_SHOWN; | 543 return AUTO_HIDE_SHOWN; |
| 544 | 544 |
| 545 if (launcher_ && launcher_->IsShowingOverflowBubble()) |
| 546 return AUTO_HIDE_SHOWN; |
| 547 |
| 545 if (launcher_widget()->IsActive() || status_->IsActive()) | 548 if (launcher_widget()->IsActive() || status_->IsActive()) |
| 546 return AUTO_HIDE_SHOWN; | 549 return AUTO_HIDE_SHOWN; |
| 547 | 550 |
| 548 // Don't show if the user is dragging the mouse. | 551 // Don't show if the user is dragging the mouse. |
| 549 if (event_filter_.get() && event_filter_->in_mouse_drag()) | 552 if (event_filter_.get() && event_filter_->in_mouse_drag()) |
| 550 return AUTO_HIDE_HIDDEN; | 553 return AUTO_HIDE_HIDDEN; |
| 551 | 554 |
| 552 aura::RootWindow* root = launcher_widget()->GetNativeView()->GetRootWindow(); | 555 aura::RootWindow* root = launcher_widget()->GetNativeView()->GetRootWindow(); |
| 553 bool mouse_over_launcher = | 556 bool mouse_over_launcher = |
| 554 launcher_widget()->GetWindowScreenBounds().Contains( | 557 launcher_widget()->GetWindowScreenBounds().Contains( |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 592 int ShelfLayoutManager::GetWorkAreaSize(const State& state, int size) const { | 595 int ShelfLayoutManager::GetWorkAreaSize(const State& state, int size) const { |
| 593 if (state.visibility_state == VISIBLE) | 596 if (state.visibility_state == VISIBLE) |
| 594 return size; | 597 return size; |
| 595 if (state.visibility_state == AUTO_HIDE) | 598 if (state.visibility_state == AUTO_HIDE) |
| 596 return kAutoHideSize; | 599 return kAutoHideSize; |
| 597 return 0; | 600 return 0; |
| 598 } | 601 } |
| 599 | 602 |
| 600 } // namespace internal | 603 } // namespace internal |
| 601 } // namespace ash | 604 } // namespace ash |
| OLD | NEW |