[vlc-devel] [PATCH] vout: on windows context menu should apear on mouse release

Hugo Beauzée-Luyssen hugo at beauzee.fr
Tue Nov 7 15:48:00 CET 2017


On Tue, Nov 7, 2017, at 03:41 PM, Pierre Lamot wrote:
>   fix: #19025
> ---
>  src/video_output/event.h | 10 ++++++++++
>  1 file changed, 10 insertions(+)
> 
> diff --git a/src/video_output/event.h b/src/video_output/event.h
> index 78804c190c..ac40ef3405 100644
> --- a/src/video_output/event.h
> +++ b/src/video_output/event.h
> @@ -80,7 +80,9 @@ static inline void
> vout_SendEventMousePressed(vout_thread_t *vout, int button)
>          var_ToggleBool(vout->obj.libvlc, "intf-toggle-fscontrol");
>          return;
>      case MOUSE_BUTTON_RIGHT:
> +#if !defined(_WIN32)
>          var_SetBool(vout->obj.libvlc, "intf-popupmenu", true);
> +#endif
>          return;
>      case MOUSE_BUTTON_WHEEL_UP:    key = KEY_MOUSEWHEELUP;    break;
>      case MOUSE_BUTTON_WHEEL_DOWN:  key = KEY_MOUSEWHEELDOWN;  break;
> @@ -92,6 +94,14 @@ static inline void
> vout_SendEventMousePressed(vout_thread_t *vout, int button)
>  static inline void vout_SendEventMouseReleased(vout_thread_t *vout, int
>  button)
>  {
>      var_NAndInteger(vout, "mouse-button-down", 1 << button);
> +#if defined(_WIN32)
> +    switch (button)
> +    {
> +    case MOUSE_BUTTON_RIGHT:
> +        var_SetBool(vout->obj.libvlc, "intf-popupmenu", true);
> +        return;
> +    }
> +#endif
>  }
>  static inline void vout_SendEventMouseDoubleClick(vout_thread_t *vout)
>  {
> -- 
> 2.14.2
> 
> _______________________________________________
> vlc-devel mailing list
> To unsubscribe or modify your subscription options:
> https://mailman.videolan.org/listinfo/vlc-devel

Seems OK to me

-- 
  Hugo Beauzée-Luyssen
  hugo at beauzee.fr


More information about the vlc-devel mailing list