| 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/panels/panel_layout_manager.h" | 5 #include "ash/wm/panels/panel_layout_manager.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "ash/launcher/launcher.h" | 10 #include "ash/launcher/launcher.h" |
| (...skipping 420 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 431 panel_windows_.erase(dragged_panel_iter); | 431 panel_windows_.erase(dragged_panel_iter); |
| 432 panel_windows_.insert(new_position, dragged_panel_info); | 432 panel_windows_.insert(new_position, dragged_panel_info); |
| 433 } | 433 } |
| 434 } | 434 } |
| 435 | 435 |
| 436 SetChildBoundsDirect(child, bounds); | 436 SetChildBoundsDirect(child, bounds); |
| 437 Relayout(); | 437 Relayout(); |
| 438 } | 438 } |
| 439 | 439 |
| 440 //////////////////////////////////////////////////////////////////////////////// | 440 //////////////////////////////////////////////////////////////////////////////// |
| 441 // PanelLayoutManager, ash::LauncherIconObserver implementation: | 441 // PanelLayoutManager, ShelfIconObserver implementation: |
| 442 | 442 |
| 443 void PanelLayoutManager::OnLauncherIconPositionsChanged() { | 443 void PanelLayoutManager::OnShelfIconPositionsChanged() { |
| 444 // TODO: As this is called for every animation step now. Relayout needs to be | 444 // TODO: As this is called for every animation step now. Relayout needs to be |
| 445 // updated to use current icon position instead of use the ideal bounds so | 445 // updated to use current icon position instead of use the ideal bounds so |
| 446 // that the panels slide with their icons instead of jumping. | 446 // that the panels slide with their icons instead of jumping. |
| 447 Relayout(); | 447 Relayout(); |
| 448 } | 448 } |
| 449 | 449 |
| 450 //////////////////////////////////////////////////////////////////////////////// | 450 //////////////////////////////////////////////////////////////////////////////// |
| 451 // PanelLayoutManager, ash::ShellObserver implementation: | 451 // PanelLayoutManager, ash::ShellObserver implementation: |
| 452 | 452 |
| 453 void PanelLayoutManager::OnShelfAlignmentChanged(aura::Window* root_window) { | 453 void PanelLayoutManager::OnShelfAlignmentChanged(aura::Window* root_window) { |
| (...skipping 410 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 864 | 864 |
| 865 void PanelLayoutManager::OnKeyboardBoundsChanging( | 865 void PanelLayoutManager::OnKeyboardBoundsChanging( |
| 866 const gfx::Rect& keyboard_bounds) { | 866 const gfx::Rect& keyboard_bounds) { |
| 867 // This bounds change will have caused a change to the Shelf which does not | 867 // This bounds change will have caused a change to the Shelf which does not |
| 868 // propogate automatically to this class, so manually recalculate bounds. | 868 // propogate automatically to this class, so manually recalculate bounds. |
| 869 OnWindowResized(); | 869 OnWindowResized(); |
| 870 } | 870 } |
| 871 | 871 |
| 872 } // namespace internal | 872 } // namespace internal |
| 873 } // namespace ash | 873 } // namespace ash |
| OLD | NEW |