示例#1
0
        protected override bool OnJoystickRelease(InputState state, JoystickEventArgs args)
        {
            if (!HasFocus)
            {
                return(base.OnJoystickRelease(state, args));
            }

            finalise();
            return(true);
        }
示例#2
0
        protected override bool OnJoystickPress(InputState state, JoystickEventArgs args)
        {
            if (!HasFocus)
            {
                return(false);
            }

            bindTarget.UpdateKeyCombination(KeyCombination.FromInputState(state));
            finalise();

            return(true);
        }
示例#3
0
 protected override bool OnJoystickRelease(InputState state, JoystickEventArgs args)
 {
     ++JoystickReleaseCount;
     return(base.OnJoystickRelease(state, args));
 }
示例#4
0
        protected virtual bool PropagateJoystickRelease(IEnumerable <Drawable> drawables, InputState state, JoystickEventArgs args)
        {
            var handledBy = drawables.FirstOrDefault(target => target.TriggerOnJoystickRelease(state, args));

            if (handledBy != null)
            {
                Logger.Log($"JoystickRelease ({args.Button}) handled by {handledBy}.", LoggingTarget.Runtime, LogLevel.Debug);
            }

            return(handledBy != null);
        }