Skip to content

Commit

Permalink
update videostatusplugin
Browse files Browse the repository at this point in the history
  • Loading branch information
Vitozz committed Feb 22, 2012
1 parent 63c07a1 commit dc73639
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 5 deletions.
4 changes: 4 additions & 0 deletions generic/videostatusplugin/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
2012-02-22
v0.1.9
+ Добавлена поддержка плеера vlc версии 2.0

2012-01-07
v0.1.8
+ попытка исправить не срабатывание определения полноэкранного режима после запуска плеера vlc
Expand Down
17 changes: 12 additions & 5 deletions generic/videostatusplugin/videostatusplugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@
#define constPlayerGMPlayer "gmplayer"
#define constPlayerKaffeine "kaffeineplayer"
#define vlcService "org.mpris.vlc"
#define vlcNewService "org.mpris.MediaPlayer2.vlc"
#define totemService "org.mpris.Totem"
#define totemNewService "org.mpris.MediaPlayer2.totem"
#define gmplayerService "com.gnome.mplayer"
Expand Down Expand Up @@ -85,7 +86,7 @@ static const QDBusArgument & operator>>(const QDBusArgument &arg, PlayerStatus &
}
#endif

#define constVersion "0.1.8"
#define constVersion "0.1.9"

#define constStatus "status"
#define constStatusMessage "statusmessage"
Expand Down Expand Up @@ -374,12 +375,18 @@ void VideoStatusChanger::setValidPlayers()
{
//функция работы со списком разрешенных плееров - ?
int index;
if (playerVLC && !isPlayerValid(vlcService)) {
validPlayers_ << vlcService;
if (playerVLC && (!isPlayerValid(vlcService) || !isPlayerValid(vlcNewService))) {
validPlayers_ << vlcService << vlcNewService;
}
else if (!playerVLC && isPlayerValid(vlcService)) {
else if (!playerVLC && (isPlayerValid(vlcService) || isPlayerValid(vlcNewService))) {
index = validPlayers_.indexOf(vlcService);
validPlayers_.removeAt(index);
if (index != -1) {
validPlayers_.removeAt(index);
}
index = validPlayers_.indexOf(vlcNewService);
if (index != -1) {
validPlayers_.removeAt(index);
}
}
if (playerTotem && (!isPlayerValid(totemService) || !isPlayerValid(totemNewService))) {
validPlayers_ << totemService << totemNewService;
Expand Down

0 comments on commit dc73639

Please sign in to comment.