summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2015-12-01 13:27:21 +0000
committerCaolán McNamara <caolanm@redhat.com>2015-12-01 13:29:18 +0000
commit585507a4127ff91d9360ca16938dbd36153aef0d (patch)
tree79e9ec943f4ed797627e18e5cb125e21f0fe26b6
parent7ac763db694a956cb1e4f82477a7f9fe993f1f1a (diff)
gtk3+wayland: wrong dialog sizes
use inner container, not outer toxic toplevel Change-Id: I44f2fe1e8e346e51e65158f7864293ef37732345
-rw-r--r--vcl/unx/gtk/gtksalframe.cxx10
1 files changed, 6 insertions, 4 deletions
diff --git a/vcl/unx/gtk/gtksalframe.cxx b/vcl/unx/gtk/gtksalframe.cxx
index 791e04e3245e..d147b496b1a2 100644
--- a/vcl/unx/gtk/gtksalframe.cxx
+++ b/vcl/unx/gtk/gtksalframe.cxx
@@ -943,22 +943,24 @@ void GtkSalFrame::moveWindow( long nX, long nY )
void GtkSalFrame::widget_set_size_request(long nWidth, long nHeight)
{
+#if !GTK_CHECK_VERSION(3,0,0)
gint nOrigwidth, nOrigheight;
gtk_window_get_size(GTK_WINDOW(m_pWindow), &nOrigwidth, &nOrigheight);
-#if !GTK_CHECK_VERSION(3,0,0)
if (nWidth > nOrigwidth || nHeight > nOrigheight)
{
m_bPaintsBlocked = true;
}
-#endif
gtk_widget_set_size_request(m_pWindow, nWidth, nHeight );
+#else
+ gtk_widget_set_size_request(GTK_WIDGET(m_pFixedContainer), nWidth, nHeight );
+#endif
}
void GtkSalFrame::window_resize(long nWidth, long nHeight)
{
+#if !GTK_CHECK_VERSION(3,0,0)
gint nOrigwidth, nOrigheight;
gtk_window_get_size(GTK_WINDOW(m_pWindow), &nOrigwidth, &nOrigheight);
-#if !GTK_CHECK_VERSION(3,0,0)
if (nWidth > nOrigwidth || nHeight > nOrigheight)
{
m_bPaintsBlocked = true;
@@ -1080,7 +1082,7 @@ void GtkSalFrame::InitCommon()
m_aMouseSignalIds.push_back(g_signal_connect( G_OBJECT(pEventWidget), "button-release-event", G_CALLBACK(signalButton), this ));
#if GTK_CHECK_VERSION(3,0,0)
g_signal_connect( G_OBJECT(m_pFixedContainer), "draw", G_CALLBACK(signalDraw), this );
- g_signal_connect( G_OBJECT(m_pWindow), "size-allocate", G_CALLBACK(sizeAllocated), this );
+ g_signal_connect( G_OBJECT(m_pFixedContainer), "size-allocate", G_CALLBACK(sizeAllocated), this );
#if GTK_CHECK_VERSION(3,14,0)
GtkGesture *pSwipe = gtk_gesture_swipe_new(pEventWidget);
g_signal_connect(pSwipe, "swipe", G_CALLBACK(gestureSwipe), this);