[vlc-commits] [Git][videolan/vlc][master] 45 commits: core: remove unused duplicate zoom hotkey strings

Jean-Baptiste Kempf gitlab at videolan.org
Sun May 23 20:52:18 UTC 2021



Jean-Baptiste Kempf pushed to branch master at VideoLAN / VLC


Commits:
ed6705d4 by Lyndon Brown at 2021-05-23T20:36:08+00:00
core: remove unused duplicate zoom hotkey strings

c3a591ae44437c1f36a981a43b1bc3295a27d6d1 placed a copy of
these defines in both libvlc-module.c and libvlc.h for some
reason. they're only used within the codebase from the
former.

playing with changing the text in the former in later work
generated warnings about the redefinition.

- - - - -
cb19e488 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt,macos: (hotkeys) robustify hotkey item identification

the existing checks:
 - assumed that any core config item (excluding special class `0`
   hint/cat/section types) that had a name starting with "key-" was a
   non-global hotkey item.
 - global hotkey item identification is similar, except looking for a
   prefix of "global-key" (Qt only).

there is no guarantee that a non-hotkey option that begins with "key-"
will never be introduced. similarly, there is no guarantee that a
hotkey option will never be introduced with a different prefix. if
either of those hypothetical situations where to occur, the hotkey
control would mishandle them.

here we:
 - check whether or not the item type matches `CONFIG_ITEM_KEY` to
   properly identify hotkey options.
 - make use of the "global-" prefix prepended to the global option
   name by the hotkey creation macro, to make a more reliable
   distinction between global and non-global.

obviously one imperfection would be that if there ever was a hotkey
option introduced with a name starting with "global-" then this would
be misidentified, but that is very unlikely, and the only way to
achieve complete perfection would be to introduce a global hotkey
subtype.

- - - - -
de355553 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt,macos: (hotkeys) remove redundant null option name check

`vlc_plugin_desc_cb()` enforces that option names are always non-null.
we thus have no need to ever check for such a possibility here.

- - - - -
26237195 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) fix bad translation macro use

- - - - -
a419545c by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) make column number enum public

such that it can be used by `KeyInputDialog`.

and name it, such that we can use it as a type later.

- - - - -
e5714154 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) make more use of column number enum

- - - - -
4211de96 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) hold relevant column index instead of global flag

this allows us to tidy up the conflict checker code a little, and make
use of the column index enum without creating a mess.

- - - - -
82753229 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) remove useless condition check

left over from a time long ago when int values were stored in the item data
attributes rather than string values.

fwiw, just to prove it's redundant, a quick review of history:
 - first, 4c90cbe87fa95b9c08422df92a687ddcfa8ee42e should have removed
   it, but it was overlooked.
 - second, 18049f2610813910140f2dfb2236ea4529766eb1 replaced the global
   instance only with a string !empty check, mistakenly breaking the
   ability to save unset global hotkey assignments (#7932).
 - thirdly, 9d7bf49bb4ccada00b85d09b23aec242fb7ddbdc fixed #7932 by
   removing the bogus !empty string check for the global instance, but
   missed the opportunity to remove the old useless check for the
   non-global instance.

- - - - -
b0385e93 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) remove incorrect hotkey table label tooltip

the item pointer provided to the constructor is that of a single hotkey
config item. using the longtext from this item in a tooltip on the label
for the entire hotkey table makes zero sense, so let's remove it.

 - for the table shown in the simple view, the "key-play" option was
   arbitrarily used for this.
 - for the table shown in the advanced view, the text from the first
   hotkey config item encountered was used.

- - - - -
aab4a2fa by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) remove useless `KeySelectorControl` constructor param

this widget is that through which all hotkeys are edited.

as just explained in the previous commit, the item pointer provided to
the constructor is always that of a single hotkey config item.

the point in passing along an item pointer was that the base control class
requires one. note that all other controls target a single config item and
so it makes sense for them, but does not make any sense for this. for
whatever reason, someone thought it made more sense to pass along an
arbitrary hotkey item pointer rather than null (possibly in relation to
the fact of displaying the incorrect tooltip removed in the previous
commit).

since the param is entirely useless for this widget, this removes it and
passes along null to the base control constructor instead. this control
simply does not need to be linked to an individual item.

note that the line removed involving "key-play" is deliberate, that was
the arbirarily chosen item to use for the widget in the simple view. (the
`p_config` var is still needed for other things though).

- - - - -
92bcf7e2 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) clear conflict flag upon fresh conflict check

if the edit dialog detects a conflict, the 'conflicts' attribute is set to
true and the dialog updated to warn the user and give them a choice as to
what to do about it.

the point of the 'conflicts' attribute relates to one of the choices given
to the user, which allows forcing the assignment. in that case, this flag
lets `KeySelectorControl::selectKey()` know that it must take action to
remove the assignment from existing keys after the dialog closes, before
storing the new assignment.

another choice available to the user is that of simply entering a different
key/combination. if the user does so, this will trigger another conflict
check. this new conflict check could obviously again find a conflict, in
which case the dialog is updated to reflect the new conflict info. if it
does not find a conflict for this new assignment, it is accepted.

in this latter situation, of an initial conflict, which the user resolves
by making a different choice which then does not conflict, the 'conflicts'
flag was left set to true from the original conflict, which meant that the
above mentioned function would waste time trying to remove the existing
assignment before storing the change.

this fixes that inefficiency by simply resetting the flag at the start of
performing a conflict check.

- - - - -
0bb7978f by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) fix "Unset" matching issue

the `locale` boolean param determines whether or not we are asking for a
translation to be performed. in the "unset" (error?) case, translation was
incorrectly always being performed upon the string "Unset", which meant
that any caller not working with translations and wanting to check for the
"Unset" condition would fail to work correctly in situations where the
translation would result in something other than exactly "Unset".

if translation has not been requested, return the untranslated form.

this means that now `KeySelectorControl::selectKey()` when reacting to
`QDialog::Accepted` will correctly store the untranslated form of "Unset"
where applicable in the data attribute. (the data attribute is supposed to
always hold an untranslated copy).

this also means that the data attribute comparison within the
`KeyInputDialog::checkForConflicts()` function will now correctly work in
translation situations.

note: it is unclear why we return "Unset" here rather than an empty string,
creating a distinction from all other unset actions. git history shows that
there was a shift from using the text "Unset" to using an empty string, yet
this was left, and without any clear explanation as to why, with a very
real possibility that it was simply overlooked. here we just leave that
question alone, to return to later.

- - - - -
a4a35b1b by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) simplify conflict checking wrt. "unset"

firstly, note that text displayed in the table is (supposed to be)
translated (it is not currently it seems for the global column), whilst
each key mapping cell holds a data attribute containing an untranslated
copy of the actual mapping value text.

the logic here:
 1. asked `VLCKeyToString( i_vlckey, true )` to convert the captured
    key/key-combination integer to string form (with translation).
 2. searched the display text of the relevant table column to find entries
    that matched.
 3. looking only at the first match (conflict), if there is one, adjusted
    the dialog for displaying the conflict condition.

