Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
06164840
Commit
06164840
authored
May 04, 2011
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Rename vlc_key_t to vlc_action_t
parent
e68c3be2
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
19 additions
and
14 deletions
+19
-14
include/vlc_keys.h
include/vlc_keys.h
+3
-3
modules/control/globalhotkeys/win32.c
modules/control/globalhotkeys/win32.c
+1
-1
modules/control/lirc.c
modules/control/lirc.c
+1
-1
modules/lua/libs/misc.c
modules/lua/libs/misc.c
+1
-1
src/config/keys.c
src/config/keys.c
+11
-6
src/control/media_player.c
src/control/media_player.c
+2
-2
No files found.
include/vlc_keys.h
View file @
06164840
...
...
@@ -89,7 +89,7 @@
VLC_EXPORT
(
char
*
,
vlc_keycode2str
,
(
uint_fast32_t
i_key
)
)
LIBVLC_USED
;
VLC_EXPORT
(
uint_fast32_t
,
vlc_str2keycode
,
(
const
char
*
str
)
)
LIBVLC_USED
;
typedef
enum
vlc_
key
{
typedef
enum
vlc_
action
{
ACTIONID_NONE
=
0
,
ACTIONID_QUIT
,
ACTIONID_PLAY_PAUSE
,
...
...
@@ -200,9 +200,9 @@ typedef enum vlc_key {
ACTIONID_RATE_SLOWER_FINE
,
ACTIONID_RATE_FASTER_FINE
,
}
vlc_
key
_t
;
}
vlc_
action
_t
;
VLC_EXPORT
(
vlc_
key
_t
,
vlc_GetActionId
,
(
const
char
*
psz_key
)
)
LIBVLC_USED
;
VLC_EXPORT
(
vlc_
action
_t
,
vlc_GetActionId
,
(
const
char
*
psz_key
)
)
LIBVLC_USED
;
struct
hotkey
{
...
...
modules/control/globalhotkeys/win32.c
View file @
06164840
...
...
@@ -304,7 +304,7 @@ LRESULT CALLBACK WMHOTKEYPROC( HWND hwnd, UINT uMsg, WPARAM wParam,
return
0
;
/* search for key associated with VLC */
vlc_
key
_t
action
=
vlc_GetActionId
(
psz_atomName
);
vlc_
action
_t
action
=
vlc_GetActionId
(
psz_atomName
);
if
(
action
!=
ACTIONID_NONE
)
{
var_SetInteger
(
p_intf
->
p_libvlc
,
...
...
modules/control/lirc.c
View file @
06164840
...
...
@@ -186,7 +186,7 @@ static void Process( intf_thread_t *p_intf )
{
if
(
!
strncmp
(
"key-"
,
c
,
4
)
)
{
vlc_
key
_t
i_key
=
vlc_GetActionId
(
c
);
vlc_
action
_t
i_key
=
vlc_GetActionId
(
c
);
if
(
i_key
)
var_SetInteger
(
p_intf
->
p_libvlc
,
"key-action"
,
i_key
);
else
...
...
modules/lua/libs/misc.c
View file @
06164840
...
...
@@ -237,7 +237,7 @@ static int vlclua_intf_should_die( lua_State *L )
static
int
vlclua_action_id
(
lua_State
*
L
)
{
vlc_
key
_t
i_key
=
vlc_GetActionId
(
luaL_checkstring
(
L
,
1
)
);
vlc_
action
_t
i_key
=
vlc_GetActionId
(
luaL_checkstring
(
L
,
1
)
);
if
(
i_key
==
0
)
return
0
;
lua_pushnumber
(
L
,
i_key
);
...
...
src/config/keys.c
View file @
06164840
...
...
@@ -230,7 +230,7 @@ found:
struct
action
{
char
name
[
MAXACTION
];
vlc_
key
_t
value
;
vlc_
action
_t
value
;
};
static
const
struct
action
actions
[]
=
...
...
@@ -341,8 +341,8 @@ static const struct action actions[] =
struct
mapping
{
uint32_t
key
;
///< Key code
vlc_
key
_t
action
;
///< Action ID
uint32_t
key
;
///< Key code
vlc_
action
_t
action
;
///< Action ID
};
static
int
keycmp
(
const
void
*
a
,
const
void
*
b
)
...
...
@@ -379,9 +379,14 @@ static int vlc_key_to_action (vlc_object_t *obj, const char *varname,
return
var_SetInteger
(
obj
,
"key-action"
,
(
*
pent
)
->
action
);
}
/**
* Sets up all key mappings for a given action.
* \param map tree (of struct mapping entries) to write mappings to
* \param confname VLC configuration item to read mappings from
* \param action action ID
*/
static
void
vlc_MapAction
(
vlc_object_t
*
obj
,
void
**
map
,
const
char
*
confname
,
vlc_
key
_t
action
)
const
char
*
confname
,
vlc_
action
_t
action
)
{
char
*
keys
=
var_InheritString
(
obj
,
confname
);
if
(
keys
==
NULL
)
...
...
@@ -496,7 +501,7 @@ static int actcmp(const void *key, const void *ent)
* Get the action ID from the action name in the configuration subsystem.
* @return the action ID or ACTIONID_NONE on error.
*/
vlc_
key_t
vlc_GetActionId
(
const
char
*
name
)
vlc_
action_t
vlc_GetActionId
(
const
char
*
name
)
{
const
struct
action
*
act
;
...
...
src/control/media_player.c
View file @
06164840
...
...
@@ -43,9 +43,9 @@
#include "media_player_internal.h"
/*
* mapping of libvlc_navigate_mode_t to vlc_
key
_t
* mapping of libvlc_navigate_mode_t to vlc_
action
_t
*/
static
const
vlc_
key
_t
libvlc_navigate_to_action
[]
=
static
const
vlc_
action
_t
libvlc_navigate_to_action
[]
=
{
ACTIONID_NAV_ACTIVATE
,
ACTIONID_NAV_UP
,
...
...
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