Various compilation scripts & patches for Linux programs.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

72 lines
1.9 KiB

7 years ago
  1. --- a/src/panels/information/phononwidget.cpp
  2. +++ b/src/panels/information/phononwidget.cpp
  3. @@ -30,6 +30,7 @@
  4. #include <QHBoxLayout>
  5. #include <QShowEvent>
  6. #include <QToolButton>
  7. +#include <QCheckBox>
  8. #include <QDialog>
  9. #include <QIcon>
  10. #include <KIconLoader>
  11. @@ -69,6 +70,7 @@
  12. m_topLayout(0),
  13. m_media(0),
  14. m_seekSlider(0),
  15. + m_playAut(0),
  16. m_audioOutput(0),
  17. m_videoPlayer(0)
  18. {
  19. @@ -79,6 +81,9 @@
  20. if (m_url != url) {
  21. stop(); // emits playingStopped() signal
  22. m_url = url;
  23. + if(m_playAut ->isChecked()){
  24. + play();
  25. + }
  26. }
  27. }
  28. @@ -115,6 +120,8 @@
  29. controlsLayout->setMargin(0);
  30. controlsLayout->setSpacing(0);
  31. + m_playAut = new QCheckBox(this);
  32. +
  33. m_playButton = new QToolButton(this);
  34. m_stopButton = new QToolButton(this);
  35. m_seekSlider = new Phonon::SeekSlider(this);
  36. @@ -122,11 +129,15 @@
  37. controlsLayout->addWidget(m_playButton);
  38. controlsLayout->addWidget(m_stopButton);
  39. controlsLayout->addWidget(m_seekSlider);
  40. + controlsLayout->addWidget(m_playAut);
  41. m_topLayout->addLayout(controlsLayout);
  42. const int smallIconSize = IconSize(KIconLoader::Small);
  43. const QSize buttonSize(smallIconSize, smallIconSize);
  44. +
  45. + m_playAut->setToolTip(i18n("play automatically"));
  46. + m_playAut->setIconSize(buttonSize);
  47. m_playButton->setToolTip(i18n("play"));
  48. m_playButton->setIconSize(buttonSize);
  49. --- a/src/panels/information/phononwidget.h
  50. +++ b/src/panels/information/phononwidget.h
  51. @@ -38,6 +38,7 @@
  52. class EmbeddedVideoPlayer;
  53. class QToolButton;
  54. class QVBoxLayout;
  55. +class QCheckBox;
  56. class PhononWidget : public QWidget
  57. {
  58. @@ -81,6 +82,7 @@
  59. QToolButton *m_playButton;
  60. QToolButton *m_stopButton;
  61. + QCheckBox *m_playAut;
  62. QVBoxLayout *m_topLayout;
  63. Phonon::MediaObject *m_media;