Changeset View
Standalone View
binaries/data/mods/public/gui/common/tab_buttons.xml
<?xml version="1.0" encoding="utf-8"?> | <?xml version="1.0" encoding="utf-8"?> | ||||
<object> | <object> | ||||
<object hotkey="tab.next"> | <object hotkey="tab.next"> | ||||
<action on="Press">selectNextTab(1);</action> | <action on="KeyDown">selectNextTab(1);</action> | ||||
</object> | </object> | ||||
<object hotkey="tab.prev"> | <object hotkey="tab.prev"> | ||||
<action on="Press">selectNextTab(-1);</action> | <action on="KeyDown">selectNextTab(-1);</action> | ||||
elexis: Whats the use case for keydown? The frequency is quite high on all systems, so it seems… | |||||
Not Done Inline ActionsWhy disallow the disco scroll? The frequency can be set (at least on linux), also potentially there can be a page with 100 tabs, and you don't want to press 50 times... bb: Why disallow the disco scroll? The frequency can be set (at least on linux), also potentially… | |||||
Not Done Inline ActionsI doubt anyone will set the keyboard frequency to adjust it to the tabs in 0ad. elexis: I doubt anyone will set the keyboard frequency to adjust it to the tabs in 0ad.
A page with 100… | |||||
Not Done Inline Actionsunlikely != impossible, so why not support the hypothetical case? (also see the revision to merge horizontal tabs in this file, and there could be many of those next too eachother) bb: unlikely != impossible, so why not support the hypothetical case? (also see the revision to… | |||||
</object> | </object> | ||||
Not Done Inline ActionsAn argument for using Press woould be that keeping it pressed means it switches tabs uncontrollably (unpredictable tab selection) as long as it doesn't stop at the first or last tab. And we can assume < 10 tabs, so there is no use case where one wants to scroll many tabs forwards quickly. elexis: An argument for using Press woould be that keeping it pressed means it switches tabs… | |||||
Done Inline ActionsOne can't assume <10. A mod could very well have a use case for many more tabs, hence the scrolling can be useful bb: One can't assume <10. A mod could very well have a use case for many more tabs, hence the… | |||||
<object name="tabButtons" type="image"> | <object name="tabButtons" type="image"> | ||||
<repeat count="20"> | <repeat count="20"> | ||||
<object name="tabButton[n]" type="button" style="ModernTabButtonVertical" size="0 0 100% 30" hidden="true"> | <object name="tabButton[n]" type="button" style="ModernTabButtonVertical" size="0 0 100% 30" hidden="true"> | ||||
<object type="text" name="tabButtonText[n]" style="ModernLabelText" ghost="true"/> | <object type="text" name="tabButtonText[n]" style="ModernLabelText" ghost="true"/> | ||||
<action on="MouseWheelUp">selectNextTab(-1);</action> | <action on="MouseWheelUp">selectNextTab(-1);</action> | ||||
<action on="MouseWheelDown">selectNextTab(1);</action> | <action on="MouseWheelDown">selectNextTab(1);</action> | ||||
</object> | </object> | ||||
</repeat> | </repeat> | ||||
</object> | </object> | ||||
</object> | </object> |
Whats the use case for keydown? The frequency is quite high on all systems, so it seems unlikely that one can hit just the right element while kepeing it pressed.