From 24a00c944aace8d7627c1eb0d7cc0ebf40731c57 Mon Sep 17 00:00:00 2001 From: simon Date: Mon, 02 Dec 2002 23:22:22 +0000 Subject: - AudioWidget and VideoWidget are no more singletons via audioUI and videoUI. this allows switching skins at run-time (the appropriate connections are already made and it works quite nicely :) --- (limited to 'noncore/multimedia/opieplayer2/main.cpp') diff --git a/noncore/multimedia/opieplayer2/main.cpp b/noncore/multimedia/opieplayer2/main.cpp index 7d11ca0..7fc7b94 100644 --- a/noncore/multimedia/opieplayer2/main.cpp +++ b/noncore/multimedia/opieplayer2/main.cpp @@ -2,13 +2,9 @@ #include #include "mediaplayerstate.h" #include "playlistwidget.h" -#include "audiowidget.h" -#include "videowidget.h" #include "mediaplayer.h" PlayListWidget *playList; -AudioWidget *audioUI; -VideoWidget *videoUI; int main(int argc, char **argv) { QPEApplication a(argc,argv); @@ -17,12 +13,9 @@ int main(int argc, char **argv) { PlayListWidget pl( st, 0, "playList" ); playList = &pl; pl.showMaximized(); - AudioWidget aw( st, 0, "audioUI" ); - audioUI = &aw; - VideoWidget vw( st, 0, "videoUI" ); - videoUI = &vw; - a.processEvents(); MediaPlayer mp( st, 0, "mediaPlayer" ); + QObject::connect( &pl, SIGNAL( skinSelected() ), + &mp, SLOT( recreateAudioAndVideoWidgets() ) ); a.showMainDocumentWidget(&pl); -- cgit v0.9.0.2