if conversion failure occurs in step 1, the conversion function returns
"Unset". the behaviour then is such that we allow storing this text for
the item, thanks to step 3 ignoring conflicts with entries that have an
unset state (whether "Unset" or empty).

the change made here concerns the complexity and inefficiency of how the
conflict check is skipped for such a situation, and the legitimacy of the
is-empty side of it.

so firstly, wrt. the former: if the data value of the inspected conflict
item is "Unset", then this must be because the corresponding display text
was "Unset" (the translated form), and thus that the search text (the
converted key) was same. (we can safely ignore the hypothetical case of
translation resulting in the same text for both "Unset" and some actual
key name as being unrealistic, and that will be of no concern when we
switch to using the non-translated text for conflict checking in a later
commit in this set anyway). given this, we can simplify and optimise
handling this situation by checking if step 1 returned "Unset" up front,
and directly accepting it if so. this is a much more simple check, and
saves effort. (note that we no longer check "Unset" against the "existing
keys" set, but we would never expect a legit conflict there anyway).

secondly, the situation of the data value being empty i believe is bogus.
an item's data value should only be empty where it is in a "proper" unset
state (not the "Unset" text situation just mentioned), which can only occur
either through the saved value being so; from use of the `del` key; or from
using the `unset` button in the edit dialog. in all three cases the display
text should also be empty. such an item could thus only be in the conflict
search results if the search text itself had been an empty string. since an
empty string does not represent any key/combination, and since the int to
string conversion always gives "Unset" upon failure, it should not be
possible for an empty string search to take place, and thus we would never
encounter a conflict item with an empty data value. we can thus ditch the
check for that.

- - - - -
0f3a4126 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) have `KeyInputDialog` hold item pointer

rather than taking just the action name of the to-be edited item.

this is necessary for the fix in the next commit.

- - - - -
c2b0d66d by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) do not show warning for conflict with self

if you tried to set a hotkey to use the same key as it already was set to,
it would detect a conflict in that the selected key was already in use,
failing to recognise though that it was conflicting with itself, thus
resulting in a pointless and silly warning.

- - - - -
656a7a26 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) rework conflict check

this replaces fetching a list of conflicts to react to, with
iterating over the table and looking for conflicts as we do so.

the primary purpose of this is not efficiency, though it is more
efficient; it is actually to support the 'multi-key assignment conflict
check' fix to come in a subsequent commit in this set.

furthermore it is needed to allow improvement of the conflict checker
regarding avoiding translation (we need to be able to compare the custom
data attributes for that, not the displayed text, as `findItems()` does).

- - - - -
c86f0e52 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) avoid pointless translation in conflict check

with the previous commits having put us in the position to do this, let's
adjust the conflict checker to avoid comparing translated text, which is
entirely unnecessary.

condition split into two for neatness due to line length issue.

- - - - -
2de662ef by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) avoid re-doing key conversions

we had:
 1. event making translated copy for 'selected' text.
 2. conflict check making an untranslated copy (one commit back in this
    set it was another translated copy).
 3. the 'accepted' code, if triggered, making a further one of each.

a single copy of each can be created and stored in public attributes by
the event handlers, and used in all of these places, without any negative
impact. this replaces the need for the public `keyValue` attribute, and
replaces the need to give the conflict checker a copy of the integer.

- - - - -
068f5d0d by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) fix non-bold wheel event name

in the 'selected' text, inconsistent with that done for keyboard events.

- - - - -
4000ae13 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) fix multi-key conflict checking

the hotkey conflict check did not understand actions which have more than
one key/key-combination (tab separated) assigned, and as such it allowed
keys/key-combinations to be assigned to more than one action in some cases.

e.g. on Linux systems, the "key-play-pause" action has both "Space" and
"Media Play Pause" keys assigned, but because the string is
"Space\tMedia Play Pause" not "Space" and because the conflict check just
matches against the entire string, the conflict is overlooked if trying to
set "Space" on something else.

conflict checking became broken by default for non-MacOS systems back in
v2.1 due to baf3e50be36ff2814cd17c9116b5184ed0ba8c0d introducing default
multi-key bindings, without testing the hotkey editor properly. on Windows,
thanks to e8668774da18804c7ab22b9cf62d119423495afc, it happened to become
unbroken by default for v2.2.

note that the editor currently does not support users assigning multi-key
bindings; so the problem only comes up when multiple bindings are the
default, or if users force them by manually editing their config file.

note also that this obviously only fixes Qt; the problem likely still
exists in the MacOS code (which I leave for a mac guy to handle), but
thankfully there are no such dual bindings there by default, so users
won't notice (unless they've manually modified their config file)..

- - - - -
adb88154 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) resize 'hotkey' table column to contents

the use of multi-key bindings (default) on some platforms, like mine,
makes the small starting width of the column problematic. this helps
avoid users having to resize the column manually to see everything.

- - - - -
8a9a91e9 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) use comma+space as visible multi-binding separator

keep the existing separator (tab) for stored values, but swap with
comma+space separator for display. it works much better this way imo and
is much less confusing. it also happens to match the style used by the
`QKeySequenceEdit` control.

we thus avoid the problems that the default multi-key bindings create, as
is the default on Linux currently, whereby with play/pause for example you
see "Space       Media Play Pause" which obviously looks odd. now you will
see "Space, Media Play Pause".

if users assign the actual comma key in a multi-key binding, it should
not really be a problem for them to grasp what's what. for instance
",, Media Play Pause".

- - - - -
4bfa2900 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) update table filtering upon column selection change

i.e. update when user changes field selection combobox.

the filter function is changed here to fetch the filter text directly
from the textbox to support this.

note that this uses Qt's `connect()` directly, bypassing the vlc `CONNECT()`
macro. doing otherwise, it compiles but does not work.

- - - - -
81e22cde by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) simplify and optimise table filter

the old solution:
 1) collected a list of all matching items. this could include duplicates
    when searching all columns.
 2) iterated over all of the items, for each one checking whether or not it
    was contained within that set of matches.

the new solution simply iterates over the items, checking the one or more
columns and setting the hidden property as appropriate as it does so.

- - - - -
ddd09846 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) add longtext tooltip to first column of each row

this makes longtext of hotkey actions available to users, helping them to
understand the purpose of the actions listed in the table.

this does not interfere at all with the tooltip giving instructions on
how to perform editing, that still appears when hovering over the other
two columns. no tooltip existed for the first column previously.

- - - - -
62c8efd7 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) add a tiny amount of padding to row height

a tiny touch of padding makes a world of difference to the look of
the table imo.

notes:

 - originally i had specified `-1` for width, signalling default,
   which worked perfectly. however now when testing before publishing
   this work, i found the change was no longer working. however it
   does work when specifying `0` for width instead. it seems
   behaviour changed or a bug was introduced in newer Qt versions.

 - i tried an alternative solution of using `sizeHint()` on the
   first element to get the initial dimentions, then increasing the
   height by 12px before applying that, however this does not work
   since values of `-1` are returned from `sizeHint()`. there does
   not seem to be a way of getting the actual size to increase it, or
   to set an amount of margin/padding to apply.

- - - - -
d6c283a5 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) clarify table label

