X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3b7067a05dd2373eb4d6b1a2d6d5699232eaa333..3dd30495169b650e8a37699d714f183691d8f2c5:/src/gtk/window.cpp diff --git a/src/gtk/window.cpp b/src/gtk/window.cpp index 2b1d991e42..4178eddb57 100644 --- a/src/gtk/window.cpp +++ b/src/gtk/window.cpp @@ -923,7 +923,8 @@ gtk_window_key_press_callback( GtkWidget *WXUNUSED(widget), // We should let GTK+ IM filter key event first. According to GTK+ 2.0 API // docs, if IM filter returns true, no further processing should be done. // we should send the key_down event anyway. - bool intercepted_by_IM = gtk_im_context_filter_keypress(win->m_imData->context, gdk_event); + bool intercepted_by_IM = + gtk_im_context_filter_keypress(win->m_imData->context, gdk_event) != 0; win->m_imData->lastKeyEvent = NULL; if (intercepted_by_IM) { @@ -2567,11 +2568,10 @@ static gboolean queue_resize(void*) void wxWindowGTK::DoMoveWindow(int x, int y, int width, int height) { + gtk_widget_set_size_request(m_widget, width, height); GtkWidget* parent = gtk_widget_get_parent(m_widget); if (WX_IS_PIZZA(parent)) WX_PIZZA(parent)->move(m_widget, x, y, width, height); - else - gtk_widget_set_size_request(m_widget, width, height); // With GTK3, gtk_widget_queue_resize() is ignored while a size-allocate // is in progress. This situation is common in wxWidgets, since @@ -3418,7 +3418,7 @@ bool wxWindowGTK::DoNavigateIn(int flags) gboolean rc; g_signal_emit_by_name(parent->m_widget, "focus", dir, &rc); - return rc == TRUE; + return rc != 0; } } @@ -3884,7 +3884,7 @@ void wxWindowGTK::SetDoubleBuffered( bool on ) bool wxWindowGTK::IsDoubleBuffered() const { - return gtk_widget_get_double_buffered( m_wxwindow ); + return gtk_widget_get_double_buffered( m_wxwindow ) != 0; } void wxWindowGTK::ClearBackground() @@ -4152,9 +4152,9 @@ bool wxWindowGTK::IsTransparentBackgroundSupported(wxString* reason) const *reason = _("This program was compiled with a too old version of GTK+, " "please rebuild with GTK+ 2.12 or newer."); } -#endif // wxGTK_HAS_COMPOSITING_SUPPORT/!wxGTK_HAS_COMPOSITING_SUPPORT return false; +#endif // wxGTK_HAS_COMPOSITING_SUPPORT/!wxGTK_HAS_COMPOSITING_SUPPORT } // ----------------------------------------------------------------------------