Mercurial > mplayer.hg
changeset 33978:81aaa1420337
Replace some btnModify() calls by btnSet().
Prefer btnSet() to btnModify() if the "pressed" state is to be set.
Additionally, put parentheses around ternary operator.
author | ib |
---|---|
date | Tue, 06 Sep 2011 09:29:04 +0000 |
parents | 0e369065b585 |
children | 1c4a2554d46b |
files | gui/interface.c gui/ui/actions.c |
diffstat | 2 files changed, 8 insertions(+), 8 deletions(-) [+] |
line wrap: on
line diff
--- a/gui/interface.c Tue Sep 06 08:59:44 2011 +0000 +++ b/gui/interface.c Tue Sep 06 09:29:04 2011 +0000 @@ -227,7 +227,7 @@ wsSetBackgroundRGB(&guiApp.subWindow, 0, 0, 0); if (gtkLoadFullscreen) - btnModify(evFullScreen, btnPressed); + btnSet(evFullScreen, btnPressed); guiInfo.Playing = GUI_STOP; @@ -697,7 +697,7 @@ // ...without video there will be no call to GUI_SETUP_VIDEO_WINDOW if (!guiInfo.VideoWindow) { wsVisibleWindow(&guiApp.subWindow, wsHideWindow); - btnModify(evFullScreen, gtkLoadFullscreen ? btnPressed : btnReleased); + btnSet(evFullScreen, (gtkLoadFullscreen ? btnPressed : btnReleased)); } // ...option variable fullscreen determines whether MPlayer will handle @@ -808,7 +808,7 @@ } else { wsVisibleWindow(&guiApp.subWindow, wsHideWindow); guiInfo.VideoWindow = False; - btnModify(evFullScreen, gtkLoadFullscreen ? btnPressed : btnReleased); + btnSet(evFullScreen, (gtkLoadFullscreen ? btnPressed : btnReleased)); } gui(GUI_SET_STATE, (void *)GUI_STOP);
--- a/gui/ui/actions.c Tue Sep 06 08:59:44 2011 +0000 +++ b/gui/ui/actions.c Tue Sep 06 09:29:04 2011 +0000 @@ -96,11 +96,11 @@ void uiState(void) { if (guiInfo.Playing == GUI_STOP || guiInfo.Playing == GUI_PAUSE) { - btnModify(evPlaySwitchToPause, btnReleased); - btnModify(evPauseSwitchToPlay, btnDisabled); + btnSet(evPlaySwitchToPause, btnReleased); + btnSet(evPauseSwitchToPlay, btnDisabled); } else { - btnModify(evPlaySwitchToPause, btnDisabled); - btnModify(evPauseSwitchToPlay, btnReleased); + btnSet(evPlaySwitchToPause, btnDisabled); + btnSet(evPauseSwitchToPlay, btnReleased); } } @@ -213,7 +213,7 @@ btnModify(evSetVolume, guiInfo.Volume); btnModify(evSetBalance, guiInfo.Balance); btnModify(evSetMoviePosition, guiInfo.Position); - btnModify(evFullScreen, guiApp.subWindow.isFullScreen ? btnPressed : btnReleased); + btnSet(evFullScreen, (guiApp.subWindow.isFullScreen ? btnPressed : btnReleased)); wsSetLayer(wsDisplay, guiApp.mainWindow.WindowID, guiApp.subWindow.isFullScreen); wsSetLayer(wsDisplay, guiApp.menuWindow.WindowID, guiApp.subWindow.isFullScreen);