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
5a08521e
Commit
5a08521e
authored
Mar 25, 2012
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Lua: remove the never used hotkeys interface
parent
cdc30635
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
108 deletions
+0
-108
modules/lua/vlc.c
modules/lua/vlc.c
+0
-3
share/Makefile.am
share/Makefile.am
+0
-2
share/lua/intf/hotkeys.lua
share/lua/intf/hotkeys.lua
+0
-103
No files found.
modules/lua/vlc.c
View file @
5a08521e
...
...
@@ -125,9 +125,6 @@ vlc_module_begin ()
set_description
(
N_
(
"Lua Telnet"
)
)
add_shortcut
(
"luatelnet"
,
"telnet"
)
/* add_shortcut( "luahotkeys" ) */
/* add_shortcut( "hotkeys" ) */
add_submodule
()
set_shortname
(
N_
(
"Lua Meta Fetcher"
)
)
set_description
(
N_
(
"Fetch meta data using lua scripts"
)
)
...
...
share/Makefile.am
View file @
5a08521e
...
...
@@ -158,7 +158,6 @@ nobase_vlclib_DATA = \
lua/intf/cli.luac
\
lua/intf/dummy.luac
\
lua/intf/dumpmeta.luac
\
lua/intf/hotkeys.luac
\
lua/intf/luac.luac
\
lua/intf/modules/common.luac
\
lua/intf/modules/host.luac
\
...
...
@@ -222,7 +221,6 @@ EXTRA_DIST += \
lua/intf/cli.lua
\
lua/intf/dummy.lua
\
lua/intf/dumpmeta.lua
\
lua/intf/hotkeys.lua
\
lua/intf/http.lua
\
lua/intf/luac.lua
\
lua/intf/modules/common.lua
\
...
...
share/lua/intf/hotkeys.lua
deleted
100644 → 0
View file @
cdc30635
--[==========================================================================[
hotkeys.lua: hotkey handling for VLC
--[==========================================================================[
Copyright (C) 2007 the VideoLAN team
$Id$
Authors: Antoine Cellerier <dionoea at videolan dot org>
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
--]==========================================================================]
--[==========================================================================[
This is meant to replace modules/control/hotkeys.c
(which will require some changes in the VLC core hotkeys stuff)
--]==========================================================================]
require
(
"common"
)
--common.table_print(vlc,"vlc.\t")
bindings
=
{
[
"Ctrl-q"
]
=
"quit"
,
[
"Space"
]
=
"play-pause"
,
[
113
]
--[[q]]
=
"quit"
,
[
119
]
--[[w]]
=
"demo"
,
[
120
]
--[[x]]
=
"demo2"
,
}
function
quit
()
print
(
"Bye-bye!"
)
vlc
.
misc
.
quit
()
end
function
demo
()
vlc
.
osd
.
icon
(
"speaker"
)
end
function
demo2
()
if
not
channel1
then
channel1
=
vlc
.
osd
.
channel_register
()
channel2
=
vlc
.
osd
.
channel_register
()
end
vlc
.
osd
.
message
(
"Hey!"
,
channel1
)
vlc
.
osd
.
slider
(
10
,
"horizontal"
,
channel2
)
end
function
action
(
func
,
delta
)
return
{
func
=
func
,
delta
=
delta
or
0
,
last
=
0
,
times
=
0
}
end
actions
=
{
[
"quit"
]
=
action
(
quit
),
[
"play-pause"
]
=
action
(
play_pause
),
[
"demo"
]
=
action
(
demo
),
[
"demo2"
]
=
action
(
demo2
),
}
action
=
nil
queue
=
{}
function
action_trigger
(
action
)
print
(
"action_trigger:"
,
tostring
(
action
))
local
a
=
actions
[
action
]
if
a
then
local
ok
,
msg
=
pcall
(
a
.
func
)
if
not
ok
then
vlc
.
msg
.
err
(
"Error while executing action `"
..
tostring
(
action
)
..
"': "
..
msg
)
end
else
vlc
.
msg
.
err
(
"Key `"
..
key
..
"' points to unknown action `"
..
bindings
[
key
]
..
"'."
)
end
end
function
key_press
(
var
,
old
,
key
,
data
)
print
(
"key_press:"
,
tostring
(
key
))
if
bindings
[
key
]
then
action_trigger
(
bindings
[
key
])
else
vlc
.
msg
.
err
(
"Key `"
..
key
..
"' isn't bound to any action."
)
end
end
vlc
.
var
.
add_callback
(
vlc
.
object
.
libvlc
(),
"key-pressed"
,
key_press
)
--vlc.var.add_callback( vlc.object.libvlc(), "action-triggered", action_trigger )
while
not
vlc
.
misc
.
lock_and_wait
()
do
end
-- Clean up
vlc
.
var
.
del_callback
(
vlc
.
object
.
libvlc
(),
"key-pressed"
,
key_press
)
--vlc.var.del_callback( vlc.object.libvlc(), "action-triggered", action_trigger )
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