Changeset View
Standalone View
src/panels/information/phononwidget.cpp
Show All 19 Lines | |||||
20 | 20 | | |||
21 | #include "phononwidget.h" | 21 | #include "phononwidget.h" | ||
22 | 22 | | |||
23 | #include <KIconLoader> | 23 | #include <KIconLoader> | ||
24 | #include <KLocalizedString> | 24 | #include <KLocalizedString> | ||
25 | #include <Phonon/AudioOutput> | 25 | #include <Phonon/AudioOutput> | ||
26 | #include <Phonon/MediaObject> | 26 | #include <Phonon/MediaObject> | ||
27 | #include <Phonon/SeekSlider> | 27 | #include <Phonon/SeekSlider> | ||
28 | #include <Phonon/VideoWidget> | 28 | #include <Phonon/VideoWidget> | ||
29 | 29 | | |||
30 | #include <QShowEvent> | 30 | #include <QShowEvent> | ||
31 | #include <QToolButton> | 31 | #include <QToolButton> | ||
rkflx: Was this part of the original Diff people reviewed? | |||||
rominf: No. | |||||
markg: Nope... | |||||
-1 Those are GCC specific (what about clang and MSVC?). At least, that's my opinion, not sure about others. markg: -1
Those are GCC specific (what about clang and MSVC?).
Phonon is the place to fix that. If… | |||||
I don't think that there is a cross-compiler way of ignoring warnings. In my opinion is better to make the code more ugly but to get rid of all warnings, because it's easier to spot a warning when it's only the one. rominf: I don't think that there is a cross-compiler way of ignoring warnings. In my opinion is better… | |||||
I usually tend to agree to changes that reduce compile warnings as i hate warnings too. In fact, adding override in phonon (to Phonon::VideoWidget::mouseMoveEvent and Phonon::VideoWidget::event would solve it, but it's probably not that easy). markg: I usually tend to agree to changes that reduce compile warnings as i hate warnings too.
But in… | |||||
32 | #include <QVBoxLayout> | 32 | #include <QVBoxLayout> | ||
33 | 33 | | |||
34 | class EmbeddedVideoPlayer : public Phonon::VideoWidget | 34 | class EmbeddedVideoPlayer : public Phonon::VideoWidget | ||
35 | { | 35 | { | ||
36 | Q_OBJECT | 36 | Q_OBJECT | ||
37 | 37 | | |||
38 | public: | 38 | public: | ||
39 | EmbeddedVideoPlayer(QWidget *parent = nullptr) : | 39 | EmbeddedVideoPlayer(QWidget *parent = nullptr) : | ||
▲ Show 20 Lines • Show All 122 Lines • ▼ Show 20 Line(s) | 161 | case Phonon::BufferingState: | |||
162 | m_stopButton->show(); | 162 | m_stopButton->show(); | ||
163 | m_playButton->hide(); | 163 | m_playButton->hide(); | ||
164 | break; | 164 | break; | ||
165 | case Phonon::StoppedState: | 165 | case Phonon::StoppedState: | ||
166 | if (m_videoPlayer) { | 166 | if (m_videoPlayer) { | ||
167 | m_videoPlayer->hide(); | 167 | m_videoPlayer->hide(); | ||
168 | } | 168 | } | ||
169 | emit hasVideoChanged(false); | 169 | emit hasVideoChanged(false); | ||
170 | // fall through | 170 | Q_FALLTHROUGH(); | ||
This requires Qt 5.8, please bump QT_MIN_VERSION defined in the top-level CMakeLists.txt. elvisangelaccio: This requires Qt 5.8, please bump `QT_MIN_VERSION` defined in the top-level CMakeLists.txt. | |||||
171 | default: | 171 | default: | ||
172 | m_stopButton->hide(); | 172 | m_stopButton->hide(); | ||
173 | m_playButton->show(); | 173 | m_playButton->show(); | ||
174 | break; | 174 | break; | ||
175 | } | 175 | } | ||
176 | setUpdatesEnabled(true); | 176 | setUpdatesEnabled(true); | ||
177 | } | 177 | } | ||
178 | 178 | | |||
▲ Show 20 Lines • Show All 54 Lines • Show Last 20 Lines |
Was this part of the original Diff people reviewed?