diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/3rdparty/phonon/ds9/mediagraph.cpp | 30 | ||||
-rw-r--r-- | src/plugins/accessible/widgets/rangecontrols.cpp | 18 | ||||
-rw-r--r-- | src/plugins/accessible/widgets/simplewidgets.cpp | 4 |
3 files changed, 24 insertions, 28 deletions
diff --git a/src/3rdparty/phonon/ds9/mediagraph.cpp b/src/3rdparty/phonon/ds9/mediagraph.cpp index 3e7a68b..153cd7e 100644 --- a/src/3rdparty/phonon/ds9/mediagraph.cpp +++ b/src/3rdparty/phonon/ds9/mediagraph.cpp @@ -781,6 +781,23 @@ namespace Phonon } } + const QList<OutputPin> demuxOutputs = BackendNode::pins(m_demux, PINDIR_OUTPUT); + for (int i = 0; i < demuxOutputs.count(); ++i) { + //...and the output must be decoded + QAMMediaType type; + hr = demuxOutputs.at(i)->ConnectionMediaType(&type); + if (FAILED(hr)) { + continue; + } + + if (type.majortype == MEDIATYPE_Video) { + m_hasVideo = true; + } else if (type.majortype == MEDIATYPE_Audio) { + m_hasAudio = true; + } + } + + for (int i = 0; i < m_decoders.count(); ++i) { QList<Filter> chain = getFilterChain(m_demux, m_decoders.at(i)); for (int i = 0; i < chain.count(); ++i) { @@ -806,14 +823,11 @@ namespace Phonon } //we need to do something smart to detect if the streams are unencoded - if (m_demux) { - const QList<OutputPin> outputs = BackendNode::pins(m_demux, PINDIR_OUTPUT); - for (int i = 0; i < outputs.count(); ++i) { - const OutputPin &out = outputs.at(i); - InputPin pin; - if (out->ConnectedTo(pin.pparam()) == HRESULT(VFW_E_NOT_CONNECTED)) { - m_decoderPins += out; //unconnected outputs can be decoded outputs - } + for (int i = 0; i < demuxOutputs.count(); ++i) { + const OutputPin &out = demuxOutputs.at(i); + InputPin pin; + if (out->ConnectedTo(pin.pparam()) == HRESULT(VFW_E_NOT_CONNECTED)) { + m_decoderPins += out; //unconnected outputs can be decoded outputs } } diff --git a/src/plugins/accessible/widgets/rangecontrols.cpp b/src/plugins/accessible/widgets/rangecontrols.cpp index 1f5407a..736ed88 100644 --- a/src/plugins/accessible/widgets/rangecontrols.cpp +++ b/src/plugins/accessible/widgets/rangecontrols.cpp @@ -83,8 +83,6 @@ QAbstractSpinBox *QAccessibleAbstractSpinBox::abstractSpinBox() const /*! \reimp */ int QAccessibleAbstractSpinBox::childCount() const { - if (!abstractSpinBox()->isVisible()) - return 0; return ValueDown; } @@ -344,8 +342,6 @@ QDoubleSpinBox *QAccessibleDoubleSpinBox::doubleSpinBox() const /*! \reimp */ int QAccessibleDoubleSpinBox::childCount() const { - if (!doubleSpinBox()->isVisible()) - return 0; return ValueDown; } @@ -410,8 +406,6 @@ QVariant QAccessibleDoubleSpinBox::invokeMethodEx(QAccessible::Method, int, cons /*! \reimp */ QString QAccessibleDoubleSpinBox::text(Text textType, int child) const { - if (!doubleSpinBox()->isVisible()) - return QString(); switch (textType) { case Name: if (child == ValueUp) @@ -540,16 +534,12 @@ QRect QAccessibleScrollBar::rect(int child) const /*! \reimp */ int QAccessibleScrollBar::childCount() const { - if (!scrollBar()->isVisible()) - return 0; return LineDown; } /*! \reimp */ QString QAccessibleScrollBar::text(Text t, int child) const { - if (!scrollBar()->isVisible()) - return QString(); switch (t) { case Value: if (!child || child == Position) @@ -698,16 +688,12 @@ QRect QAccessibleSlider::rect(int child) const /*! \reimp */ int QAccessibleSlider::childCount() const { - if (!slider()->isVisible()) - return 0; return PageRight; } /*! \reimp */ QString QAccessibleSlider::text(Text t, int child) const { - if (!slider()->isVisible()) - return QString(); switch (t) { case Value: if (!child || child == 2) @@ -932,15 +918,11 @@ QRect QAccessibleDial::rect(int child) const int QAccessibleDial::childCount() const { - if (!dial()->isVisible()) - return 0; return SliderHandle; } QString QAccessibleDial::text(Text textType, int child) const { - if (!dial()->isVisible()) - return QString(); if (textType == Value && child >= Self && child <= SliderHandle) return QString::number(dial()->value()); if (textType == Name) { diff --git a/src/plugins/accessible/widgets/simplewidgets.cpp b/src/plugins/accessible/widgets/simplewidgets.cpp index aa64630..8001eae 100644 --- a/src/plugins/accessible/widgets/simplewidgets.cpp +++ b/src/plugins/accessible/widgets/simplewidgets.cpp @@ -176,7 +176,7 @@ QString QAccessibleButton::text(Text t, int child) const break; } if (str.isEmpty()) - str = QAccessibleWidgetEx::text(t, child);; + str = QAccessibleWidgetEx::text(t, child); return qt_accStripAmp(str); } @@ -396,7 +396,7 @@ QString QAccessibleToolButton::text(Text t, int child) const QString str; switch (t) { case Name: - str = toolButton()->text(); + str = toolButton()->accessibleName(); if (str.isEmpty()) str = toolButton()->text(); break; |