diff options
author | ananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-04 11:10:51 +0000 |
---|---|---|
committer | ananta@chromium.org <ananta@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2014-06-04 11:10:51 +0000 |
commit | 6c72e093fc68313c0b3977e01ef140a698ad6fc6 (patch) | |
tree | c9756acd26813c633942c8ff3a699988772dc52b /ui/base/resource | |
parent | 82ba6a405f3f83ae5dd4b304c1eb5f8a01b91c43 (diff) | |
download | chromium_src-6c72e093fc68313c0b3977e01ef140a698ad6fc6.zip chromium_src-6c72e093fc68313c0b3977e01ef140a698ad6fc6.tar.gz chromium_src-6c72e093fc68313c0b3977e01ef140a698ad6fc6.tar.bz2 |
Pass the device scale factor in the command line to renderer processes.
This is to ensure that we don't use GDI to query the device scale factor in renderer processes.
This is in preparation for setting the MITIGATION_WIN32K_DISABLE policy on renderer processes, which
will lock them out from making user32/gdi32 calls which enter win32k.sys.
BUG=365160
Review URL: https://codereview.chromium.org/308003020
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@274766 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/base/resource')
-rw-r--r-- | ui/base/resource/resource_bundle.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/ui/base/resource/resource_bundle.cc b/ui/base/resource/resource_bundle.cc index 83aba3c..f5a592d 100644 --- a/ui/base/resource/resource_bundle.cc +++ b/ui/base/resource/resource_bundle.cc @@ -605,7 +605,10 @@ void ResourceBundle::InitSharedInstance(Delegate* delegate) { #if defined(OS_WIN) // Must be called _after_ supported scale factors are set since it // uses them. - ui::win::InitDeviceScaleFactor(); + // Don't initialize the device scale factor if it has already been + // initialized. + if (!gfx::win::IsDeviceScaleFactorSet()) + ui::win::InitDeviceScaleFactor(); #endif } |