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

Side by Side Diff: ash/wm/common/panels/panel_layout_manager.cc

Issue 1997633004: Removes |old| parameter from OnWindowPropertyChanged() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 months 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
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/wm/common/panels/panel_layout_manager.h" 5 #include "ash/wm/common/panels/panel_layout_manager.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after
440 Relayout(); 440 Relayout();
441 } 441 }
442 442
443 void PanelLayoutManager::OnShelfAlignmentChanged() { 443 void PanelLayoutManager::OnShelfAlignmentChanged() {
444 Relayout(); 444 Relayout();
445 } 445 }
446 446
447 ///////////////////////////////////////////////////////////////////////////// 447 /////////////////////////////////////////////////////////////////////////////
448 // PanelLayoutManager, WindowObserver implementation: 448 // PanelLayoutManager, WindowObserver implementation:
449 449
450 void PanelLayoutManager::OnWindowPropertyChanged(wm::WmWindow* window, 450 void PanelLayoutManager::OnWindowPropertyChanged(
451 wm::WmWindowProperty property, 451 wm::WmWindow* window,
452 intptr_t old) { 452 wm::WmWindowProperty property) {
453 // Trigger a relayout to position the panels whenever the panel icon is set 453 // Trigger a relayout to position the panels whenever the panel icon is set
454 // or changes. 454 // or changes.
455 if (property == wm::WmWindowProperty::SHELF_ID) 455 if (property == wm::WmWindowProperty::SHELF_ID)
456 Relayout(); 456 Relayout();
457 } 457 }
458 458
459 ///////////////////////////////////////////////////////////////////////////// 459 /////////////////////////////////////////////////////////////////////////////
460 // PanelLayoutManager, WindowStateObserver implementation: 460 // PanelLayoutManager, WindowStateObserver implementation:
461 461
462 void PanelLayoutManager::OnPostWindowStateTypeChange( 462 void PanelLayoutManager::OnPostWindowStateTypeChange(
(...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after
893 // Keyboard hidden, restore original bounds if they exist. 893 // Keyboard hidden, restore original bounds if they exist.
894 panel->SetBoundsDirect(panel_state->GetRestoreBoundsInScreen()); 894 panel->SetBoundsDirect(panel_state->GetRestoreBoundsInScreen());
895 } 895 }
896 } 896 }
897 // This bounds change will have caused a change to the Shelf which does not 897 // This bounds change will have caused a change to the Shelf which does not
898 // propogate automatically to this class, so manually recalculate bounds. 898 // propogate automatically to this class, so manually recalculate bounds.
899 OnWindowResized(); 899 OnWindowResized();
900 } 900 }
901 901
902 } // namespace ash 902 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698