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

Side by Side Diff: components/mus/ws/connection_manager.cc

Issue 1775133003: Moves EventDispatcher from Display to WindowManagerState (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: todo Created 4 years, 9 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
« no previous file with comments | « components/mus/ws/connection_manager.h ('k') | components/mus/ws/display.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "components/mus/ws/connection_manager.h" 5 #include "components/mus/ws/connection_manager.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/stl_util.h" 8 #include "base/stl_util.h"
9 #include "components/mus/ws/connection_manager_delegate.h" 9 #include "components/mus/ws/connection_manager_delegate.h"
10 #include "components/mus/ws/display.h" 10 #include "components/mus/ws/display.h"
(...skipping 464 matching lines...) Expand 10 before | Expand all | Expand 10 after
475 void ConnectionManager::OnWindowBoundsChanged(ServerWindow* window, 475 void ConnectionManager::OnWindowBoundsChanged(ServerWindow* window,
476 const gfx::Rect& old_bounds, 476 const gfx::Rect& old_bounds,
477 const gfx::Rect& new_bounds) { 477 const gfx::Rect& new_bounds) {
478 if (in_destructor_) 478 if (in_destructor_)
479 return; 479 return;
480 480
481 ProcessWindowBoundsChanged(window, old_bounds, new_bounds); 481 ProcessWindowBoundsChanged(window, old_bounds, new_bounds);
482 if (!window->parent()) 482 if (!window->parent())
483 return; 483 return;
484 484
485 // TODO(sky): optimize this.
486 SchedulePaint(window->parent(), old_bounds); 485 SchedulePaint(window->parent(), old_bounds);
487 SchedulePaint(window->parent(), new_bounds); 486 SchedulePaint(window->parent(), new_bounds);
488 487
489 MaybeUpdateNativeCursor(window); 488 MaybeUpdateNativeCursor(window);
490 } 489 }
491 490
492 void ConnectionManager::OnWindowClientAreaChanged( 491 void ConnectionManager::OnWindowClientAreaChanged(
493 ServerWindow* window, 492 ServerWindow* window,
494 const gfx::Insets& new_client_area, 493 const gfx::Insets& new_client_area,
495 const std::vector<gfx::Rect>& new_additional_client_areas) { 494 const std::vector<gfx::Rect>& new_additional_client_areas) {
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
565 ServerWindow* transient_child) { 564 ServerWindow* transient_child) {
566 // If we're deleting a window, then this is a superfluous message. 565 // If we're deleting a window, then this is a superfluous message.
567 if (current_operation_type() == OperationType::DELETE_WINDOW) 566 if (current_operation_type() == OperationType::DELETE_WINDOW)
568 return; 567 return;
569 for (auto& pair : tree_map_) { 568 for (auto& pair : tree_map_) {
570 pair.second->ProcessTransientWindowRemoved(window, transient_child, 569 pair.second->ProcessTransientWindowRemoved(window, transient_child,
571 IsOperationSource(pair.first)); 570 IsOperationSource(pair.first));
572 } 571 }
573 } 572 }
574 573
575 void ConnectionManager::OnWillDestroyDisplay(Display* display) {
576 for (auto& pair : tree_map_)
577 pair.second->OnWillDestroyDisplay(display);
578 }
579
580 void ConnectionManager::OnFirstDisplayReady() { 574 void ConnectionManager::OnFirstDisplayReady() {
581 delegate_->OnFirstDisplayReady(); 575 delegate_->OnFirstDisplayReady();
582 } 576 }
583 577
584 void ConnectionManager::OnNoMoreDisplays() { 578 void ConnectionManager::OnNoMoreDisplays() {
585 delegate_->OnNoMoreDisplays(); 579 delegate_->OnNoMoreDisplays();
586 } 580 }
587 581
588 } // namespace ws 582 } // namespace ws
589 } // namespace mus 583 } // namespace mus
OLDNEW
« no previous file with comments | « components/mus/ws/connection_manager.h ('k') | components/mus/ws/display.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698