diff options
author | Michael Meeks <michael.meeks@suse.com> | 2012-01-15 01:24:38 +0000 |
---|---|---|
committer | Michael Meeks <michael.meeks@suse.com> | 2012-01-16 09:28:29 +0000 |
commit | 955b18d41866508dd0d69704991c03d7d9479e5d (patch) | |
tree | 12864d0282a53ba66059bb558d4f72561e979200 /vcl | |
parent | vcl: introduce crystal clear separation between X11 Screens and DisplayScreens (diff) | |
download | core-955b18d41866508dd0d69704991c03d7d9479e5d.tar.gz core-955b18d41866508dd0d69704991c03d7d9479e5d.zip |
vcl: second part of fix for fdo#43458 - get xrandr / y positioning right
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/inc/vcl/wrkwin.hxx | 25 | ||||
-rw-r--r-- | vcl/source/window/wrkwin.cxx | 16 | ||||
-rw-r--r-- | vcl/unx/gtk/window/gtkframe.cxx | 2 |
3 files changed, 23 insertions, 20 deletions
diff --git a/vcl/inc/vcl/wrkwin.hxx b/vcl/inc/vcl/wrkwin.hxx index c58f6971ffc0..c9a3da94b0a2 100644 --- a/vcl/inc/vcl/wrkwin.hxx +++ b/vcl/inc/vcl/wrkwin.hxx @@ -80,30 +80,33 @@ public: virtual sal_Bool Close(); - /** The default value of nDisplay = -1 means "don't care" and - allows to backends to use any screen [** or display? terminology!] - they like (most probably the current one). + /** The default value of nDisplayScreen = -1 means "don't care" and + allows to backends to use any screen they like (most probably + the current one). NOTE: The default value cannot be 0, because 0 is a legitimate - screen number. + Display Screen number. */ - void ShowFullScreenMode( sal_Bool bFullScreenMode = sal_True, sal_Int32 nDisplay = -1 ); + void ShowFullScreenMode( sal_Bool bFullScreenMode = sal_True, + sal_Int32 nDisplayScreen = -1 ); void EndFullScreenMode() { ShowFullScreenMode( sal_False ); } - sal_Bool IsFullScreenMode() const { return mbFullScreenMode; } + sal_Bool IsFullScreenMode() const { return mbFullScreenMode; } - void StartPresentationMode( sal_Bool bPresentation = sal_True, sal_uInt16 nFlags = 0, sal_Int32 nDisplay = 0 ); + void StartPresentationMode( sal_Bool bPresentation = sal_True, + sal_uInt16 nFlags = 0, + sal_Int32 nDisplayScreen = 0 ); void EndPresentationMode() { StartPresentationMode( sal_False ); } - sal_Bool IsPresentationMode() const { return mbPresentationMode; } + sal_Bool IsPresentationMode() const { return mbPresentationMode; } - sal_Bool IsMinimized() const; + sal_Bool IsMinimized() const; - sal_Bool SetPluginParent( SystemParentData* pParent ); + sal_Bool SetPluginParent( SystemParentData* pParent ); void Minimize(); void Restore(); void Maximize( sal_Bool bMaximize = sal_True ); - sal_Bool IsMaximized() const; + sal_Bool IsMaximized() const; }; #endif // _SV_WRKWIN_HXX diff --git a/vcl/source/window/wrkwin.cxx b/vcl/source/window/wrkwin.cxx index 08af25cd0891..822f97953de8 100644 --- a/vcl/source/window/wrkwin.cxx +++ b/vcl/source/window/wrkwin.cxx @@ -178,15 +178,15 @@ WorkWindow::~WorkWindow() // ----------------------------------------------------------------------- -void WorkWindow::ShowFullScreenMode( sal_Bool bFullScreenMode, sal_Int32 nDisplay ) +void WorkWindow::ShowFullScreenMode( sal_Bool bFullScreenMode, sal_Int32 nDisplayScreen ) { if ( !mbFullScreenMode == !bFullScreenMode ) return; - if( (nDisplay < 0) - || (nDisplay >= static_cast<sal_Int32>(Application::GetScreenCount()) ) ) + if( (nDisplayScreen < 0) + || (nDisplayScreen >= static_cast<sal_Int32>(Application::GetScreenCount()) ) ) { - nDisplay = GetScreenNumber(); + nDisplayScreen = GetScreenNumber(); } mbFullScreenMode = bFullScreenMode != 0; @@ -205,13 +205,13 @@ void WorkWindow::ShowFullScreenMode( sal_Bool bFullScreenMode, sal_Int32 nDispla } mpWindowImpl->mpFrameWindow->mpWindowImpl->mbWaitSystemResize = sal_True; - ImplGetFrame()->ShowFullScreen( bFullScreenMode, nDisplay ); + ImplGetFrame()->ShowFullScreen( bFullScreenMode, nDisplayScreen ); } } // ----------------------------------------------------------------------- -void WorkWindow::StartPresentationMode( sal_Bool bPresentation, sal_uInt16 nFlags, sal_Int32 nDisplay ) +void WorkWindow::StartPresentationMode( sal_Bool bPresentation, sal_uInt16 nFlags, sal_Int32 nDisplayScreen ) { if ( !bPresentation == !mbPresentationMode ) return; @@ -224,7 +224,7 @@ void WorkWindow::StartPresentationMode( sal_Bool bPresentation, sal_uInt16 nFlag mnPresentationFlags = nFlags; if ( !(mnPresentationFlags & PRESENTATION_NOFULLSCREEN) ) - ShowFullScreenMode( sal_True, nDisplay ); + ShowFullScreenMode( sal_True, nDisplayScreen ); if ( !mbSysChild ) { if ( mnPresentationFlags & PRESENTATION_HIDEALLAPPS ) @@ -246,7 +246,7 @@ void WorkWindow::StartPresentationMode( sal_Bool bPresentation, sal_uInt16 nFlag if ( mnPresentationFlags & PRESENTATION_HIDEALLAPPS ) mpWindowImpl->mpFrame->SetAlwaysOnTop( sal_False ); } - ShowFullScreenMode( mbPresentationFull, nDisplay ); + ShowFullScreenMode( mbPresentationFull, nDisplayScreen ); mbPresentationMode = sal_False; mbPresentationVisible = sal_False; diff --git a/vcl/unx/gtk/window/gtkframe.cxx b/vcl/unx/gtk/window/gtkframe.cxx index 0768093ef9fb..4869c4594873 100644 --- a/vcl/unx/gtk/window/gtkframe.cxx +++ b/vcl/unx/gtk/window/gtkframe.cxx @@ -1880,7 +1880,7 @@ void GtkSalFrame::SetScreen( unsigned int nNewScreen, int eType, Rectangle *pSiz if( eType == SET_FULLSCREEN ) { maGeometry.nX = aNewMonitor.x; - maGeometry.nY = aNewMonitor.x; + maGeometry.nY = aNewMonitor.y; maGeometry.nWidth = aNewMonitor.width; maGeometry.nHeight = aNewMonitor.height; m_nStyle |= SAL_FRAME_STYLE_PARTIAL_FULLSCREEN; |