diff options
author | Vladimir Glazounov <vg@openoffice.org> | 2008-10-01 13:31:44 +0000 |
---|---|---|
committer | Vladimir Glazounov <vg@openoffice.org> | 2008-10-01 13:31:44 +0000 |
commit | 46a63a2af38e694327c5308168f499a549fb724e (patch) | |
tree | 6e80cfea121ed9231141a56153e9208f553863cb /vcl/unx/source | |
parent | 248539e2fa8ac0f5271a83f26fe71d0dcc4a5a67 (diff) |
CWS-TOOLING: integrate CWS vcl92
Diffstat (limited to 'vcl/unx/source')
-rw-r--r-- | vcl/unx/source/app/randrwrapper.cxx | 10 | ||||
-rw-r--r-- | vcl/unx/source/app/saldisp.cxx | 25 | ||||
-rw-r--r-- | vcl/unx/source/gdi/pspgraphics.cxx | 5 | ||||
-rw-r--r-- | vcl/unx/source/gdi/salgdi.cxx | 6 |
4 files changed, 9 insertions, 37 deletions
diff --git a/vcl/unx/source/app/randrwrapper.cxx b/vcl/unx/source/app/randrwrapper.cxx index f9bf6e2e168f..b079e2909e71 100644 --- a/vcl/unx/source/app/randrwrapper.cxx +++ b/vcl/unx/source/app/randrwrapper.cxx @@ -8,7 +8,7 @@ * * $RCSfile: randrwrapper.cxx,v $ * - * $Revision: 1.5 $ + * $Revision: 1.5.10.1 $ * * This file is part of OpenOffice.org. * @@ -281,6 +281,7 @@ void RandRWrapper::releaseWrapper() #endif #include "saldisp.hxx" +#include "salframe.h" void SalDisplay::InitRandR( XLIB_Window aRoot ) const { @@ -314,6 +315,7 @@ int SalDisplay::processRandREvent( XEvent* pEvent ) if( nRet == 1 && pEvent->type != ConfigureNotify) // this should then be a XRRScreenChangeNotifyEvent { // update screens + bool bNotify = false; for( size_t i = 0; i < m_aScreens.size(); i++ ) { if( m_aScreens[i].m_bInit ) @@ -329,6 +331,10 @@ int SalDisplay::processRandREvent( XEvent* pEvent ) pSizes = pWrapper->XRRConfigSizes( pConfig, &nSizes ); XRRScreenSize *pTargetSize = pSizes + nId; + bNotify = bNotify || + m_aScreens[i].m_aSize.Width() != pTargetSize->width || + m_aScreens[i].m_aSize.Height() != pTargetSize->height; + m_aScreens[i].m_aSize = Size( pTargetSize->width, pTargetSize->height ); pWrapper->XRRFreeScreenConfigInfo( pConfig ); @@ -338,6 +344,8 @@ int SalDisplay::processRandREvent( XEvent* pEvent ) #endif } } + if( bNotify && ! m_aFrames.empty() ) + m_aFrames.front()->CallCallback( SALEVENT_DISPLAYCHANGED, 0 ); } } #else diff --git a/vcl/unx/source/app/saldisp.cxx b/vcl/unx/source/app/saldisp.cxx index a1f51a33c618..ac4506c0ac6c 100644 --- a/vcl/unx/source/app/saldisp.cxx +++ b/vcl/unx/source/app/saldisp.cxx @@ -2609,31 +2609,6 @@ void SalDisplay::PrintInfo() const sal::static_int_cast< unsigned int >(GetVisual(m_nDefaultScreen).GetVisualId()) ); } -void SalDisplay::GetScreenFontResolution( sal_Int32& rDPIX, sal_Int32& rDPIY ) const -{ - rDPIX = aResolution_.A(); - rDPIY = aResolution_.B(); - if( mbExactResolution ) - return; - - int nThreshold; - if (m_aScreens[m_nDefaultScreen].m_aSize.Height() <= 600) - nThreshold = 96; - else if (m_aScreens[m_nDefaultScreen].m_aSize.Height() <= 768) - nThreshold = 108; - else - nThreshold = 120; - - if( rDPIY < nThreshold ) - { - rDPIX = Divide( rDPIX * nThreshold, rDPIY ); - rDPIY = nThreshold; - } - - // #i18602# always equalize x- and y-resolution - rDPIX = rDPIY; -} - void SalDisplay::InitXinerama() { if( m_aScreens.size() > 1 ) diff --git a/vcl/unx/source/gdi/pspgraphics.cxx b/vcl/unx/source/gdi/pspgraphics.cxx index 60111ff2acd5..44c3e19f589f 100644 --- a/vcl/unx/source/gdi/pspgraphics.cxx +++ b/vcl/unx/source/gdi/pspgraphics.cxx @@ -275,11 +275,6 @@ void PspGraphics::GetResolution( sal_Int32 &rDPIX, sal_Int32 &rDPIY ) } } -void PspGraphics::GetScreenFontResolution( sal_Int32 &rDPIX, sal_Int32 &rDPIY ) -{ - m_pPrinterGfx->GetScreenFontResolution (rDPIX, rDPIY); -} - USHORT PspGraphics::GetBitCount() { return m_pPrinterGfx->GetBitCount(); diff --git a/vcl/unx/source/gdi/salgdi.cxx b/vcl/unx/source/gdi/salgdi.cxx index bb861ba020fd..2b21397248ef 100644 --- a/vcl/unx/source/gdi/salgdi.cxx +++ b/vcl/unx/source/gdi/salgdi.cxx @@ -518,12 +518,6 @@ void X11SalGraphics::GetResolution( sal_Int32 &rDPIX, sal_Int32 &rDPIY ) // cons } // -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= -void X11SalGraphics::GetScreenFontResolution( sal_Int32 &rDPIX, sal_Int32 &rDPIY ) // const -{ - GetDisplay()->GetScreenFontResolution( rDPIX, rDPIY ); -} - -// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= USHORT X11SalGraphics::GetBitCount() // const { return GetVisual().GetDepth(); |