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

Side by Side Diff: services/ui/public/cpp/lib/window.cc

Issue 2092343002: Touch HUD app for mustash (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Change window manager connection unittest to original Created 4 years, 5 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 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 "services/ui/public/cpp/window.h" 5 #include "services/ui/public/cpp/window.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <set> 10 #include <set>
(...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after
465 client_->RequestClose(this); 465 client_->RequestClose(this);
466 } 466 }
467 467
468 std::string Window::GetName() const { 468 std::string Window::GetName() const {
469 if (HasSharedProperty(mojom::WindowManager::kName_Property)) 469 if (HasSharedProperty(mojom::WindowManager::kName_Property))
470 return GetSharedProperty<std::string>(mojom::WindowManager::kName_Property); 470 return GetSharedProperty<std::string>(mojom::WindowManager::kName_Property);
471 471
472 return std::string(); 472 return std::string();
473 } 473 }
474 474
475 void Window::SetAcceptEvents(bool accept_events) {
476 if (client_)
477 client_->SetAcceptEvents(server_id_, accept_events);
478 }
479
475 //////////////////////////////////////////////////////////////////////////////// 480 ////////////////////////////////////////////////////////////////////////////////
476 // Window, protected: 481 // Window, protected:
477 482
478 Window::Window() : Window(nullptr, static_cast<Id>(-1)) {} 483 Window::Window() : Window(nullptr, static_cast<Id>(-1)) {}
479 484
480 Window::~Window() { 485 Window::~Window() {
481 FOR_EACH_OBSERVER(WindowObserver, observers_, OnWindowDestroying(this)); 486 FOR_EACH_OBSERVER(WindowObserver, observers_, OnWindowDestroying(this));
482 if (client_) 487 if (client_)
483 client_->OnWindowDestroying(this); 488 client_->OnWindowDestroying(this);
484 489
(...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after
882 notifier->NotifyWindowReordered(); 887 notifier->NotifyWindowReordered();
883 888
884 return true; 889 return true;
885 } 890 }
886 891
887 // static 892 // static
888 Window** Window::GetStackingTarget(Window* window) { 893 Window** Window::GetStackingTarget(Window* window) {
889 return &window->stacking_target_; 894 return &window->stacking_target_;
890 } 895 }
891 } // namespace ui 896 } // namespace ui
OLDNEW
« no previous file with comments | « mash/touch_hud/touch_hud_application.cc ('k') | services/ui/public/cpp/lib/window_tree_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698