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

Unified Diff: ui/views/widget/native_widget_aura.cc

Issue 2538633002: Adds a couple more properties to the property converter (Closed)
Patch Set: cleanup Created 4 years, 1 month 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 side-by-side diff with in-line comments
Download patch
Index: ui/views/widget/native_widget_aura.cc
diff --git a/ui/views/widget/native_widget_aura.cc b/ui/views/widget/native_widget_aura.cc
index e719b2c9df3d8b972ef0139bd15cffe7514eec94..3c33aec2b50b7f305eaeb75e52435a73e2839e61 100644
--- a/ui/views/widget/native_widget_aura.cc
+++ b/ui/views/widget/native_widget_aura.cc
@@ -11,6 +11,7 @@
#include "base/strings/string_util.h"
#include "base/threading/thread_task_runner_handle.h"
#include "build/build_config.h"
+#include "services/ui/public/interfaces/window_manager.mojom.h"
#include "third_party/skia/include/core/SkRegion.h"
#include "ui/aura/client/aura_constants.h"
#include "ui/aura/client/capture_client.h"
@@ -313,6 +314,8 @@ void NativeWidgetAura::CenterWindow(const gfx::Size& size) {
if (!window_)
return;
+ window_->SetProperty(aura::client::kPreferredSize, new gfx::Size(size));
+
gfx::Rect parent_bounds(window_->parent()->GetBoundsInRootWindow());
// When centering window, we take the intersection of the host and
// the parent. We assume the root window represents the visible
« ui/views/mus/mus_client.cc ('K') | « ui/views/test/native_widget_factory_aura_mus.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698