optimize manual blits by not forcing them at gPainter::end, but instead call flush...
authorFelix Domke <tmbinc@elitedvb.net>
Tue, 9 Jun 2009 01:09:02 +0000 (03:09 +0200)
committerFelix Domke <tmbinc@elitedvb.net>
Tue, 9 Jun 2009 01:09:02 +0000 (03:09 +0200)
lib/gdi/grc.cpp
lib/gdi/grc.h
lib/gui/ewidgetdesktop.cpp

index 5ef68332101906660ce4671310490d9a709e72c8..4b2c5550ccd13a67815a926085b710bf4aea56b9 100644 (file)
@@ -569,7 +569,7 @@ void gPainter::setCompositing(gCompositingData *comp)
        m_rc->submit(o);
 }
 
-void gPainter::end()
+void gPainter::flush()
 {
        if ( m_dc->islocked() )
                return;
@@ -579,6 +579,12 @@ void gPainter::end()
        m_rc->submit(o);
 }
 
+void gPainter::end()
+{
+       if ( m_dc->islocked() )
+               return;
+}
+
 gDC::gDC()
 {
        m_spinner_pic = 0;
index 3b6ed3255744943226af292bae563c2d265677db..5d0106b3b98102ec36f198fe18797eaf7d3504b4 100644 (file)
@@ -262,6 +262,8 @@ public:
        void flip();
        void notify();
        void setCompositing(gCompositingData *comp);
+       
+       void flush();
 };
 
 class gDC: public iObject
index fa53235929780d7f5759e52bdbc67d1f8975c41d..98bc1f7dce08334776d40e6002ec6968d21c3ef0 100644 (file)
@@ -332,6 +332,10 @@ void eWidgetDesktop::paint()
        if (m_comp_mode == cmBuffered)
        {
 //             redrawComposition(0);
+       } else
+       {
+               gPainter painter(m_screen.m_dc);
+               painter.flush();
        }
 }