let's start the text with something describing the actual purpose
of the overall control, rather than leaping directly into
instructions on how to use it. this may not be so important for
where the table is shown in the simple view, but makes a notable
difference to use in the advanced view, where it looks very odd
without it.

also, let's clarify those instructions a bit.

- - - - -
10128a9f by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) remove pretty pointless line separator beneath the table

- - - - -
da95e7ad by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) fix missing translation of initial displayed global assignment

the displayed text is always displayed translated for non-global, and this
is the case for edits for global, but the initial unedited displayed text
was not translated.

due to the way the global data is temporarily stored in a `QMap`, it seems
that the easiest way to fix this is to simply convert from `QString` to
raw string pointer with `qtu()` and then back to `QString` with translation
applied with `qfut()`.

- - - - -
1342e605 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) improve/update table docs

- - - - -
e7abd3e2 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) fix overlooked old use of "Unset" for an unset item situation

the "Unset" text used to be used for all unset cases, but a long time ago
all except this one got changed to use an empty string instead. having
spent a bit of time trying to track down an answer in the git history as to
the question of why, i gave up. i found no clear answer in the time spent
looking. it very well may have been simply overlooked rather than
deliberately left to create a clear distinction that a failure occurred.

i'm going to assume that it was overlooked. i've thus changed it to return
an empty string. i don't expect this to cause any problems for the two
different uses in the Qt code.

- - - - -
0c423eeb by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) rework global hotkey table population

rather than getting a list of matching items, instead iterate over the list
and compare, thus avoiding the allocations in building that list. this also
puts us in a position to locate the row by option name rather than
shorttext, which might be better.

- - - - -
a758d770 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) use key name for global data population

this avoids doing a translation lookup of the displayed shorttext, and
using the option name just feels more "correct".

note that we strip the "global-" prefix with `+7` to get the match.

- - - - -
ba06a165 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) remove redundant problem check

we now rely upon checking option name rather than shorttext. it is somewhat
less likely that a mistake with duplicate option names will have been made
compared to duplicate shorttext, and duplicate option names presents an
even bigger and broader problem that we currently do nothing about. this is
not very useful towards helping with that, we'd want a full check of the
entire table's option names if we cared to properly check things here..

- - - - -
a3e2e9d0 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) do not skip item on null shorttext (action label)

unlikely and better to add it rather than skip. being there with a blank
label would better help diagnose what went wrong in testing, or if it
slipped past testing, someone is more likely to notice and report the
problem leading to a fix.

note that we must conditionally use `qfut()` because the underlying
translation function does not like nulls, and my fix for that was rejected.

- - - - -
001574dc by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) simplify and optimise global population

now the above non-global check has been reduced to a single name check,
we can strip the reverse of that here with an else.

the one remaining condition is just to avoid work for empty mappings.

- - - - -
4c38d200 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) fix grid layout numbers

we need 4 columns, not five. one element on the line with four was being
pointlessly stretched across two.

- - - - -
78b49ac0 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) remove unnecessary constructor param

the parent is always the table.

- - - - -
2c124b48 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) move param init

- - - - -
7da6f250 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) convert remaining loops to use iterators

- - - - -
33db5233 by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) avoid duplication in getting (non-global) option name

- - - - -
1cbb4d39 by Lyndon Brown at 2021-05-23T20:36:08+00:00
core: move a few misorganised hotkey declarations

move the clear playlist and subtitle scaling hotkey options above
the bookmarks and jump-size ones.

 - in the hotkey widget they are surely more interesting than the
   big block of bookmark ones that otherwise come at the end.

 - in help output, since the bookmark ones and jump sizes ones each
   declare sections, these options appear miscategorised as being a
   part of the bookmark section. this was overlooked in
   711733c6202a19aac63722ad01c58f8cd9c29dcc, or more likely perhaps
   lost from it in a rebase over time.

- - - - -
7d14aae8 by Lyndon Brown at 2021-05-23T20:36:08+00:00
core: move bookmark option text defines

these are not for hotkey options they are for playlist options

- - - - -
954ae268 by Lyndon Brown at 2021-05-23T20:36:08+00:00
core: ensure all hotkey options have longtext

with an earlier commit in this set having added a tooltip using longtext
to the first column of the hotkey editing table, allowing users to get
an additional description to help them understand the purpose of an
action, it would be great for best UX if we have such a tooltip for
each and every entry in the table. of the 113 entries, 9 were missing
longtext and thus missing the tooltip.

it was for this reason i skipped hotkeys in
d75459a35b98cb8e6a5978e776335bd5b87ea52b.

the "Select the hotkey to use..." form was used with that being fairly
common for hotkey longtext.

i used a single common longtext for the four zoom presets, as done
already with bookmarks and subtitle text scaling, reducing translator
burden.

- - - - -
0289edad by Lyndon Brown at 2021-05-23T20:36:08+00:00
qt: (hotkeys) improve translatability of strings

- - - - -


8 changed files:

- modules/gui/macosx/coreinteraction/VLCHotkeysController.m
- modules/gui/macosx/preferences/VLCSimplePrefsController.m
- modules/gui/qt/dialogs/preferences/preferences_widgets.cpp
- modules/gui/qt/dialogs/preferences/preferences_widgets.hpp
- modules/gui/qt/dialogs/preferences/simple_preferences.cpp
- modules/gui/qt/widgets/native/customwidgets.cpp
- src/libvlc-module.c
- src/libvlc.h


Changes:

