Reported by nvdakor on 2014-12-16 00:31
Hi,
In touch handler, there exist two containers for touch modes: a list of available touch modes and a dictionary that maps touch mode to human-readable touch mode labels. This labels map is used not only for storing touch modes, but also used to look up gestures and such.
Second, current global commands/touch_change mode script pulls the new touch mode label straight from touch handler's touch modes list. Although this is fine for built-ion scripts, an add-on that may wish to add custom touch modes will find itself not presenting human-readable labels.
Thus to better utilize the labels map so it can serve as a single lookup source for touch modes (even when the mode changes), I'd like to suggest slightly modifying the change mode script to pull the touch mode labels from the actual labels map. This allows already translated labels to be presented to the user, as well as for add-ons which adds custom touch modes (such as enhanced touch gestures add-on) to present human-readable labels for custom touch modes (unless the touch mode concept is destined to die someday).
Thanks.
Reported by nvdakor on 2014-12-16 00:31
Hi,
In touch handler, there exist two containers for touch modes: a list of available touch modes and a dictionary that maps touch mode to human-readable touch mode labels. This labels map is used not only for storing touch modes, but also used to look up gestures and such.
Second, current global commands/touch_change mode script pulls the new touch mode label straight from touch handler's touch modes list. Although this is fine for built-ion scripts, an add-on that may wish to add custom touch modes will find itself not presenting human-readable labels.
Thus to better utilize the labels map so it can serve as a single lookup source for touch modes (even when the mode changes), I'd like to suggest slightly modifying the change mode script to pull the touch mode labels from the actual labels map. This allows already translated labels to be presented to the user, as well as for add-ons which adds custom touch modes (such as enhanced touch gestures add-on) to present human-readable labels for custom touch modes (unless the touch mode concept is destined to die someday).
Thanks.