summaryrefslogtreecommitdiffstats
path: root/pyload/plugins
diff options
context:
space:
mode:
Diffstat (limited to 'pyload/plugins')
-rw-r--r--pyload/plugins/accounts/Premium4Me.py3
-rw-r--r--pyload/plugins/accounts/UnrestrictLi.py6
-rw-r--r--pyload/plugins/addons/Premium4Me.py32
-rw-r--r--pyload/plugins/addons/UnrestrictLi.py44
4 files changed, 9 insertions, 76 deletions
diff --git a/pyload/plugins/accounts/Premium4Me.py b/pyload/plugins/accounts/Premium4Me.py
index 7f49cca30..79aa40e2e 100644
--- a/pyload/plugins/accounts/Premium4Me.py
+++ b/pyload/plugins/accounts/Premium4Me.py
@@ -4,6 +4,9 @@ class Premium4Me(MultiHoster):
__name__ = "Premium4Me"
__version__ = "0.03"
__type__ = "account"
+ __config__ = [("activated", "bool", "Activated", "False"),
+ ("hosterListMode", "all;listed;unlisted", "Use for downloads from supported hosters:", "all"),
+ ("hosterList", "str", "Hoster list (comma separated)", "")]
__description__ = """Premium.to account plugin"""
__author_name__ = ("RaNaN", "zoidberg", "stickell")
__author_mail__ = ("RaNaN@pyload.org", "zoidberg@mujmail.cz", "l.stickell@yahoo.it")
diff --git a/pyload/plugins/accounts/UnrestrictLi.py b/pyload/plugins/accounts/UnrestrictLi.py
index 0e2249e1a..2a284a179 100644
--- a/pyload/plugins/accounts/UnrestrictLi.py
+++ b/pyload/plugins/accounts/UnrestrictLi.py
@@ -23,6 +23,12 @@ class UnrestrictLi(MultiHoster):
__name__ = "UnrestrictLi"
__version__ = "0.02"
__type__ = "account"
+ __config__ = [("activated", "bool", "Activated", "False"),
+ ("hosterListMode", "all;listed;unlisted", "Use for hosters (if supported)", "all"),
+ ("hosterList", "str", "Hoster list (comma separated)", ""),
+ ("unloadFailing", "bool", "Revert to standard download if download fails", "False"),
+ ("interval", "int", "Reload interval in hours (0 to disable)", "24"),
+ ("history", "bool", "Delete History", "False")]
__description__ = """Unrestrict.li account plugin"""
__author_name__ = ("stickell")
__author_mail__ = ("l.stickell@yahoo.it")
diff --git a/pyload/plugins/addons/Premium4Me.py b/pyload/plugins/addons/Premium4Me.py
deleted file mode 100644
index 4bcc79b25..000000000
--- a/pyload/plugins/addons/Premium4Me.py
+++ /dev/null
@@ -1,32 +0,0 @@
-# -*- coding: utf-8 -*-
-
-from module.network.RequestFactory import getURL
-from module.plugins.internal.MultiHoster import MultiHoster
-
-
-class Premium4Me(MultiHoster):
- __name__ = "Premium4Me"
- __version__ = "0.03"
- __type__ = "hook"
-
- __config__ = [("activated", "bool", "Activated", "False"),
- ("hosterListMode", "all;listed;unlisted", "Use for downloads from supported hosters:", "all"),
- ("hosterList", "str", "Hoster list (comma separated)", "")]
- __description__ = """Premium.to hook plugin"""
- __author_name__ = ("RaNaN", "zoidberg", "stickell")
- __author_mail__ = ("RaNaN@pyload.org", "zoidberg@mujmail.cz", "l.stickell@yahoo.it")
-
- def getHoster(self):
- page = getURL("http://premium.to/api/hosters.php?authcode=%s" % self.account.authcode)
- return [x.strip() for x in page.replace("\"", "").split(";")]
-
- def coreReady(self):
- self.account = self.core.accountManager.getAccountPlugin("Premium4Me")
-
- user = self.account.selectAccount()[0]
-
- if not user:
- self.logError(_("Please add your premium.to account first and restart pyLoad"))
- return
-
- return MultiHoster.coreReady(self)
diff --git a/pyload/plugins/addons/UnrestrictLi.py b/pyload/plugins/addons/UnrestrictLi.py
deleted file mode 100644
index 0810a22d5..000000000
--- a/pyload/plugins/addons/UnrestrictLi.py
+++ /dev/null
@@ -1,44 +0,0 @@
-# -*- coding: utf-8 -*-
-
-############################################################################
-# This program is free software: you can redistribute it and/or modify #
-# it under the terms of the GNU Affero General Public License as #
-# published by the Free Software Foundation, either version 3 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 Affero General Public License for more details. #
-# #
-# You should have received a copy of the GNU Affero General Public License #
-# along with this program. If not, see <http://www.gnu.org/licenses/>. #
-############################################################################
-
-from module.plugins.internal.MultiHoster import MultiHoster
-from module.network.RequestFactory import getURL
-from module.common.json_layer import json_loads
-
-
-class UnrestrictLi(MultiHoster):
- __name__ = "UnrestrictLi"
- __version__ = "0.02"
- __type__ = "hook"
- __config__ = [("activated", "bool", "Activated", "False"),
- ("hosterListMode", "all;listed;unlisted", "Use for hosters (if supported)", "all"),
- ("hosterList", "str", "Hoster list (comma separated)", ""),
- ("unloadFailing", "bool", "Revert to standard download if download fails", "False"),
- ("interval", "int", "Reload interval in hours (0 to disable)", "24"),
- ("history", "bool", "Delete History", "False")]
-
- __description__ = """Unrestrict.li hook plugin"""
- __author_name__ = ("stickell")
- __author_mail__ = ("l.stickell@yahoo.it")
-
- def getHoster(self):
- json_data = getURL('http://unrestrict.li/api/jdownloader/hosts.php?format=json')
- json_data = json_loads(json_data)
-
- host_list = [element['host'] for element in json_data['result']]
-
- return host_list