=====================================
modules/gui/macosx/coreinteraction/VLCHotkeysController.m
=====================================
@@ -64,8 +64,8 @@
     for (size_t i = 0; i < confsize; i++) {
         module_config_t *p_item = p_config + i;
 
-        if (CONFIG_ITEM(p_item->i_type) && p_item->psz_name != NULL
-            && !strncmp(p_item->psz_name , "key-", 4)
+        if (p_item->i_type == CONFIG_ITEM_KEY
+            && strncmp( p_item->psz_name, "global-", 7 ) != 0
             && !EMPTY_STR(p_item->psz_text)) {
             if (p_item->value.psz)
                 [mutArray addObject:toNSStr(p_item->value.psz)];


=====================================
modules/gui/macosx/preferences/VLCSimplePrefsController.m
=====================================
@@ -834,8 +834,8 @@ static inline const char * __config_GetLabel(vlc_object_t *p_this, const char *p
     for (size_t i = 0; i < confsize; i++) {
         module_config_t *p_item = p_config + i;
 
-        if (CONFIG_ITEM(p_item->i_type) && p_item->psz_name != NULL
-           && !strncmp(p_item->psz_name , "key-", 4)
+        if (p_item->i_type == CONFIG_ITEM_KEY
+           && strncmp(p_item->psz_name, "global-", 7) != 0
            && !EMPTY_STR(p_item->psz_text)) {
             [tempArray_desc addObject: _NS(p_item->psz_text)];
             [tempArray_names addObject: toNSStr(p_item->psz_name)];


=====================================
modules/gui/qt/dialogs/preferences/preferences_widgets.cpp
=====================================
@@ -40,12 +40,14 @@
 #include <vlc_plugin.h>
 
 #include <QString>
+#include <QStringList>
 #include <QVariant>
 #include <QGridLayout>
 #include <QSlider>
 #include <QFileDialog>
 #include <QGroupBox>
 #include <QTreeWidgetItem>
+#include <QTreeWidgetItemIterator>
 #include <QSignalMapper>
 #include <QDialogButtonBox>
 #include <QKeyEvent>
@@ -56,6 +58,8 @@
 #define MINWIDTH_BOX 90
 #define LAST_COLUMN 10
 
+#define HOTKEY_ITEM_HEIGHT 24
+
 QString formatTooltip(const QString & tooltip)
 {
     QString text = tooltip;
@@ -122,7 +126,7 @@ ConfigControl *ConfigControl::createControl( vlc_object_t *p_this,
         p_control = new FontConfigControl( p_this, p_item, parent );
         break;
     case CONFIG_ITEM_KEY:
-        p_control = new KeySelectorControl( p_this, p_item, parent );
+        p_control = new KeySelectorControl( p_this, parent );
         break;
     case CONFIG_ITEM_BOOL:
         p_control = new BoolConfigControl( p_this, p_item, parent );
@@ -1109,14 +1113,12 @@ void FloatRangeConfigControl::finish()
 /**********************************************************************
  * Key selector widget
  **********************************************************************/
-KeySelectorControl::KeySelectorControl( vlc_object_t *_p_this,
-                                      module_config_t *_p_item, QWidget *p ) :
-                                ConfigControl( _p_this, _p_item )
-
+KeySelectorControl::KeySelectorControl( vlc_object_t *_p_this, QWidget *p ) :
+                                ConfigControl( _p_this, nullptr )
 {
     label = new QLabel(
-        qtr( "Select or double click an action to change the associated "
-             "hotkey. Use delete key to remove hotkeys."), p );
+        qtr( "Action hotkey mappings. Double-click (or select and press Enter) "
+             "to change an action's hotkey. The delete key will unset." ), p );
 
     label->setWordWrap( true );
     searchLabel = new QLabel( qtr( "Search" ), p );
@@ -1150,18 +1152,20 @@ KeySelectorControl::KeySelectorControl( vlc_object_t *_p_this,
     finish();
 
     CONNECT( actionSearch, textChanged( const QString& ),
-             this, filter( const QString& ) );
+             this, filter() );
+    connect( searchOption, QOverload<int>::of(&QComboBox::activated),
+             this, &KeySelectorControl::filter );
 }
 
 void KeySelectorControl::fillGrid( QGridLayout *l, int line )
 {
     QGridLayout *gLayout = new QGridLayout();
-    gLayout->addWidget( label, 0, 0, 1, 5 );
-    gLayout->addWidget( searchLabel, 1, 0, 1, 2 );
-    gLayout->addWidget( actionSearch, 1, 2, 1, 1 );
-    gLayout->addWidget( searchOptionLabel, 1, 3, 1, 1 );
-    gLayout->addWidget( searchOption, 1, 4, 1, 1 );
-    gLayout->addWidget( table, 2, 0, 1, 5 );
+    gLayout->addWidget( label, 0, 0, 1, 4 );
+    gLayout->addWidget( searchLabel, 1, 0, 1, 1 );
+    gLayout->addWidget( actionSearch, 1, 1, 1, 1 );
+    gLayout->addWidget( searchOptionLabel, 1, 2, 1, 1 );
+    gLayout->addWidget( searchOption, 1, 3, 1, 1 );
+    gLayout->addWidget( table, 2, 0, 1, 4 );
     l->addLayout( gLayout, line, 0, 1, -1 );
 }
 
@@ -1180,10 +1184,15 @@ void KeySelectorControl::buildAppHotkeysList( QWidget *rootWidget )
 
 void KeySelectorControl::finish()
 {
-    if( label && p_item->psz_longtext )
-        label->setToolTip( formatTooltip( qfut( p_item->psz_longtext ) ) );
+    /* Fill the table
 
-    /* Fill the table */
+       Each table row (action) has the following:
+        - Non-global option name stored in data of column 0 (action name) field.
+        - Translated key assignment strings displayed in columns 1 & 2, global
+          and non-global respectively.
+        - Non-translated (stored) key assignment strings stored in data of
+          columns 1 & 2, global and non-global respectively.
+     */
 
     /* Get the main Module */
     module_t *p_main = module_get_main();
@@ -1200,82 +1209,88 @@ void KeySelectorControl::finish()
     {
         module_config_t *p_config_item = p_config + i;
 
+        if( p_config_item->i_type != CONFIG_ITEM_KEY )
+            continue;
+
         /* If we are a (non-global) key option not empty */
-        if( CONFIG_ITEM(p_config_item->i_type) && p_config_item->psz_name != NULL
-         && !strncmp( p_config_item->psz_name , "key-", 4 )
-         && !EMPTY_STR( p_config_item->psz_text ) )
+        if( strncmp( p_config_item->psz_name, "global-", 7 ) != 0 )
         {
-            /*
-               Each tree item has:
-                - QString text in column 0
-                - QString name in data of column 0
-                - KeyValue in String in column 1
-             */
             QTreeWidgetItem *treeItem = new QTreeWidgetItem();
-            treeItem->setText( ACTION_COL, qfut( p_config_item->psz_text ) );
+            treeItem->setText( ACTION_COL, p_config_item->psz_text ?
+                                           qfut( p_config_item->psz_text ) : qfu("") );
             treeItem->setData( ACTION_COL, Qt::UserRole,
                                QVariant( qfu( p_config_item->psz_name ) ) );
+            if (p_config_item->psz_longtext)
+                treeItem->setToolTip( ACTION_COL, qfut(p_config_item->psz_longtext) );
 
-            QString keys = qfu(p_config_item->value.psz ? _(p_config_item->value.psz) : "");
-            treeItem->setText( HOTKEY_COL, keys );
+            QString keys = p_config_item->value.psz ? qfut(p_config_item->value.psz) : qfu("");
+            treeItem->setText( HOTKEY_COL, keys.replace( "\t", ", " ) );
             treeItem->setToolTip( HOTKEY_COL, qtr("Double click to change.\nDelete key to remove.") );
             treeItem->setToolTip( GLOBAL_HOTKEY_COL, qtr("Double click to change.\nDelete key to remove.") );
             treeItem->setData( HOTKEY_COL, Qt::UserRole, QVariant( p_config_item->value.psz ) );
             table->addTopLevelItem( treeItem );
-            continue;
         }
-
-        if( CONFIG_ITEM(p_config_item->i_type) && p_config_item->psz_name != NULL
-         && !strncmp( p_config_item->psz_name , "global-key", 10 )
-         && !EMPTY_STR( p_config_item->psz_text )
-         && !EMPTY_STR( p_config_item->value.psz ) )
+        /* Capture global key option mappings to fill in afterwards */
+        else if( !EMPTY_STR( p_config_item->value.psz ) )
         {
-            global_keys.insert( qfut( p_config_item->psz_text ), qfu( p_config_item->value.psz ) );
+            global_keys.insert( qfu( p_config_item->psz_name + 7 ),
+                                qfu( p_config_item->value.psz ) );
         }
     }
 
     QMap<QString, QString>::const_iterator i = global_keys.constBegin();
     while (i != global_keys.constEnd())
     {
-        QList<QTreeWidgetItem *> list =
-            table->findItems( i.key(), Qt::MatchExactly|Qt::MatchWrap, ACTION_COL );
-        if( list.count() >= 1 )
+        for (QTreeWidgetItemIterator iter(table); *iter; ++iter)
         {
-            QString keys = i.value();
-            list[0]->setText( GLOBAL_HOTKEY_COL, keys );
-            list[0]->setData( GLOBAL_HOTKEY_COL, Qt::UserRole, keys );
-        }
-        if( list.count() >= 2 )
-            msg_Dbg( p_this, "This is probably wrong, %s", qtu(i.key()) );
+            QTreeWidgetItem *item = *iter;
 
+            if( item->data( ACTION_COL, Qt::UserRole ) == i.key() )
+            {
+                QString keys = i.value();
+                item->setText( GLOBAL_HOTKEY_COL, qfut(qtu(keys)).replace( "\t", ", " ) );
+                item->setData( GLOBAL_HOTKEY_COL, Qt::UserRole, keys );
+                break;
+            }
+        }
         ++i;
     }
 
     module_config_free (p_config);
 
-    table->resizeColumnToContents( 0 );
+    table->resizeColumnToContents( ACTION_COL );
+    table->resizeColumnToContents( HOTKEY_COL );
+
+    table->setUniformRowHeights( true );
+    table->topLevelItem(0)->setSizeHint( 0, QSize( 0, HOTKEY_ITEM_HEIGHT ) );
 
     CONNECT( table, itemActivated( QTreeWidgetItem *, int ),
              this, selectKey( QTreeWidgetItem *, int ) );
 }
 
-void KeySelectorControl::filter( const QString &qs_search )
+void KeySelectorControl::filter()
 {
+    const QString &qs_search = actionSearch->text();
     int i_column = searchOption->itemData( searchOption->currentIndex() ).toInt();
-    QList<QTreeWidgetItem *> resultList;
-    if ( i_column == ANY_COL )
+    int i_column_count = 1;
+    if( i_column == ANY_COL )
     {
-        for( int i = 0; i < ANY_COL; i++ )
-            resultList << table->findItems( qs_search, Qt::MatchContains, i );
+        i_column = 0; // ACTION_COL
+        i_column_count = ANY_COL;
     }
-    else
+    for (QTreeWidgetItemIterator iter(table); *iter; ++iter)
     {
-        resultList = table->findItems( qs_search, Qt::MatchContains, i_column );
-    }
-    for( int i = 0; i < table->topLevelItemCount(); i++ )
-    {
-        table->topLevelItem( i )->setHidden(
-                !resultList.contains( table->topLevelItem( i ) ) );
+        QTreeWidgetItem *item = *iter;
+        bool found = false;
+        for( int idx = i_column; idx < (i_column + i_column_count); idx++ )
+        {
+            if( item->text( idx ).contains( qs_search, Qt::CaseInsensitive ) )
+            {
+                found = true;
+                break;
+            }
+        }
+        item->setHidden( !found );
     }
 }
 
@@ -1294,33 +1309,32 @@ void KeySelectorControl::selectKey( QTreeWidgetItem *keyItem, int column )
     bool b_global = ( column == GLOBAL_HOTKEY_COL );
 
     /* Launch a small dialog to ask for a new key */
-    KeyInputDialog *d = new KeyInputDialog( table, keyItem->text( ACTION_COL ),
-                                            table, b_global );
+    KeyInputDialog *d = new KeyInputDialog( table, keyItem, b_global );
     d->setExistingkeysSet( &existingkeys );
     d->exec();
 
     if( d->result() == QDialog::Accepted )
     {
-        QString newKey = VLCKeyToString( d->keyValue, false );
-
         /* In case of conflict, reset other keys*/
         if( d->conflicts )
         {
-            QTreeWidgetItem *it;
-            for( int i = 0; i < table->topLevelItemCount() ; i++ )
+            for (QTreeWidgetItemIterator iter(table); *iter; ++iter)
             {
-                it = table->topLevelItem(i);
-                if( ( keyItem != it ) &&
-                    ( it->data( column, Qt::UserRole ).toString() == newKey ) )
+                QTreeWidgetItem *it = *iter;
+                if( keyItem == it )
+                    continue;
+                QStringList it_keys = it->data( column, Qt::UserRole ).toString().split( "\t" );
+                if( it_keys.removeAll( d->vlckey ) )
                 {
-                    it->setText( column, NULL );
-                    it->setData( column, Qt::UserRole, QVariant() );
+                    QString it_filteredkeys = it_keys.join( "\t" );
+                    it->setText( column, it_filteredkeys.replace( "\t", ", " ) );
+                    it->setData( column, Qt::UserRole, it_filteredkeys );
                 }
             }
         }
 
-        keyItem->setText( column, VLCKeyToString( d->keyValue, true ) );
-        keyItem->setData( column, Qt::UserRole, newKey );
+        keyItem->setText( column, d->vlckey_tr );
+        keyItem->setData( column, Qt::UserRole, d->vlckey );
     }
     else if( d->result() == 2 )
     {
@@ -1333,15 +1347,16 @@ void KeySelectorControl::selectKey( QTreeWidgetItem *keyItem, int column )
 
 void KeySelectorControl::doApply()
 {
-    QTreeWidgetItem *it;
-    for( int i = 0; i < table->topLevelItemCount() ; i++ )
+    for (QTreeWidgetItemIterator iter(table); *iter; ++iter)
     {
-        it = table->topLevelItem(i);
-        if( it->data( HOTKEY_COL, Qt::UserRole ).toInt() >= 0 )
-            config_PutPsz( qtu( it->data( ACTION_COL, Qt::UserRole ).toString() ),
-                           qtu( it->data( HOTKEY_COL, Qt::UserRole ).toString() ) );
+        QTreeWidgetItem *it = *iter;
+
+        QString option = it->data( ACTION_COL, Qt::UserRole ).toString();
+
+        config_PutPsz( qtu( option ),
+                       qtu( it->data( HOTKEY_COL, Qt::UserRole ).toString() ) );
 
-        config_PutPsz( qtu( "global-" + it->data( ACTION_COL, Qt::UserRole ).toString() ),
+        config_PutPsz( qtu( "global-" + option ),
                        qtu( it->data( GLOBAL_HOTKEY_COL, Qt::UserRole ).toString() ) );
     }
 }
@@ -1382,23 +1397,24 @@ bool KeySelectorControl::eventFilter( QObject *obj, QEvent *e )
  * Class KeyInputDialog
  **/
 KeyInputDialog::KeyInputDialog( QTreeWidget *_table,
-                                const QString& keyToChange,
-                                QWidget *_parent,
-                                bool _b_global ) :
-                                QDialog( _parent ), keyValue(0), b_global( _b_global )
+                                QTreeWidgetItem * _keyItem,
+                                bool b_global ) :
+                                QDialog( _table ), table( _table ), keyItem( _keyItem )
 {
     setModal( true );
     conflicts = false;
     existingkeys = NULL;
 
-    table = _table;
-    setWindowTitle( ( b_global ? qtr( "Global" ) + QString(" ") : "" )
-                    + qtr( "Hotkey change" ) );
+    column = b_global ? KeySelectorControl::GLOBAL_HOTKEY_COL
+                      : KeySelectorControl::HOTKEY_COL;
+
+    setWindowTitle( b_global ? qtr( "Global Hotkey change" )
+                             : qtr( "Hotkey change" ) );
     setWindowRole( "vlc-key-input" );
 
     QVBoxLayout *vLayout = new QVBoxLayout( this );
-    selected = new QLabel( qtr( "Press the new key or combination for " )
-                           + QString("<b>%1</b>").arg( keyToChange ) );
+    selected = new QLabel( qtr( "Press the new key or combination for <b>%1</b>" )
+                           .arg( keyItem->text( KeySelectorControl::ACTION_COL ) ) );
     vLayout->addWidget( selected , Qt::AlignCenter );
 
     warning = new QLabel;
@@ -1431,26 +1447,38 @@ void KeyInputDialog::setExistingkeysSet( const QSet<QString> *keyset )
     existingkeys = keyset;
 }
 
-void KeyInputDialog::checkForConflicts( int i_vlckey, const QString &sequence )
+void KeyInputDialog::checkForConflicts( const QString &sequence )
 {
-    QList<QTreeWidgetItem *> conflictList =
-        table->findItems( VLCKeyToString( i_vlckey, true ), Qt::MatchExactly,
-                          b_global ? 2 : 1 );
+    conflicts = false;
+    if ( vlckey == "" )
+    {
+        accept();
+        return;
+    }
 
-    if( conflictList.count() &&
-        !conflictList[0]->data( b_global ? 2 : 1, Qt::UserRole ).toString().isEmpty() &&
-         conflictList[0]->data( b_global ? 2 : 1, Qt::UserRole ).toString() != "Unset" )
+    for (QTreeWidgetItemIterator iter(table); *iter; ++iter)
     {
-        warning->setText( qtr("Warning: this key or combination is already assigned to ") +
-                QString( "\"<b>%1</b>\"" ).arg( conflictList[0]->text( 0 ) ) );
+        QTreeWidgetItem *item = *iter;
+
+        if( item == keyItem )
+            continue;
+
+        if( !item->data( column, Qt::UserRole ).toString().split( "\t" ).contains( vlckey ) )
+            continue;
+
+        warning->setText(
+                qtr("Warning: this key or combination is already assigned to \"<b>%1</b>\"")
+                .arg( item->text( KeySelectorControl::ACTION_COL ) ) );
         warning->show();
         ok->show();
         unset->hide();
 
         conflicts = true;
+        return;
     }
-    else if( existingkeys && !sequence.isEmpty()
-             && existingkeys->contains( sequence ) )
+
+    if( existingkeys && !sequence.isEmpty()
+        && existingkeys->contains( sequence ) )
     {
         warning->setText(
             qtr( "Warning: <b>%1</b> is already an application menu shortcut" )
@@ -1476,18 +1504,19 @@ void KeyInputDialog::keyPressEvent( QKeyEvent *e )
         return;
     int i_vlck = qtEventToVLCKey( e );
     QKeySequence sequence( e->key() | e->modifiers() );
-    selected->setText( qtr( "Key or combination: " )
-                + QString("<b>%1</b>").arg( VLCKeyToString( i_vlck, true ) ) );
-    checkForConflicts( i_vlck, sequence.toString() );
-    keyValue = i_vlck;
+    vlckey = VLCKeyToString( i_vlck, false );
+    vlckey_tr = VLCKeyToString( i_vlck, true );
+    selected->setText( qtr( "Key or combination: <b>%1</b>" ).arg( vlckey_tr ) );
+    checkForConflicts( sequence.toString() );
 }
 
 void KeyInputDialog::wheelEvent( QWheelEvent *e )
 {
     int i_vlck = qtWheelEventToVLCKey( *e );
-    selected->setText( qtr( "Key: " ) + VLCKeyToString( i_vlck, true ) );
-    checkForConflicts( i_vlck, QString() );
-    keyValue = i_vlck;
+    vlckey = VLCKeyToString( i_vlck, false );
+    vlckey_tr = VLCKeyToString( i_vlck, true );
+    selected->setText( qtr( "Key: <b>%1</b>" ).arg( vlckey_tr ) );
+    checkForConflicts( QString() );
 }
 
 void KeyInputDialog::unsetAction() { done( 2 ); };


=====================================
modules/gui/qt/dialogs/preferences/preferences_widgets.hpp
=====================================
@@ -488,9 +488,16 @@ class KeySelectorControl : public ConfigControl
     Q_OBJECT
 
 public:
-    KeySelectorControl( vlc_object_t *, module_config_t *, QWidget * );
+    KeySelectorControl( vlc_object_t *, QWidget * );
     int getType() const Q_DECL_OVERRIDE;
     void doApply() Q_DECL_OVERRIDE;
+    enum ColumnIndex
+    {
+        ACTION_COL = 0,
+        HOTKEY_COL = 1,
+        GLOBAL_HOTKEY_COL = 2,
+        ANY_COL = 3 // == count()
+    };
 
 protected:
     bool eventFilter( QObject *, QEvent * ) Q_DECL_OVERRIDE;
@@ -512,17 +519,10 @@ private:
     QTreeWidget *table;
     QList<module_config_t *> values;
     QSet<QString> existingkeys;
-    enum
-    {
-        ACTION_COL = 0,
-        HOTKEY_COL = 1,
-        GLOBAL_HOTKEY_COL = 2,
-        ANY_COL = 3 // == count()
-    };
 
 private slots:
     void selectKey( QTreeWidgetItem * = NULL, int column = 1 );
-    void filter( const QString & );
+    void filter();
 };
 
 class KeyInputDialog : public QDialog
@@ -530,20 +530,21 @@ class KeyInputDialog : public QDialog
     Q_OBJECT
 
 public:
-    KeyInputDialog( QTreeWidget *, const QString&, QWidget *, bool b_global = false );
-    int keyValue;
+    KeyInputDialog( QTreeWidget *, QTreeWidgetItem *, bool b_global = false );
     bool conflicts;
+    QString vlckey, vlckey_tr;
     void setExistingkeysSet( const QSet<QString> *keyset = NULL );
 
 private:
     QTreeWidget *table;
     QLabel *selected, *warning;
     QPushButton *ok, *unset;
+    QTreeWidgetItem *keyItem;
+    enum KeySelectorControl::ColumnIndex column;
 
-    void checkForConflicts( int i_vlckey, const QString &sequence );
+    void checkForConflicts( const QString &sequence );
     void keyPressEvent( QKeyEvent *);
     void wheelEvent( QWheelEvent *);
-    bool b_global;
     const QSet<QString> *existingkeys;
 
 private slots:


=====================================
modules/gui/qt/dialogs/preferences/simple_preferences.cpp
=====================================
@@ -977,25 +977,17 @@ SPrefsPanel::SPrefsPanel( intf_thread_t *_p_intf, QWidget *_parent,
 
         case SPrefsHotkeys:
         {
-            p_config = config_FindConfig( "key-play" );
-
             QGridLayout *gLayout = new QGridLayout;
             panel->setLayout( gLayout );
             int line = 0;
 
             panel_label->setText( qtr( "Configure Hotkeys" ) );
-            control = new KeySelectorControl( VLC_OBJECT(p_intf), p_config, this );
+            control = new KeySelectorControl( VLC_OBJECT(p_intf), this );
             control->insertIntoExistingGrid( gLayout, line );
             controls.append( control );
 
             line++;
 
-            QFrame *sepline = new QFrame;
-            sepline->setFrameStyle(QFrame::HLine | QFrame::Sunken);
-            gLayout->addWidget( sepline, line, 0, 1, -1 );
-
-            line++;
-
             p_config = config_FindConfig( "hotkeys-y-wheel-mode" );
             control = new IntegerListConfigControl( VLC_OBJECT(p_intf),
                     p_config, this, false );


=====================================
modules/gui/qt/widgets/native/customwidgets.cpp
=====================================
@@ -326,7 +326,7 @@ QString VLCKeyToString( unsigned val, bool locale )
 {
     char *base = vlc_keycode2str (val, locale);
     if (base == NULL)
-        return qtr( "Unset" );
+        return qfu( "" );
 
     QString r = qfu( base );
 


=====================================
src/libvlc-module.c
=====================================
@@ -1246,6 +1246,17 @@ static const char *const psz_recursive_list_text[] = {
     "The playlist can use a tree to categorize some items, like the " \
     "contents of a directory." )
 
+#define BOOKMARK1_TEXT N_("Playlist bookmark 1")
+#define BOOKMARK2_TEXT N_("Playlist bookmark 2")
+#define BOOKMARK3_TEXT N_("Playlist bookmark 3")
+#define BOOKMARK4_TEXT N_("Playlist bookmark 4")
+#define BOOKMARK5_TEXT N_("Playlist bookmark 5")
+#define BOOKMARK6_TEXT N_("Playlist bookmark 6")
+#define BOOKMARK7_TEXT N_("Playlist bookmark 7")
+#define BOOKMARK8_TEXT N_("Playlist bookmark 8")
+#define BOOKMARK9_TEXT N_("Playlist bookmark 9")
+#define BOOKMARK10_TEXT N_("Playlist bookmark 10")
+#define BOOKMARK_LONGTEXT N_("This allows you to define playlist bookmarks.")
 
 /*****************************************************************************
  * Hotkeys
@@ -1393,6 +1404,7 @@ static const char *const mouse_wheel_texts[] = {
 #define ZOOM_HALF_KEY_TEXT N_("1:2 Half")
 #define ZOOM_ORIGINAL_KEY_TEXT N_("1:1 Original")
 #define ZOOM_DOUBLE_KEY_TEXT N_("2:1 Double")
+#define ZOOM_LEVEL_KEY_LONGTEXT N_("Select the hotkey to use to zoom to the corresponding level.")
 
 #define PLAY_BOOKMARK1_KEY_TEXT N_("Play playlist bookmark 1")
 #define PLAY_BOOKMARK2_KEY_TEXT N_("Play playlist bookmark 2")
@@ -1419,19 +1431,6 @@ static const char *const mouse_wheel_texts[] = {
 #define PLAY_CLEAR_KEY_TEXT N_("Clear the playlist")
 #define PLAY_CLEAR_KEY_LONGTEXT N_("Select the key to clear the current playlist.")
 
-#define BOOKMARK1_TEXT N_("Playlist bookmark 1")
-#define BOOKMARK2_TEXT N_("Playlist bookmark 2")
-#define BOOKMARK3_TEXT N_("Playlist bookmark 3")
-#define BOOKMARK4_TEXT N_("Playlist bookmark 4")
-#define BOOKMARK5_TEXT N_("Playlist bookmark 5")
-#define BOOKMARK6_TEXT N_("Playlist bookmark 6")
-#define BOOKMARK7_TEXT N_("Playlist bookmark 7")
-#define BOOKMARK8_TEXT N_("Playlist bookmark 8")
-#define BOOKMARK9_TEXT N_("Playlist bookmark 9")
-#define BOOKMARK10_TEXT N_("Playlist bookmark 10")
-#define BOOKMARK_LONGTEXT N_( \
-      "This allows you to define playlist bookmarks.")
-
 #define AUDIO_TRACK_KEY_TEXT N_("Cycle audio track")
 #define AUDIO_TRACK_KEY_LONGTEXT N_("Cycle through the available audio tracks(languages).")
 #define SUBTITLE_REVERSE_TRACK_KEY_TEXT N_("Cycle subtitle track in reverse order")
@@ -1461,6 +1460,7 @@ static const char *const mouse_wheel_texts[] = {
 #define DEINTERLACE_MODE_KEY_TEXT N_("Cycle deinterlace modes")
 #define DEINTERLACE_MODE_KEY_LONGTEXT N_("Cycle through available deinterlace modes.")
 #define INTF_TOGGLE_FSC_KEY_TEXT N_("Show controller in fullscreen")
+#define INTF_TOGGLE_FSC_KEY_LONGTEXT N_("Select the hotkey to use to toggle visibility of controls in fullscreen mode.")
 #define INTF_BOSS_KEY_TEXT N_("Boss key")
 #define INTF_BOSS_KEY_LONGTEXT N_("Hide the interface and pause playback.")
 #define INTF_POPUP_MENU_KEY_TEXT N_("Context menu")
@@ -1505,9 +1505,13 @@ static const char *const mouse_wheel_texts[] = {
 
 /* 360° Viewpoint */
 #define VIEWPOINT_FOV_IN_KEY_TEXT N_("Shrink the viewpoint field of view (360°)")
+#define VIEWPOINT_FOV_IN_KEY_LONGTEXT N_("Select the hotkey to use to shrink the viewpoint (360°) field of view.")
 #define VIEWPOINT_FOV_OUT_KEY_TEXT N_("Expand the viewpoint field of view (360°)")
+#define VIEWPOINT_FOV_OUT_KEY_LONGTEXT N_("Select the hotkey to use to expand the viewpoint (360°) field of view.")
 #define VIEWPOINT_ROLL_CLOCK_KEY_TEXT N_("Roll the viewpoint clockwise (360°)")
+#define VIEWPOINT_ROLL_CLOCK_KEY_LONGTEXT N_("Select the hotkey to use for viewpoint (360°) clockwise roll.")
 #define VIEWPOINT_ROLL_ANTICLOCK_KEY_TEXT N_("Roll the viewpoint anti-clockwise (360°)")
+#define VIEWPOINT_ROLL_ANTICLOCK_KEY_LONGTEXT N_("Select the hotkey to use for viewpoint (360°) anti-clockwise roll.")
 
 #define WALLPAPER_KEY_TEXT N_("Toggle wallpaper mode in video output")
 #define WALLPAPER_KEY_LONGTEXT N_( \
@@ -2705,7 +2709,7 @@ vlc_module_begin ()
     add_key("key-deinterlace-mode", KEY_DEINTERLACE_MODE,
             DEINTERLACE_MODE_KEY_TEXT, DEINTERLACE_MODE_KEY_LONGTEXT)
     add_key("key-intf-show", KEY_INTF_TOGGLE_FSC,
-            INTF_TOGGLE_FSC_KEY_TEXT, INTF_TOGGLE_FSC_KEY_TEXT)
+            INTF_TOGGLE_FSC_KEY_TEXT, INTF_TOGGLE_FSC_KEY_LONGTEXT)
     add_obsolete_inner( "key-intf-hide", CONFIG_ITEM_KEY )
 
     add_key("key-intf-boss", KEY_INTF_BOSS,
@@ -2739,20 +2743,29 @@ vlc_module_begin ()
     add_key("key-loop", KEY_LOOP, LOOP_KEY_TEXT, LOOP_KEY_LONGTEXT)
 
     add_key("key-viewpoint-fov-in", KEY_VIEWPOINT_FOV_IN,
-            VIEWPOINT_FOV_IN_KEY_TEXT, VIEWPOINT_FOV_IN_KEY_TEXT)
+            VIEWPOINT_FOV_IN_KEY_TEXT, VIEWPOINT_FOV_IN_KEY_LONGTEXT)
     add_key("key-viewpoint-fov-out", KEY_VIEWPOINT_FOV_OUT,
-            VIEWPOINT_FOV_OUT_KEY_TEXT, VIEWPOINT_FOV_OUT_KEY_TEXT)
+            VIEWPOINT_FOV_OUT_KEY_TEXT, VIEWPOINT_FOV_OUT_KEY_LONGTEXT)
     add_key("key-viewpoint-roll-clock", NULL,
-            VIEWPOINT_ROLL_CLOCK_KEY_TEXT, VIEWPOINT_ROLL_CLOCK_KEY_TEXT)
+            VIEWPOINT_ROLL_CLOCK_KEY_TEXT, VIEWPOINT_ROLL_CLOCK_KEY_LONGTEXT)
     add_key("key-viewpoint-roll-anticlock", NULL,
             VIEWPOINT_ROLL_ANTICLOCK_KEY_TEXT,
-            VIEWPOINT_ROLL_ANTICLOCK_KEY_TEXT)
+            VIEWPOINT_ROLL_ANTICLOCK_KEY_LONGTEXT)
+
+    add_key("key-zoom-quarter", KEY_ZOOM_QUARTER, ZOOM_QUARTER_KEY_TEXT, ZOOM_LEVEL_KEY_LONGTEXT)
+    add_key("key-zoom-half", KEY_ZOOM_HALF, ZOOM_HALF_KEY_TEXT, ZOOM_LEVEL_KEY_LONGTEXT)
+    add_key("key-zoom-original", KEY_ZOOM_ORIGINAL, ZOOM_ORIGINAL_KEY_TEXT, ZOOM_LEVEL_KEY_LONGTEXT)
+    add_key("key-zoom-double", KEY_ZOOM_DOUBLE, ZOOM_DOUBLE_KEY_TEXT, ZOOM_LEVEL_KEY_LONGTEXT)
+
+    add_key("key-clear-playlist", KEY_PLAY_CLEAR,
+            PLAY_CLEAR_KEY_TEXT, PLAY_CLEAR_KEY_LONGTEXT)
 
-    add_key("key-zoom-quarter", KEY_ZOOM_QUARTER, ZOOM_QUARTER_KEY_TEXT, NULL)
-    add_key("key-zoom-half", KEY_ZOOM_HALF, ZOOM_HALF_KEY_TEXT, NULL)
-    add_key("key-zoom-original", KEY_ZOOM_ORIGINAL,
-            ZOOM_ORIGINAL_KEY_TEXT, NULL)
-    add_key("key-zoom-double", KEY_ZOOM_DOUBLE, ZOOM_DOUBLE_KEY_TEXT, NULL)
+    add_key("key-subtitle-text-scale-normal", KEY_SUBTEXT_SCALE,
+            SUBTEXT_SCALE_KEY_TEXT, SUBTEXT_SCALE_KEY_LONGTEXT)
+    add_key("key-subtitle-text-scale-up", KEY_SUBTEXT_SCALEUP,
+            SUBTEXT_SCALEUP_KEY_TEXT, SUBTEXT_SCALE_KEY_LONGTEXT)
+    add_key("key-subtitle-text-scale-down", KEY_SUBTEXT_SCALEDOWN,
+            SUBTEXT_SCALEDOWN_KEY_TEXT, SUBTEXT_SCALE_KEY_LONGTEXT)
 
     set_section ( N_("Jump sizes" ), NULL )
     add_integer( "extrashort-jump-size", 3, JIEXTRASHORT_TEXT,
@@ -2805,15 +2818,6 @@ vlc_module_begin ()
             PLAY_BOOKMARK9_KEY_TEXT, PLAY_BOOKMARK_KEY_LONGTEXT)
     add_key("key-play-bookmark10", KEY_PLAY_BOOKMARK10,
             PLAY_BOOKMARK10_KEY_TEXT, PLAY_BOOKMARK_KEY_LONGTEXT)
-    add_key("key-clear-playlist", KEY_PLAY_CLEAR,
-            PLAY_CLEAR_KEY_TEXT, PLAY_CLEAR_KEY_LONGTEXT)
-
-    add_key("key-subtitle-text-scale-normal", KEY_SUBTEXT_SCALE,
-            SUBTEXT_SCALE_KEY_TEXT, SUBTEXT_SCALE_KEY_LONGTEXT)
-    add_key("key-subtitle-text-scale-up", KEY_SUBTEXT_SCALEUP,
-            SUBTEXT_SCALEUP_KEY_TEXT, SUBTEXT_SCALE_KEY_LONGTEXT)
-    add_key("key-subtitle-text-scale-down", KEY_SUBTEXT_SCALEDOWN,
-            SUBTEXT_SCALEDOWN_KEY_TEXT, SUBTEXT_SCALE_KEY_LONGTEXT)
 
 /* Miscellaneous */
     /* Not displayed in GUI, listed in help output though */


=====================================
src/libvlc.h
=====================================
@@ -159,12 +159,6 @@ void vlc_objres_clear(vlc_object_t *obj);
 void vlc_objres_remove(vlc_object_t *obj, void *data,
                        bool (*match)(void *, void *));
 
-#define ZOOM_SECTION N_("Zoom")
-#define ZOOM_QUARTER_KEY_TEXT N_("1:4 Quarter")
-#define ZOOM_HALF_KEY_TEXT N_("1:2 Half")
-#define ZOOM_ORIGINAL_KEY_TEXT N_("1:1 Original")
-#define ZOOM_DOUBLE_KEY_TEXT N_("2:1 Double")
-
 /**
  * Private LibVLC instance data.
  */



View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/722afbfe36517581d3d4618e4296411185684519...0289edadff52734c2509ee62364507a09205c492

-- 
View it on GitLab: https://code.videolan.org/videolan/vlc/-/compare/722afbfe36517581d3d4618e4296411185684519...0289edadff52734c2509ee62364507a09205c492
You're receiving this email because of your account on code.videolan.org.




More information about the vlc-commits mailing list