- Moderator
- #1
Hi
Under certain curcumstances, I wan't to catch a user-action (say, if the user pressed "stop" in the "my music" screen).
Now, catching the action is easy, but how can I avoid the action to be read by MediaPortal afterwords?
My plugin is a process-plugin.
I have my handler like this:
OnAction then checks the action:
Under certain curcumstances, I wan't to catch a user-action (say, if the user pressed "stop" in the "my music" screen).
Now, catching the action is easy, but how can I avoid the action to be read by MediaPortal afterwords?
My plugin is a process-plugin.
I have my handler like this:
Code:
GUIGraphicsContext.OnNewAction += new OnActionHandler(OnAction);
OnAction then checks the action:
Code:
public void OnAction(MediaPortal.GUI.Library.Action action)
{
switch (action.wID)
{
case MediaPortal.GUI.Library.Action.ActionType.ACTION_STOP:
//some function is run here
break;
}
}