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

Side by Side Diff: mash/wm/non_client_frame_controller.cc

Issue 1857623003: convert //mash to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 | « mash/wm/layout_manager_unittest.cc ('k') | mash/wm/root_window_controller.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "mash/wm/non_client_frame_controller.h" 5 #include "mash/wm/non_client_frame_controller.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <memory>
10
9 #include "base/macros.h" 11 #include "base/macros.h"
10 #include "components/mus/public/cpp/property_type_converters.h" 12 #include "components/mus/public/cpp/property_type_converters.h"
11 #include "components/mus/public/cpp/window.h" 13 #include "components/mus/public/cpp/window.h"
12 #include "components/mus/public/cpp/window_manager_delegate.h" 14 #include "components/mus/public/cpp/window_manager_delegate.h"
13 #include "components/mus/public/cpp/window_property.h" 15 #include "components/mus/public/cpp/window_property.h"
14 #include "components/mus/public/interfaces/window_manager.mojom.h" 16 #include "components/mus/public/interfaces/window_manager.mojom.h"
15 #include "components/mus/public/interfaces/window_tree_host.mojom.h" 17 #include "components/mus/public/interfaces/window_tree_host.mojom.h"
16 #include "mash/wm/frame/frame_border_hit_test_controller.h" 18 #include "mash/wm/frame/frame_border_hit_test_controller.h"
17 #include "mash/wm/frame/move_event_handler.h" 19 #include "mash/wm/frame/move_event_handler.h"
18 #include "mash/wm/frame/non_client_frame_view_mash.h" 20 #include "mash/wm/frame/non_client_frame_view_mash.h"
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
133 const gfx::ImageSkia& app_icon) override { 135 const gfx::ImageSkia& app_icon) override {
134 // Do nothing. The client controls window icons, not us. 136 // Do nothing. The client controls window icons, not us.
135 } 137 }
136 void UpdateClientArea() override { 138 void UpdateClientArea() override {
137 // This pushes the client area to the WS. We don't want to do that as 139 // This pushes the client area to the WS. We don't want to do that as
138 // the client area should come from the client, not us. 140 // the client area should come from the client, not us.
139 } 141 }
140 142
141 private: 143 private:
142 // The shadow, may be null. 144 // The shadow, may be null.
143 scoped_ptr<Shadow> shadow_; 145 std::unique_ptr<Shadow> shadow_;
144 146
145 scoped_ptr<MoveEventHandler> move_event_handler_; 147 std::unique_ptr<MoveEventHandler> move_event_handler_;
146 148
147 DISALLOW_COPY_AND_ASSIGN(WmNativeWidgetMus); 149 DISALLOW_COPY_AND_ASSIGN(WmNativeWidgetMus);
148 }; 150 };
149 151
150 class ClientViewMus : public views::ClientView { 152 class ClientViewMus : public views::ClientView {
151 public: 153 public:
152 ClientViewMus(views::Widget* widget, 154 ClientViewMus(views::Widget* widget,
153 views::View* contents_view, 155 views::View* contents_view,
154 NonClientFrameController* frame_controller) 156 NonClientFrameController* frame_controller)
155 : views::ClientView(widget, contents_view), 157 : views::ClientView(widget, contents_view),
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
270 widget_->UpdateWindowTitle(); 272 widget_->UpdateWindowTitle();
271 } 273 }
272 274
273 void NonClientFrameController::OnWindowDestroyed(mus::Window* window) { 275 void NonClientFrameController::OnWindowDestroyed(mus::Window* window) {
274 window_->RemoveObserver(this); 276 window_->RemoveObserver(this);
275 window_ = nullptr; 277 window_ = nullptr;
276 } 278 }
277 279
278 } // namespace wm 280 } // namespace wm
279 } // namespace mash 281 } // namespace mash
OLDNEW
« no previous file with comments | « mash/wm/layout_manager_unittest.cc ('k') | mash/wm/root_window_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698