summaryrefslogtreecommitdiffstats
path: root/pyload/remote
diff options
context:
space:
mode:
Diffstat (limited to 'pyload/remote')
-rw-r--r--pyload/remote/apitypes.py34
-rw-r--r--pyload/remote/apitypes_debug.py8
-rw-r--r--pyload/remote/pyload.thrift16
-rw-r--r--pyload/remote/wsbackend/AsyncHandler.py2
4 files changed, 30 insertions, 30 deletions
diff --git a/pyload/remote/apitypes.py b/pyload/remote/apitypes.py
index 196491083..d487599c3 100644
--- a/pyload/remote/apitypes.py
+++ b/pyload/remote/apitypes.py
@@ -51,12 +51,13 @@ class InputType:
Folder = 4
Textbox = 5
Password = 6
- Bool = 7
- Click = 8
- Select = 9
- Multiple = 10
- List = 11
- Table = 12
+ Time = 7
+ Bool = 8
+ Click = 9
+ Select = 10
+ Multiple = 11
+ List = 12
+ Table = 13
class Interaction:
All = 0
@@ -127,13 +128,13 @@ class AddonService(BaseObject):
self.media = media
class ConfigHolder(BaseObject):
- __slots__ = ['name', 'label', 'description', 'long_description', 'items', 'info']
+ __slots__ = ['name', 'label', 'description', 'explanation', 'items', 'info']
- def __init__(self, name=None, label=None, description=None, long_description=None, items=None, info=None):
+ def __init__(self, name=None, label=None, description=None, explanation=None, items=None, info=None):
self.name = name
self.label = label
self.description = description
- self.long_description = long_description
+ self.explanation = explanation
self.items = items
self.info = info
@@ -149,14 +150,13 @@ class ConfigInfo(BaseObject):
self.activated = activated
class ConfigItem(BaseObject):
- __slots__ = ['name', 'label', 'description', 'input', 'default_value', 'value']
+ __slots__ = ['name', 'label', 'description', 'input', 'value']
- def __init__(self, name=None, label=None, description=None, input=None, default_value=None, value=None):
+ def __init__(self, name=None, label=None, description=None, input=None, value=None):
self.name = name
self.label = label
self.description = description
self.input = input
- self.default_value = default_value
self.value = value
class DownloadInfo(BaseObject):
@@ -211,20 +211,20 @@ class Forbidden(ExceptionObject):
pass
class Input(BaseObject):
- __slots__ = ['type', 'data']
+ __slots__ = ['type', 'default_value', 'data']
- def __init__(self, type=None, data=None):
+ def __init__(self, type=None, default_value=None, data=None):
self.type = type
+ self.default_value = default_value
self.data = data
class InteractionTask(BaseObject):
- __slots__ = ['iid', 'type', 'input', 'default_value', 'title', 'description', 'plugin']
+ __slots__ = ['iid', 'type', 'input', 'title', 'description', 'plugin']
- def __init__(self, iid=None, type=None, input=None, default_value=None, title=None, description=None, plugin=None):
+ def __init__(self, iid=None, type=None, input=None, title=None, description=None, plugin=None):
self.iid = iid
self.type = type
self.input = input
- self.default_value = default_value
self.title = title
self.description = description
self.plugin = plugin
diff --git a/pyload/remote/apitypes_debug.py b/pyload/remote/apitypes_debug.py
index 96673cc99..7c62a6277 100644
--- a/pyload/remote/apitypes_debug.py
+++ b/pyload/remote/apitypes_debug.py
@@ -23,17 +23,17 @@ classes = {
'AddonService' : [basestring, basestring, (list, basestring), (None, int)],
'ConfigHolder' : [basestring, basestring, basestring, basestring, (list, ConfigItem), (None, (list, AddonInfo))],
'ConfigInfo' : [basestring, basestring, basestring, basestring, bool, (None, bool)],
- 'ConfigItem' : [basestring, basestring, basestring, Input, basestring, basestring],
+ 'ConfigItem' : [basestring, basestring, basestring, Input, basestring],
'DownloadInfo' : [basestring, basestring, basestring, int, basestring, basestring],
'DownloadProgress' : [int, int, int, int],
'EventInfo' : [basestring, (list, basestring)],
'FileDoesNotExists' : [int],
'FileInfo' : [int, basestring, int, int, int, int, int, int, int, (None, DownloadInfo)],
- 'Input' : [int, (None, basestring)],
- 'InteractionTask' : [int, int, Input, (None, basestring), basestring, basestring, basestring],
+ 'Input' : [int, (None, basestring), (None, basestring)],
+ 'InteractionTask' : [int, int, Input, basestring, basestring, basestring],
'InvalidConfigSection' : [basestring],
'LinkStatus' : [basestring, basestring, basestring, int, int, basestring],
- 'OnlineCheck' : [int, (None, (dict, basestring, LinkStatus))],
+ 'OnlineCheck' : [int, (dict, basestring, LinkStatus)],
'PackageDoesNotExists' : [int],
'PackageInfo' : [int, basestring, basestring, int, int, basestring, basestring, basestring, int, (list, basestring), int, bool, int, PackageStats, (list, int), (list, int)],
'PackageStats' : [int, int, int, int],
diff --git a/pyload/remote/pyload.thrift b/pyload/remote/pyload.thrift
index 57d7e0a0a..f218896ef 100644
--- a/pyload/remote/pyload.thrift
+++ b/pyload/remote/pyload.thrift
@@ -77,6 +77,7 @@ enum InputType {
Folder,
Textbox,
Password,
+ Time,
Bool, // confirm like, yes or no dialog
Click, // for positional captchas
Select, // select from list
@@ -113,7 +114,8 @@ enum Role {
struct Input {
1: InputType type,
- 2: optional JSONString data,
+ 2: optional JSONString default_value,
+ 3: optional JSONString data,
}
struct DownloadProgress {
@@ -215,10 +217,9 @@ struct InteractionTask {
1: InteractionID iid,
2: Interaction type,
3: Input input,
- 4: optional JSONString default_value,
- 5: string title,
- 6: string description,
- 7: PluginName plugin,
+ 4: string title,
+ 5: string description,
+ 6: PluginName plugin,
}
struct AddonService {
@@ -239,15 +240,14 @@ struct ConfigItem {
2: string label,
3: string description,
4: Input input,
- 5: JSONString default_value,
- 6: JSONString value,
+ 5: JSONString value,
}
struct ConfigHolder {
1: string name, // for plugin this is the PluginName
2: string label,
3: string description,
- 4: string long_description,
+ 4: string explanation,
5: list<ConfigItem> items,
6: optional list<AddonInfo> info,
}
diff --git a/pyload/remote/wsbackend/AsyncHandler.py b/pyload/remote/wsbackend/AsyncHandler.py
index f1c584b7d..b936de898 100644
--- a/pyload/remote/wsbackend/AsyncHandler.py
+++ b/pyload/remote/wsbackend/AsyncHandler.py
@@ -43,7 +43,7 @@ class AsyncHandler(AbstractHandler):
PATH = "/async"
COMMAND = "start"
- PROGRESS_INTERVAL = 2
+ PROGRESS_INTERVAL = 1.5
EVENT_PATTERN = re.compile(r"^(package|file|interaction)", re.I)
INTERACTION = Interaction.All