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

Side by Side Diff: ash/mus/non_client_frame_controller.cc

Issue 2689283003: chromeos: removes underlay surface offset (Closed)
Patch Set: log error Created 3 years, 10 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 | « no previous file | services/ui/public/interfaces/window_manager.mojom » ('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 "ash/mus/non_client_frame_controller.h" 5 #include "ash/mus/non_client_frame_controller.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <memory> 9 #include <memory>
10 #include <string> 10 #include <string>
(...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 } 312 }
313 // Applying properties will have set the show state if specified. 313 // Applying properties will have set the show state if specified.
314 // NativeWidgetAura resets the show state from |params|, so we need to update 314 // NativeWidgetAura resets the show state from |params|, so we need to update
315 // |params|. 315 // |params|.
316 params.show_state = window_->GetProperty(aura::client::kShowStateKey); 316 params.show_state = window_->GetProperty(aura::client::kShowStateKey);
317 widget_->Init(params); 317 widget_->Init(params);
318 did_init_native_widget_ = true; 318 did_init_native_widget_ = true;
319 319
320 widget_->ShowInactive(); 320 widget_->ShowInactive();
321 321
322 const int shadow_inset =
323 Shadow::GetInteriorInsetForStyle(Shadow::STYLE_ACTIVE);
324 WmWindow* wm_window = WmWindow::Get(window_); 322 WmWindow* wm_window = WmWindow::Get(window_);
325 const gfx::Insets extended_hit_region = 323 const gfx::Insets extended_hit_region =
326 wm_window->ShouldUseExtendedHitRegion() ? GetExtendedHitRegion() 324 wm_window->ShouldUseExtendedHitRegion() ? GetExtendedHitRegion()
327 : gfx::Insets(); 325 : gfx::Insets();
328 window_manager_client_->SetUnderlaySurfaceOffsetAndExtendedHitArea( 326 window_manager_client_->SetExtendedHitArea(window_, extended_hit_region);
329 window_, gfx::Vector2d(shadow_inset, shadow_inset), extended_hit_region);
330 327
331 aura::client::GetTransientWindowClient()->AddObserver(this); 328 aura::client::GetTransientWindowClient()->AddObserver(this);
332 } 329 }
333 330
334 // static 331 // static
335 NonClientFrameController* NonClientFrameController::Get(aura::Window* window) { 332 NonClientFrameController* NonClientFrameController::Get(aura::Window* window) {
336 return window->GetProperty(kNonClientFrameControllerKey); 333 return window->GetProperty(kNonClientFrameControllerKey);
337 } 334 }
338 335
339 // static 336 // static
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
457 void NonClientFrameController::OnWillRestackTransientChildAbove( 454 void NonClientFrameController::OnWillRestackTransientChildAbove(
458 aura::Window* parent, 455 aura::Window* parent,
459 aura::Window* transient_child) {} 456 aura::Window* transient_child) {}
460 457
461 void NonClientFrameController::OnDidRestackTransientChildAbove( 458 void NonClientFrameController::OnDidRestackTransientChildAbove(
462 aura::Window* parent, 459 aura::Window* parent,
463 aura::Window* transient_child) {} 460 aura::Window* transient_child) {}
464 461
465 } // namespace mus 462 } // namespace mus
466 } // namespace ash 463 } // namespace ash
OLDNEW
« no previous file with comments | « no previous file | services/ui/public/interfaces/window_manager.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698