[Ohrrpgce] SVN: james/10250 Add optional right-drag scrolling support to plankmenus, and use it for

James Paige Bob at hamsterrepublic.com
Fri Mar 30 07:48:27 PDT 2018


On Thu, Mar 29, 2018 at 7:59 PM, Ralph Versteegen <teeemcee at gmail.com>
wrote:

> Actually, maybe what you're seeing are actually multitouch gestures. I had
> assumed they were only enabled if AppUsesMultitouch=y is set in the .cfg
> file, but if you look at DemoGLSurfaceView_nativeMotionEvent in
> src/video/android/SDL_androidinput.c, it appears they are always enabled
> and send normal scancodes, and AppUsesMultitouch only makes them
> additionally send joystick and SDL 1.3/2 multitouch events.
>
> The four multitouch gestures send these scancodes:
> static int multitouchGestureKeycode[MAX_MULTITOUCH_GESTURES] = {
> SDL_KEY(SDL_KEY_VAL(SDL_ANDROID_SCREENKB_KEYCODE_6)),
> SDL_KEY(SDL_KEY_VAL(SDL_ANDROID_SCREENKB_KEYCODE_7)),
> SDL_KEY(SDL_KEY_VAL(SDL_ANDROID_SCREENKB_KEYCODE_8)),
> SDL_KEY(SDL_KEY_VAL(SDL_ANDROID_SCREENKB_KEYCODE_9))
> };
>
>
Interesting...

In androidinputtest.rpg I can see that 3-finger touch definitely sends the
key that is defined for "MENU" which in that case is "m" and 4-finger touch
sends what is configured for "BACK" which in that case is "K"


> On 30 March 2018 at 15:41, Ralph Versteegen <teeemcee at gmail.com> wrote:
>
>> I had a look at the code, and couldn't figure out where this is
>> implemented.
>>
>> But I was reminded that there is a settings menu, which we hide (using
>> StartupMenuButtonTimeout in the .cfg) , which has a bunch of settings for
>> touch and emulating right clicks and so forth. That might be the fastest
>> way to explore the settings.
>>
>> On 30 March 2018 at 11:47, James Paige <Bob at hamsterrepublic.com> wrote:
>>
>>> I also learned something odd about the android port. Apparently a
>>> three-finger tap triggers the "Menu" button, and a four-finger tap triggers
>>> the "Back" button. The ohrrpgce interprets both of these as ESC.
>>>
>>> Unfortunately, the detection of three and four finger touches is not
>>> great, and a rapid two-finger drag (such as scrolling) can sometimes be
>>> interpreted as one of them.
>>>
>>> I puzzled over why my two-finger scrolling kept exiting out of them menu
>>> at seemingly random times until I understood this.
>>>
>>> Hopefully I can figure out how to disable it in AndroidAppSettings.cfg
>>>
>>> ---
>>> James
>>>
>>>
>>>
>>>
>>> On Thu, Mar 29, 2018 at 2:28 PM, James Paige <Bob at hamsterrepublic.com>
>>> wrote:
>>>
>>>> I have tested this on my phone in the android port, and it very nearly
>>>> works the way I want it to, but I am sure it will still need more tuning.
>>>>
>>>> sdl-android's two-finger right mouse support is pretty good.
>>>>
>>>> I am pleased how easy it is for me to accurately click inventory slots
>>>> on my 5-inch phone screen. Your mileage may vary, depending on screen size,
>>>> and perhaps on the physics of your fingertips ;)
>>>>
>>>> I also tested without turning off the virtual gamepad, and I am pleased
>>>> that the touch controls I have implemented so far work pretty decently even
>>>> when the virtual gamepad is obstructing parts of the touchable screen.
>>>>
>>>> For now I am not disabling the android virtual gamepad based on mouse
>>>> controls being enabled (although I probably will do so some extend later)
>>>>
>>>>
>>>> On Thu, Mar 29, 2018 at 2:14 PM, <subversion at hamsterrepublic.com>
>>>> wrote:
>>>>
>>>>> james
>>>>> 2018-03-29 14:14:01 -0700 (Thu, 29 Mar 2018)
>>>>> 92
>>>>> Add optional right-drag scrolling support to plankmenus, and use it
>>>>> for the inventory screen
>>>>> ---
>>>>> U   wip/menustuf.rbas
>>>>> U   wip/plankmenu.bas
>>>>> U   wip/plankmenu.bi
>>>>> _______________________________________________
>>>>> Ohrrpgce mailing list
>>>>> ohrrpgce at lists.motherhamster.org
>>>>> http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
>>>>>
>>>>
>>>>
>>>
>>> _______________________________________________
>>> Ohrrpgce mailing list
>>> ohrrpgce at lists.motherhamster.org
>>> http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
>>>
>>>
>>
>
> _______________________________________________
> Ohrrpgce mailing list
> ohrrpgce at lists.motherhamster.org
> http://lists.motherhamster.org/listinfo.cgi/ohrrpgce-motherhamster.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.motherhamster.org/pipermail/ohrrpgce-motherhamster.org/attachments/20180330/a77690cc/attachment.html>


More information about the Ohrrpgce mailing list