mirror of
https://github.com/tuxbox-neutrino/neutrino.git
synced 2025-08-30 00:41:17 +02:00
CMoviePlayerGui: Send PLUGIN_PLAYSTATE_LEAVE_ALL to plugin...
...when tv/radio button are pressed on remote control - Set Lua api version to 1.32
This commit is contained in:
@@ -281,6 +281,7 @@ static void set_lua_variables(lua_State *L)
|
|||||||
{ "STOP", CMoviePlayerGui::PLUGIN_PLAYSTATE_STOP },
|
{ "STOP", CMoviePlayerGui::PLUGIN_PLAYSTATE_STOP },
|
||||||
{ "NEXT", CMoviePlayerGui::PLUGIN_PLAYSTATE_NEXT },
|
{ "NEXT", CMoviePlayerGui::PLUGIN_PLAYSTATE_NEXT },
|
||||||
{ "PREV", CMoviePlayerGui::PLUGIN_PLAYSTATE_PREV },
|
{ "PREV", CMoviePlayerGui::PLUGIN_PLAYSTATE_PREV },
|
||||||
|
{ "LEAVE_ALL", CMoviePlayerGui::PLUGIN_PLAYSTATE_LEAVE_ALL },
|
||||||
{ NULL, 0 }
|
{ NULL, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@@ -31,7 +31,7 @@ extern "C" {
|
|||||||
#include "luainstance_helpers.h"
|
#include "luainstance_helpers.h"
|
||||||
|
|
||||||
#define LUA_API_VERSION_MAJOR 1
|
#define LUA_API_VERSION_MAJOR 1
|
||||||
#define LUA_API_VERSION_MINOR 31
|
#define LUA_API_VERSION_MINOR 32
|
||||||
|
|
||||||
/* inspired by Steve Kemp http://www.steve.org.uk/ */
|
/* inspired by Steve Kemp http://www.steve.org.uk/ */
|
||||||
class CLuaInstance
|
class CLuaInstance
|
||||||
|
@@ -1171,7 +1171,7 @@ void CMoviePlayerGui::PlayFileLoop(void)
|
|||||||
menu_ret = menu_return::RETURN_EXIT_ALL;
|
menu_ret = menu_return::RETURN_EXIT_ALL;
|
||||||
|
|
||||||
playstate = CMoviePlayerGui::STOPPED;
|
playstate = CMoviePlayerGui::STOPPED;
|
||||||
keyPressed = CMoviePlayerGui::PLUGIN_PLAYSTATE_STOP;
|
keyPressed = CMoviePlayerGui::PLUGIN_PLAYSTATE_LEAVE_ALL;
|
||||||
ClearQueue();
|
ClearQueue();
|
||||||
g_RCInput->postMsg(msg, data);
|
g_RCInput->postMsg(msg, data);
|
||||||
} else if (msg == CRCInput::RC_timeout || msg == NeutrinoMessages::EVT_TIMER) {
|
} else if (msg == CRCInput::RC_timeout || msg == NeutrinoMessages::EVT_TIMER) {
|
||||||
@@ -1194,7 +1194,7 @@ void CMoviePlayerGui::PlayFileLoop(void)
|
|||||||
printf("CMoviePlayerGui::PlayFile: neutrino handleMsg messages_return::cancel_all\n");
|
printf("CMoviePlayerGui::PlayFile: neutrino handleMsg messages_return::cancel_all\n");
|
||||||
menu_ret = menu_return::RETURN_EXIT_ALL;
|
menu_ret = menu_return::RETURN_EXIT_ALL;
|
||||||
playstate = CMoviePlayerGui::STOPPED;
|
playstate = CMoviePlayerGui::STOPPED;
|
||||||
keyPressed = CMoviePlayerGui::PLUGIN_PLAYSTATE_STOP;
|
keyPressed = CMoviePlayerGui::PLUGIN_PLAYSTATE_LEAVE_ALL;
|
||||||
ClearQueue();
|
ClearQueue();
|
||||||
}
|
}
|
||||||
else if (msg <= CRCInput::RC_MaxRC ) {
|
else if (msg <= CRCInput::RC_MaxRC ) {
|
||||||
|
@@ -72,7 +72,8 @@ class CMoviePlayerGui : public CMenuTarget
|
|||||||
PLUGIN_PLAYSTATE_NORMAL = 0,
|
PLUGIN_PLAYSTATE_NORMAL = 0,
|
||||||
PLUGIN_PLAYSTATE_STOP = 1,
|
PLUGIN_PLAYSTATE_STOP = 1,
|
||||||
PLUGIN_PLAYSTATE_NEXT = 2,
|
PLUGIN_PLAYSTATE_NEXT = 2,
|
||||||
PLUGIN_PLAYSTATE_PREV = 3
|
PLUGIN_PLAYSTATE_PREV = 3,
|
||||||
|
PLUGIN_PLAYSTATE_LEAVE_ALL = 4
|
||||||
};
|
};
|
||||||
|
|
||||||
enum repeat_mode_enum { REPEAT_OFF = 0, REPEAT_TRACK = 1, REPEAT_ALL = 2 };
|
enum repeat_mode_enum { REPEAT_OFF = 0, REPEAT_TRACK = 1, REPEAT_ALL = 2 };
|
||||||
|
Reference in New Issue
Block a user