Show when a keybind is unbound #205

Merged
merged 1 commit into from Nov 30, 2015

Projects

None yet

4 participants

@PabstMirror
Contributor

Before it would show all unbound keys as duplicates (red)

@PabstMirror PabstMirror added the Bug Fix label Nov 29, 2015
@Killswitch00 Killswitch00 commented on an outdated diff Nov 29, 2015
addons/keybinding/gui/fnc_updateGUI.sqf
@@ -106,6 +106,12 @@ if !(isNull _display) then {
};
};
+ private _isUnbound = false;
@Killswitch00
Killswitch00 Nov 29, 2015 Contributor

Won't work for 1.52

@commy2 commy2 commented on an outdated diff Nov 30, 2015
addons/keybinding/gui/fnc_updateGUI.sqf
@@ -106,6 +106,13 @@ if !(isNull _display) then {
};
};
+ private "_isUnbound";
+ _isUnbound = false;
+ if (_dikCode in [-1, 0]) then {
@commy2
commy2 Nov 30, 2015 Contributor

Thats a pretty sophisticated way to write <= 0 in this case. :)

@Killswitch00
Contributor

I can not reproduce the problem that this PR supposedly solves. An action for which the assigned key is unbound (deleted) is shown as...well, nothing in the "Assigned keys" column in the configuration dialog.

@PabstMirror
Contributor

The keys on the bottom are all "unbound", but show up as duplicates in red. I think explicitly showing that they are unbound should be much clearer to users.

2015-11-27_00002

Edit, or we can just not show any text, but I think it's good to get rid of the red duplicate text.

@jonpas
Contributor
jonpas commented Nov 30, 2015

@Killswitch00 If there is only one key unbound in the category it will show up empty (this is fine), but due to empty actually being it's own "key" it will show up as a duplicate bind when having more empty binds.

@Killswitch00
Contributor

Thanks for the explanation and screenshot.

@jonpas
Contributor
jonpas commented Nov 30, 2015

👍

@Killswitch00
Contributor

As mentioned elsewhere, how about displaying unbound keys as they are displayed in the normal game key assingment dialog, ie with the assigned key field empty? (As PabstMirror said, it would save us the trouble of translating the [UNBOUND] string)

@PabstMirror PabstMirror Show when a keybind is unbound
Fix private and mark dikCode -1 or 0 as unbound

Just show blank space for unbound keys

Formatting
9b512ee
@Killswitch00 Killswitch00 added this to the 2.2 milestone Nov 30, 2015
@Killswitch00 Killswitch00 merged commit dec0641 into master Nov 30, 2015
@PabstMirror PabstMirror deleted the unboundKeyDisplay branch Nov 30, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment