Commit 595ad46f authored by Christoph Pfister's avatar Christoph Pfister

fix MediaWidget initialization (emit state events)

parent 30a11b64
......@@ -43,6 +43,13 @@ AbstractMediaWidget::~AbstractMediaWidget()
{
}
void AbstractMediaWidget::connectToMediaWidget(MediaWidget *mediaWidget_)
{
mediaWidget = mediaWidget_;
addPendingUpdates(PlaybackStatus | CurrentTotalTime | Seekable | Metadata | AudioStreams |
Subtitles | Titles | Chapters | Angles | DvdMenu | VideoSize);
}
void AbstractMediaWidget::addPendingUpdates(PendingUpdates pendingUpdatesToBeAdded)
{
while (true) {
......
......@@ -29,7 +29,7 @@ public:
explicit AbstractMediaWidget(QWidget *parent);
virtual ~AbstractMediaWidget();
void setMediaWidget(MediaWidget *mediaWidget_) { mediaWidget = mediaWidget_; }
void connectToMediaWidget(MediaWidget *mediaWidget_);
// zero-based numbering is used everywhere (e.g. first audio channel = 0)
......
......@@ -69,7 +69,7 @@ MediaWidget::MediaWidget(KMenu *menu_, KToolBar *toolBar, KActionCollection *col
backend = new DummyMediaWidget(this);
}
backend->setMediaWidget(this);
backend->connectToMediaWidget(this);
layout->addWidget(backend);
osdWidget = new OsdWidget(this);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment