summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (show whitespace changes)
-rw-r--r--noncore/multimedia/opieplayer2/xinevideowidget.cpp18
1 files changed, 6 insertions, 12 deletions
diff --git a/noncore/multimedia/opieplayer2/xinevideowidget.cpp b/noncore/multimedia/opieplayer2/xinevideowidget.cpp
index 7f59085..78ebe19 100644
--- a/noncore/multimedia/opieplayer2/xinevideowidget.cpp
+++ b/noncore/multimedia/opieplayer2/xinevideowidget.cpp
@@ -1,3 +1,2 @@
-
/*
                This file is part of the Opie Project
@@ -216,4 +215,7 @@ void XineVideoWidget::paintEvent2 ( QPaintEvent * )
int middle_h = _vh/2;
m_thisframe.setRect(width()/2-middle_w,height()/2-middle_h,_vw,_vh);
+
+ {
+ // is this stuff realy needed? it seems working without, too.
QRect topFill,rightFill,leftFill,downFill;
topFill. setRect(0,0 ,width(),m_thisframe.top());
@@ -234,4 +236,6 @@ void XineVideoWidget::paintEvent2 ( QPaintEvent * )
p.fillRect(leftFill,black);
}
+
+ }
uchar *fb = dp. frameBuffer ( );
uchar *frame = m_buff;
@@ -268,11 +272,4 @@ void XineVideoWidget::paintEvent2 ( QPaintEvent * )
}
}
-
-
- {
- // QVFB hack by Martin Jones
- // We need to "touch" all affected clip rects with a normal QPainter in addition to the QDirectPainter
- p.fillRect(QRect(mapFromGlobal (m_thisframe. topLeft ( )), m_thisframe.size ()),QBrush(NoBrush));
- }
}
}
@@ -312,7 +309,4 @@ void XineVideoWidget::setVideoFrame ( uchar* img, int w, int h, int bpl )
m_buff = 0;
}
- } else if (l==0){
- delete[] m_buff;
- m_buff = 0;
}
m_lastsize = l;
@@ -324,5 +318,5 @@ void XineVideoWidget::setVideoFrame ( uchar* img, int w, int h, int bpl )
} // Release Mutex
- paintEvent2(0);
+ if (m_buff) paintEvent2(0);
}