summaryrefslogtreecommitdiff
path: root/vcl/source/app
diff options
context:
space:
mode:
authorChris Sherlock <chris.sherlock79@gmail.com>2014-05-06 22:56:25 +1000
committerChris Sherlock <chris.sherlock79@gmail.com>2014-05-07 09:28:59 +1000
commitef31acfde05d5fe0706b0e2d24fc19d07cdbcd31 (patch)
tree25c83a4277233949c6d0bcc74719f2f8792801a8 /vcl/source/app
parent20144988df7296fb012ff0b01f04d3978888e94d (diff)
VCL: Application::SetSettings should not set mnAppFontX to 0
pImplSVData->maGDIData.mnAppFontX is *not* a flag to determine if application font dimensions should be reset. The way it currently works is: 1. Application::SetSettings() is called to reset Window settings, etc. 2. Settings are updated on all windows - but at the same time pImplSVData->maGDIData.mnAppFontX is set to zero as a way of indicating to the global function ImplCalMapResolution that we need to get the font from the first window, or if this isn't available then create a new dummy WorkWindow and use this to get the font data, and set the application font to this. This is very odd. What we really should be doing is calling on ImplInitAppFontData directly from within SetSettings() instead of making ImplCalcMapResolution detect that mnAppFontX is zero and there is a valid first frame window. Ultimately, this was found when I commited f76026a43acc to move ImplInitAppFontData from Window to Application. Somehow I entirely missed that the font and style dropdowns in writer died, and I also somehow a whole bunch of tests failed but I again didn't notice this either. With this fix, I should be able to recommit the previous change. Change-Id: Ib526954962fdc397fb3ddd3c21ae947d939db9e5
Diffstat (limited to 'vcl/source/app')
-rw-r--r--vcl/source/app/svapp.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx
index 4c8a25465b38..607702d1a0d2 100644
--- a/vcl/source/app/svapp.cxx
+++ b/vcl/source/app/svapp.cxx
@@ -549,7 +549,7 @@ void Application::SetSettings( const AllSettings& rSettings )
{
nOldDPIX = pFirstFrame->mnDPIX;
nOldDPIY = pFirstFrame->mnDPIY;
- pSVData->maGDIData.mnAppFontX = 0;
+ Window::ImplInitAppFontData(pFirstFrame);
}
Window* pFrame = pFirstFrame;
while ( pFrame )