aboutsummaryrefslogtreecommitdiff
path: root/src-qt5/desktop-utils/lumina-mediaplayer
diff options
context:
space:
mode:
authorWeblate <noreply@weblate.org>2017-08-08 12:59:40 +0000
committerWeblate <noreply@weblate.org>2017-08-08 12:59:40 +0000
commita99ff5984b9f327d5cbf0de9b3caa447960fd846 (patch)
treecbc913d11641ecbc42a3fb405cbad84d6805d6a0 /src-qt5/desktop-utils/lumina-mediaplayer
parentTranslated using Weblate (French) (diff)
parentTranslated using Weblate (Czech) (diff)
downloadlumina-a99ff5984b9f327d5cbf0de9b3caa447960fd846.tar.gz
lumina-a99ff5984b9f327d5cbf0de9b3caa447960fd846.tar.bz2
lumina-a99ff5984b9f327d5cbf0de9b3caa447960fd846.zip
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'src-qt5/desktop-utils/lumina-mediaplayer')
-rw-r--r--src-qt5/desktop-utils/lumina-mediaplayer/main.cpp1
-rw-r--r--src-qt5/desktop-utils/lumina-mediaplayer/mainUI.cpp12
2 files changed, 7 insertions, 6 deletions
diff --git a/src-qt5/desktop-utils/lumina-mediaplayer/main.cpp b/src-qt5/desktop-utils/lumina-mediaplayer/main.cpp
index 9eebff9f..18b6d73e 100644
--- a/src-qt5/desktop-utils/lumina-mediaplayer/main.cpp
+++ b/src-qt5/desktop-utils/lumina-mediaplayer/main.cpp
@@ -16,6 +16,7 @@
int main(int argc, char *argv[]) {
LTHEME::LoadCustomEnvSettings();
LSingleApplication a(argc, argv, "l-mediap");
+ if(!a.isPrimaryProcess()){ return 0; }
//Now go ahead and setup the app
QStringList args;
for(int i=1; i<argc; i++){
diff --git a/src-qt5/desktop-utils/lumina-mediaplayer/mainUI.cpp b/src-qt5/desktop-utils/lumina-mediaplayer/mainUI.cpp
index dfd859d7..cfb6823c 100644
--- a/src-qt5/desktop-utils/lumina-mediaplayer/mainUI.cpp
+++ b/src-qt5/desktop-utils/lumina-mediaplayer/mainUI.cpp
@@ -22,7 +22,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI()){
ui->setupUi(this);
SETTINGS = LUtils::openSettings("lumina-desktop","lumina-mediaplayer",this);
closing = false;
- DISABLE_VIDEO = true; //add a toggle in the UI for this later
+ DISABLE_VIDEO = false; //add a toggle in the UI for this later
//Any special UI changes
QWidget *spacer = new QWidget(this);
spacer->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Preferred);
@@ -69,7 +69,7 @@ void MainUI::loadArguments(QStringList args){
void MainUI::setupPlayer(){
PLAYER = new QMediaPlayer(this); //base multimedia object
VIDEO = new QVideoWidget(this); //output to this widget for video
- PLAYLIST = new QMediaPlaylist(PLAYER); //pull from this playlist
+ PLAYLIST = new QMediaPlaylist(PLAYER); //pull from this playlist
ui->videoLayout->addWidget(VIDEO);
//Now setup the interfaces between all these objects
@@ -262,13 +262,13 @@ void MainUI::closeApplication(){
QTimer::singleShot(500, this, SLOT(close()) );
}else{
this->close();
- }
+ }
}
void MainUI::PlayerTypeChanged(bool active){
if(!active){ return; } //this gets rid of the "extra" signals from the radio button functionality (1 signal from each button on change)
- if(ui->radio_pandora->isChecked()){
- ui->stackedWidget->setCurrentWidget(ui->page_pandora);
+ if(ui->radio_pandora->isChecked()){
+ ui->stackedWidget->setCurrentWidget(ui->page_pandora);
PandoraStateChanged(PANDORA->currentState());
QIcon ico = LXDG::findIcon("pandora",":pandora");
SYSTRAY->setIcon( ico );
@@ -276,7 +276,7 @@ void MainUI::PlayerTypeChanged(bool active){
this->setWindowTitle( tr("Pandora Radio") );
//Now hide/deactivate any toolbar buttons which are not used
ui->actionBack->setVisible(!ui->radio_pandora->isChecked());
- }else{
+ }else{
ui->stackedWidget->setCurrentWidget(ui->page_local);
LocalStateChanged(QMediaPlayer::StoppedState);
QIcon ico = LXDG::findIcon("media-playlist-audio","audio-x-generic");
bgstack15