[Libreoffice-commits] core.git: Branch 'libreoffice-5-2' - vcl/source vcl/unx

Caolán McNamara caolanm at redhat.com
Wed Nov 23 11:35:15 UTC 2016


 vcl/source/window/syswin.cxx  |    4 ----
 vcl/unx/gtk3/gtk3gtkframe.cxx |    4 +++-
 2 files changed, 3 insertions(+), 5 deletions(-)

New commits:
commit 37ded4ac7b1fe91bb08eaada29d3514570432073
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Tue Nov 15 15:05:44 2016 +0000

    Resolves: tdf#102957 revert SetMinOutputSizePixel workaround
    
    of
    
    commit afeddaf7e0d11ad9b1df0c80bcc3f50caa87e21a
    Author: Caolán McNamara <caolanm at redhat.com>
    Date:   Wed Dec 16 10:46:10 2015 +0000
    
        Related: rhbz#1281906 set a min size on un-resizeable non-layout dialogs
    
    and using a mixture of gtk_window_set_default_size before its visible, and
    gtk_window_set_default_size + gtk_window_resize after its shown now works for
    me under wayland so the original problem can be solved that way
    
    Change-Id: Iaf8fd3019a7e902ad07b6825f919c6f25288e9b7
    (cherry picked from commit 7e2ef433d29fca84ed27a9203b5761dc8dbd8bf8)
    Reviewed-on: https://gerrit.libreoffice.org/30875
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>

diff --git a/vcl/source/window/syswin.cxx b/vcl/source/window/syswin.cxx
index 660328b..6603de2 100644
--- a/vcl/source/window/syswin.cxx
+++ b/vcl/source/window/syswin.cxx
@@ -1113,10 +1113,6 @@ void SystemWindow::DoInitialLayout()
         mbIsCalculatingInitialLayoutSize = false;
         mbInitialLayoutDone = true;
     }
-    else if (IsDialog() && !(GetStyle() & WB_SIZEABLE))
-    {
-        SetMinOutputSizePixel(GetSizePixel());
-    }
 }
 
 void SystemWindow::doDeferredInit(WinBits /*nBits*/)
diff --git a/vcl/unx/gtk3/gtk3gtkframe.cxx b/vcl/unx/gtk3/gtk3gtkframe.cxx
index ecd77ee..d74f7b8 100644
--- a/vcl/unx/gtk3/gtk3gtkframe.cxx
+++ b/vcl/unx/gtk3/gtk3gtkframe.cxx
@@ -884,7 +884,9 @@ void GtkSalFrame::window_resize(long nWidth, long nHeight)
 {
     m_nWidthRequest = nWidth;
     m_nHeightRequest = nHeight;
-    gtk_window_resize(GTK_WINDOW(m_pWindow), nWidth, nHeight);
+    gtk_window_set_default_size(GTK_WINDOW(m_pWindow), nWidth, nHeight);
+    if (gtk_widget_get_visible(m_pWindow))
+        gtk_window_resize(GTK_WINDOW(m_pWindow), nWidth, nHeight);
 }
 
 void GtkSalFrame::resizeWindow( long nWidth, long nHeight )


More information about the Libreoffice-commits mailing list