[Libreoffice-commits] core.git: vcl/inc vcl/source vcl/unx

Caolán McNamara caolanm at redhat.com
Thu Sep 22 16:25:49 UTC 2016


 vcl/inc/salframe.hxx          |    4 ----
 vcl/source/app/salvtables.cxx |    3 +--
 vcl/source/window/paint.cxx   |    3 +--
 vcl/unx/gtk/gtksalframe.cxx   |   14 --------------
 4 files changed, 2 insertions(+), 22 deletions(-)

New commits:
commit 99ee7deaf0a7a61bc74e8cb2d8a654fb675f50bb
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Thu Sep 22 17:19:21 2016 +0100

    Resolves: tdf#102347 configure size/expose might never come...
    
    if you request a size you might not get it.
    
    This attempt dating through...
    
    commit 6dc1d2706f519d91617ac1a12fc2051d97ef98c0
    Author: Caolán McNamara <caolanm at redhat.com>
    Date:   Mon Jun 15 10:56:33 2015 +0100
    
        another stab at tdf#91393
    
        block paints only if the new requested size is larger than the original and
        unblock on explicit expose events as well as configure ones
    
    ...
    
    commit 8f324aebfb94c4b2023894121b954ad4f35eb395
    Author: Caolán McNamara <caolanm at redhat.com>
    Date:   Sun Jun 14 15:49:56 2015 +0100
    
        Resolves: tdf#91393 autotext (etc) not fully drawn
    
    ...
    
    commit e6a1956034c98204e30b0ca40330249d6f6f8155
    Author: Jan Holesovsky <kendy at collabora.com>
    Date:   Fri Jun 12 15:36:03 2015 +0200
    
        tdf#91301: Don't cache incomplete tabs.
    
        After introduction of the Idle processing, something has changed so
        that the underlying GetGdkWindow() does not update its size fast enough;
        even though the gtk_window_resize() is called before the Window::Erase()
        (that actually paints the background) etc.
    
    is all junk. I don't see the original problem of tdf#91393 or tdf#91301 anymore
    under gtk2 after reverting this yet anyway to see if they need another fix.
    
    Change-Id: Ide071eba279de726a9c6a80884bc9021c8914d9d

diff --git a/vcl/inc/salframe.hxx b/vcl/inc/salframe.hxx
index 16b2b52..a9654b8 100644
--- a/vcl/inc/salframe.hxx
+++ b/vcl/inc/salframe.hxx
@@ -104,8 +104,6 @@ class VCL_PLUGIN_PUBLIC SalFrame
     : public vcl::DeletionNotifier
     , public SalGeometryProvider
 {
-protected:
-    bool                    m_bPaintsBlocked;
 private:
     // the VCL window corresponding to this frame
     VclPtr<vcl::Window>     m_pWindow;
@@ -280,8 +278,6 @@ public:
     // (e.g. input methods, printer update handlers).
     long                    CallCallback( SalEvent nEvent, const void* pEvent ) const
         { return m_pProc ? long(m_pProc( m_pWindow, nEvent, pEvent )) : 0; }
-
-    bool PaintsBlocked() const { return m_bPaintsBlocked; }
 };
 
 #endif // INCLUDED_VCL_INC_SALFRAME_HXX
diff --git a/vcl/source/app/salvtables.cxx b/vcl/source/app/salvtables.cxx
index 3748eb2..12cee86 100644
--- a/vcl/source/app/salvtables.cxx
+++ b/vcl/source/app/salvtables.cxx
@@ -30,8 +30,7 @@
 
 
 SalFrame::SalFrame()
-    : m_bPaintsBlocked(false)
-    , m_pWindow(nullptr)
+    : m_pWindow(nullptr)
     , m_pProc(nullptr)
 {
 }
diff --git a/vcl/source/window/paint.cxx b/vcl/source/window/paint.cxx
index cc66017..2c2c943 100644
--- a/vcl/source/window/paint.cxx
+++ b/vcl/source/window/paint.cxx
@@ -655,8 +655,7 @@ IMPL_LINK_NOARG_TYPED(Window, ImplHandlePaintHdl, Idle *, void)
 
     // save paint events until resizing or initial sizing done
     if (mpWindowImpl->mbFrame &&
-        (mpWindowImpl->mpFrameData->maResizeIdle.IsActive() ||
-         mpWindowImpl->mpFrame->PaintsBlocked()))
+        mpWindowImpl->mpFrameData->maResizeIdle.IsActive())
     {
         mpWindowImpl->mpFrameData->maPaintIdle.Start();
     }
diff --git a/vcl/unx/gtk/gtksalframe.cxx b/vcl/unx/gtk/gtksalframe.cxx
index 9167a3f..529128e 100644
--- a/vcl/unx/gtk/gtksalframe.cxx
+++ b/vcl/unx/gtk/gtksalframe.cxx
@@ -861,23 +861,11 @@ void GtkSalFrame::moveWindow( long nX, long nY )
 
 void GtkSalFrame::widget_set_size_request(long nWidth, long nHeight)
 {
-    gint nOrigwidth, nOrigheight;
-    gtk_window_get_size(GTK_WINDOW(m_pWindow), &nOrigwidth, &nOrigheight);
-    if (nWidth > nOrigwidth || nHeight > nOrigheight)
-    {
-        m_bPaintsBlocked = true;
-    }
     gtk_widget_set_size_request(m_pWindow, nWidth, nHeight );
 }
 
 void GtkSalFrame::window_resize(long nWidth, long nHeight)
 {
-    gint nOrigwidth, nOrigheight;
-    gtk_window_get_size(GTK_WINDOW(m_pWindow), &nOrigwidth, &nOrigheight);
-    if (nWidth > nOrigwidth || nHeight > nOrigheight)
-    {
-        m_bPaintsBlocked = true;
-    }
     gtk_window_resize(GTK_WINDOW(m_pWindow), nWidth, nHeight);
 }
 
@@ -2894,7 +2882,6 @@ gboolean GtkSalFrame::signalCrossing( GtkWidget*, GdkEventCrossing* pEvent, gpoi
 gboolean GtkSalFrame::signalExpose( GtkWidget*, GdkEventExpose* pEvent, gpointer frame )
 {
     GtkSalFrame* pThis = static_cast<GtkSalFrame*>(frame);
-    pThis->m_bPaintsBlocked = false;
 
     struct SalPaintEvent aEvent( pEvent->area.x, pEvent->area.y, pEvent->area.width, pEvent->area.height, OpenGLHelper::isVCLOpenGLEnabled() );
 
@@ -2906,7 +2893,6 @@ gboolean GtkSalFrame::signalExpose( GtkWidget*, GdkEventExpose* pEvent, gpointer
 gboolean GtkSalFrame::signalConfigure( GtkWidget*, GdkEventConfigure* pEvent, gpointer frame )
 {
     GtkSalFrame* pThis = static_cast<GtkSalFrame*>(frame);
-    pThis->m_bPaintsBlocked = false;
 
     bool bMoved = false, bSized = false;
     int x = pEvent->x, y = pEvent->y;


More information about the Libreoffice-commits mailing list