Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-gpu
Commits
e77d9061
Commit
e77d9061
authored
Mar 27, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use KeyToString
parent
1e81cdfb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
20 deletions
+8
-20
modules/gui/macosx/simple_prefs.m
modules/gui/macosx/simple_prefs.m
+5
-11
modules/gui/qt4/util/customwidgets.cpp
modules/gui/qt4/util/customwidgets.cpp
+3
-9
No files found.
modules/gui/macosx/simple_prefs.m
View file @
e77d9061
...
...
@@ -83,17 +83,11 @@ static VLCSimplePrefs *_o_sharedInstance = nil;
if
(
val
&
KEY_MODIFIER_COMMAND
)
[
o_temp_str
appendString
:
[
NSString
stringWithUTF8String
:
"
\xE2\x8C\x98
"
]];
unsigned
int
i_keys
=
sizeof
(
vlc_keys
)
/
sizeof
(
key_descriptor_t
);
for
(
unsigned
int
i
=
0
;
i
<
i_keys
;
i
++
)
{
if
(
vlc_keys
[
i
].
i_key_code
==
(
val
&
~
KEY_MODIFIER
)
)
{
if
(
vlc_keys
[
i
].
psz_key_string
)
[
o_temp_str
appendString
:
[
NSString
stringWithUTF8String
:
vlc_keys
[
i
].
psz_key_string
]];
else
o_temp_str
=
@"Unset"
;
}
}
const
char
*
base
=
KeyToString
(
val
&
~
KEY_MODIFIER
);
if
(
base
)
[
o_temp_str
appendString
:
[
NSString
stringWithUTF8String
:
base
]];
else
o_temp_str
=
@"Unset"
;
return
o_temp_str
;
}
...
...
modules/gui/qt4/util/customwidgets.cpp
View file @
e77d9061
...
...
@@ -181,6 +181,8 @@ int qtWheelEventToVLCKey( QWheelEvent *e )
QString
VLCKeyToString
(
int
val
)
{
const
char
*
base
=
KeyToString
(
val
&
~
KEY_MODIFIER
);
QString
r
=
""
;
if
(
val
&
KEY_MODIFIER_CTRL
)
r
+=
"Ctrl+"
;
...
...
@@ -189,14 +191,6 @@ QString VLCKeyToString( int val )
if
(
val
&
KEY_MODIFIER_SHIFT
)
r
+=
"Shift+"
;
unsigned
int
i_keys
=
sizeof
(
vlc_keys
)
/
sizeof
(
key_descriptor_t
);
for
(
unsigned
int
i
=
0
;
i
<
i_keys
;
i
++
)
{
if
(
vlc_keys
[
i
].
i_key_code
==
(
val
&
~
KEY_MODIFIER
)
)
{
r
+=
vlc_keys
[
i
].
psz_key_string
;
}
}
return
r
;
return
r
+
(
base
?
base
:
"Unset"
);
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment