Posts: 993
Joined: Nov 2014
Reputation:
20
2016-11-18, 09:48
(This post was last modified: 2016-11-18, 10:02 by burekas.)
Hi,
How can I send text to an Edit Text control (or clear it) in one of the kodi xml windows/dialogs?
My purpose is to catch the Keyboard dialog and send him the text for searching.
(Assuming that I know their ID's)
Thanks.
Posts: 180
Joined: Aug 2016
2016-11-18, 16:38
(This post was last modified: 2016-11-18, 16:53 by User 342716.)
(2016-11-18, 09:48)burekas Wrote: Hi,
How can I send text to an Edit Text control (or clear it) in one of the kodi xml windows/dialogs?
My purpose is to catch the Keyboard dialog and send him the text for searching.
(Assuming that I know their ID's)
Thanks.
By default the edit control should handle getting the text from the keyboard.
PHP Code:
myEditControl.getText();
myEditControl.setText();
http://mirrors.xbmc.org/docs/python-docs...ontrolEdit
https://codedocs.xyz/xbmc/xbmc/class_x_b..._edit.html
http://alwinesch.github.io/group__python...ntrol_edit
See below if you wish to use a custom keyboard and get text, there is an example
http://mirrors.xbmc.org/docs/python-docs...l#Keyboard
https://codedocs.xyz/xbmc/xbmc/class_x_b...board.html
http://forum.kodi.tv/showthread.php?tid=...m+keyboard
Posts: 623
Joined: Mar 2011
Reputation:
83
sarbes
Team-Kodi Member
Posts: 623
I would advice strongly against such hacks. This is far too error prone to work reliable. This could fail on slow/busy systems and would introduce a briefly flashing text search/characters.
It seems to me that you could write a subtitle add-on instead.
Posts: 993
Joined: Nov 2014
Reputation:
20
2016-11-22, 20:31
(This post was last modified: 2016-11-22, 20:54 by burekas.)
Ok, I did a subtitle add-on
Is there any way to run another subtitle addon from my subtitle addon, and passing the args from my addon to him?
Basically I tried to do so (With Runscript), but there is a problem with the handle value when I pass it (Attempt to use invalid handle) because the other addon need a handle id for his addDirectoryItem & endDirectory functions.
How can I solve this?
The idea is like this: Subtitles Dialog => activate my subtitle addon => run another existing subtitle addon with title which created by my addon => Show the results in the Subtitles Dialog.
Posts: 623
Joined: Mar 2011
Reputation:
83
sarbes
Team-Kodi Member
Posts: 623
You have two options: call some functions of the add-on directly or fork it.