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

Unified Diff: blimp/client/app/linux/blimp_display_manager.cc

Issue 2504793002: Scale bounds in DesktopWindowTreeHostMus and in calls to SetBounds. (Closed)
Patch Set: SetBounds + rebase 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
« no previous file with comments | « no previous file | blimp/client/public/contents/blimp_contents_view.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: blimp/client/app/linux/blimp_display_manager.cc
diff --git a/blimp/client/app/linux/blimp_display_manager.cc b/blimp/client/app/linux/blimp_display_manager.cc
index 1f1f10911bcec221aabb1ac6d3411f2b8e6b054f..078c89366c59c90c7bb263680adf5013798eda6d 100644
--- a/blimp/client/app/linux/blimp_display_manager.cc
+++ b/blimp/client/app/linux/blimp_display_manager.cc
@@ -14,6 +14,7 @@
#include "ui/events/gesture_detection/motion_event_generic.h"
#include "ui/events/gestures/motion_event_aura.h"
#include "ui/events/platform/platform_event_source.h"
+#include "ui/gfx/geometry/dip_util.h"
#include "ui/gfx/geometry/size.h"
#include "ui/platform_window/platform_window.h"
#include "ui/platform_window/x11/x11_window.h"
@@ -40,7 +41,8 @@ BlimpDisplayManager::BlimpDisplayManager(
BlimpDisplayManager::~BlimpDisplayManager() = default;
void BlimpDisplayManager::SetWindowSize(const gfx::Size& window_size) {
- platform_window_->SetBounds(gfx::Rect(window_size));
+ platform_window_->SetBounds(
+ gfx::ConvertRectToPixel(device_pixel_ratio_, gfx::Rect(window_size)));
}
void BlimpDisplayManager::SetBlimpContents(
« no previous file with comments | « no previous file | blimp/client/public/contents/blimp_contents_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698