Class: KodiClient::Methods::Input
Overview
contains all Kodi Input methods
Constant Summary
collapse
- BACK =
'Input.Back'
'Input.ContextMenu'
- DOWN =
'Input.Down'
- EXECUTE_ACTION =
'Input.ExecuteAction'
- HOME =
'Input.Home'
- INFO =
'Input.Info'
- LEFT =
'Input.Left'
- RIGHT =
'Input.Right'
- SELECT =
'Input.Select'
- SEND_TEXT =
'Input.SendText'
- SHOW_CODEC =
'Input.ShowCodec'
- SHOW_OSD =
'Input.ShowOSD'
- SHOW_PLAYER_PROCESS_INFO =
'Input.ShowPlayerProcessInfo'
- UP =
'Input.Up'
Instance Method Summary
collapse
Methods inherited from KodiMethod
#apply_options, #invoke_api
Instance Method Details
#back(kodi_id = 1) ⇒ Object
23
24
25
26
27
|
# File 'lib/kodi_client/methods/input.rb', line 23
def back(kodi_id = 1)
request = KodiRequest.new(kodi_id, BACK, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#down(kodi_id = 1) ⇒ Object
35
36
37
38
39
|
# File 'lib/kodi_client/methods/input.rb', line 35
def down(kodi_id = 1)
request = KodiRequest.new(kodi_id, DOWN, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#execute_action(action = Types::Input::InputAction::BACK, kodi_id = 1) ⇒ Object
#home(kodi_id = 1) ⇒ Object
47
48
49
50
51
|
# File 'lib/kodi_client/methods/input.rb', line 47
def home(kodi_id = 1)
request = KodiRequest.new(kodi_id, HOME, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#info(kodi_id = 1) ⇒ Object
53
54
55
56
57
|
# File 'lib/kodi_client/methods/input.rb', line 53
def info(kodi_id = 1)
request = KodiRequest.new(kodi_id, INFO, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#left(kodi_id = 1) ⇒ Object
59
60
61
62
63
|
# File 'lib/kodi_client/methods/input.rb', line 59
def left(kodi_id = 1)
request = KodiRequest.new(kodi_id, LEFT, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#right(kodi_id = 1) ⇒ Object
65
66
67
68
69
|
# File 'lib/kodi_client/methods/input.rb', line 65
def right(kodi_id = 1)
request = KodiRequest.new(kodi_id, RIGHT, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#select(kodi_id = 1) ⇒ Object
71
72
73
74
75
|
# File 'lib/kodi_client/methods/input.rb', line 71
def select(kodi_id = 1)
request = KodiRequest.new(kodi_id, SELECT, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#send_text(text, done = true, kodi_id = 1) ⇒ Object
77
78
79
80
81
|
# File 'lib/kodi_client/methods/input.rb', line 77
def send_text(text, done = true, kodi_id = 1)
request = KodiRequest.new(kodi_id, SEND_TEXT, { 'text' => text, 'done' => done})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#show_codec(kodi_id = 1) ⇒ Object
83
84
85
86
87
|
# File 'lib/kodi_client/methods/input.rb', line 83
def show_codec(kodi_id = 1)
request = KodiRequest.new(kodi_id, SHOW_CODEC, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#show_osd(kodi_id = 1) ⇒ Object
89
90
91
92
93
|
# File 'lib/kodi_client/methods/input.rb', line 89
def show_osd(kodi_id = 1)
request = KodiRequest.new(kodi_id, SHOW_OSD, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|
#show_player_process_info(kodi_id = 1) ⇒ Object
#up(kodi_id = 1) ⇒ Object
101
102
103
104
105
|
# File 'lib/kodi_client/methods/input.rb', line 101
def up(kodi_id = 1)
request = KodiRequest.new(kodi_id, UP, {})
json = invoke_api(request)
KodiResponse.new(json)
end
|