summaryrefslogtreecommitdiffstats
path: root/src/3rdparty/phonon/mmf/videooutput.cpp
diff options
context:
space:
mode:
authorGareth Stockwell <gareth.stockwell@sosco.com>2009-08-27 12:27:15 (GMT)
committerGareth Stockwell <gareth.stockwell@sosco.com>2009-08-28 12:30:26 (GMT)
commit559ef5cafeb39766a7481a37168e37e9cb315bb5 (patch)
treee5faeeb9cf901c054b659ea217095639bf2baeba /src/3rdparty/phonon/mmf/videooutput.cpp
parent104b5dc3b96f2d9d7fbae79ca1fcd303f3828d86 (diff)
downloadQt-559ef5cafeb39766a7481a37168e37e9cb315bb5.zip
Qt-559ef5cafeb39766a7481a37168e37e9cb315bb5.tar.gz
Qt-559ef5cafeb39766a7481a37168e37e9cb315bb5.tar.bz2
Wrapped code using QT_BEGIN/END_NAMESPACE macros
Diffstat (limited to 'src/3rdparty/phonon/mmf/videooutput.cpp')
-rw-r--r--src/3rdparty/phonon/mmf/videooutput.cpp18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/3rdparty/phonon/mmf/videooutput.cpp b/src/3rdparty/phonon/mmf/videooutput.cpp
index 171565b..6534b7b 100644
--- a/src/3rdparty/phonon/mmf/videooutput.cpp
+++ b/src/3rdparty/phonon/mmf/videooutput.cpp
@@ -24,6 +24,8 @@ along with this library. If not, see <http://www.gnu.org/licenses/>.
#include <QMoveEvent>
#include <QResizeEvent>
+QT_BEGIN_NAMESPACE
+
using namespace Phonon;
using namespace Phonon::MMF;
@@ -87,12 +89,15 @@ void VideoOutput::dump()
TRACE("maxSize %d %d", maximumWidth(), maximumHeight());
TRACE("sizeHint %d %d", sizeHint().width(), sizeHint().height());
- QWidget& parentWidget = *qobject_cast<QWidget*>(parent());
- TRACE("parent.isVisible %d", parentWidget.isVisible());
- TRACE("parent.pos %d %d", parentWidget.x(), parentWidget.y());
- TRACE("parent.size %d %d", parentWidget.size().width(), parentWidget.size().height());
- TRACE("parent.maxSize %d %d", parentWidget.maximumWidth(), parentWidget.maximumHeight());
- TRACE("parent.sizeHint %d %d", parentWidget.sizeHint().width(), parentWidget.sizeHint().height());
+ QWidget* parentWidget = qobject_cast<QWidget*>(parent());
+ if(parentWidget)
+ {
+ TRACE("parent.isVisible %d", parentWidget->isVisible());
+ TRACE("parent.pos %d %d", parentWidget->x(), parentWidget->y());
+ TRACE("parent.size %d %d", parentWidget->size().width(), parentWidget->size().height());
+ TRACE("parent.maxSize %d %d", parentWidget->maximumWidth(), parentWidget->maximumHeight());
+ TRACE("parent.sizeHint %d %d", parentWidget->sizeHint().width(), parentWidget->sizeHint().height());
+ }
TRACE_EXIT_0();
}
@@ -214,4 +219,5 @@ void MMF::VideoOutput::moveEvent(QMoveEvent* event)
//-----------------------------------------------------------------------------
+QT_END_NAMESPACE