]> git.sur5r.net Git - minitube/commitdiff
Painting optimization
authorFlavio Tordini <flavio.tordini@gmail.com>
Sun, 23 Aug 2009 08:58:16 +0000 (10:58 +0200)
committerFlavio Tordini <flavio.tordini@gmail.com>
Sun, 23 Aug 2009 08:58:16 +0000 (10:58 +0200)
src/SearchView.cpp

index 6ed908dd11c17ed119bf12481dae27ae37a7eaaa..71f16d674ff2152d84a7f13a225eba54c9ef0435 100644 (file)
@@ -6,6 +6,12 @@ static const int PADDING = 40;
 
 SearchView::SearchView(QWidget *parent) : QWidget(parent) {
 
+#ifdef Q_WS_MAC
+    // speedup painting since we'll paint the whole background
+    // by ourselves anyway in paintEvent()
+    setAttribute(Qt::WA_OpaquePaintEvent);
+#endif
+
     QFont biggerFont;
     biggerFont.setPointSize(biggerFont.pointSize()*1.5);