Skip to content

Commit

Permalink
new locale files
Browse files Browse the repository at this point in the history
  • Loading branch information
RaNaN committed Dec 13, 2011
1 parent 2c84da4 commit cfa3273
Show file tree
Hide file tree
Showing 49 changed files with 27 additions and 50 deletions.
13 changes: 10 additions & 3 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,17 @@
# |version| and |release|, also used in various other places throughout the
# built documents.
#
# The short X.Y version.
version = '0.4'
# The full version, including alpha/beta/rc tags.
release = '0.4.8'
""" [[[cog
from pavement import options
v = options.version.split(".")
cog.outl("version = '%s'" % ".".join(v[:2]))
cog.outl("release = '%s'" % ".".join(v))
]]]"""
version = '0.4'
release = '0.4.9'
# [[[end]]]


# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
Binary file modified locale/cs/LC_MESSAGES/django.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/cs/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/cs/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/cs/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/cs/LC_MESSAGES/setup.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/de/LC_MESSAGES/django.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/de/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Empty file modified locale/de/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Empty file.
Binary file modified locale/de/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/de/LC_MESSAGES/setup.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/es/LC_MESSAGES/django.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/es/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/es/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/es/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/es/LC_MESSAGES/setup.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/fr/LC_MESSAGES/django.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/fr/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Empty file modified locale/fr/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Empty file.
Binary file modified locale/fr/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/fr/LC_MESSAGES/setup.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/it/LC_MESSAGES/django.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/it/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Empty file modified locale/it/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Empty file.
Binary file modified locale/it/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/it/LC_MESSAGES/setup.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/nl/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Empty file modified locale/nl/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Empty file.
Binary file modified locale/nl/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/pl/LC_MESSAGES/django.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/pl/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Empty file modified locale/pl/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Empty file.
Binary file modified locale/pl/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/pl/LC_MESSAGES/setup.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/pt_BR/LC_MESSAGES/django.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/pt_BR/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/pt_BR/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/pt_BR/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/pt_BR/LC_MESSAGES/setup.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/ru/LC_MESSAGES/django.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/ru/LC_MESSAGES/pyLoad.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/ru/LC_MESSAGES/pyLoadCli.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/ru/LC_MESSAGES/pyLoadGui.mo
100755 → 100644
Binary file not shown.
Binary file modified locale/ru/LC_MESSAGES/setup.mo
100755 → 100644
Binary file not shown.
2 changes: 1 addition & 1 deletion module/config/default.conf
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ log - "Log":
int log_size : "Size in kb" = 100
bool log_rotate : "Log Rotate" = True
general - "General":
en;de;fr;it;es;nl;sv;ru;pl;cs;pt_BR language : "Language" = en
en;de;fr;it;es;nl;sv;ru;pl;cs;sr;pt_BR language : "Language" = en
folder download_folder : "Download Folder" = Downloads
bool debug_mode : "Debug Mode" = False
bool checksum : "Use Checksum" = False
Expand Down
39 changes: 1 addition & 38 deletions module/database/FileDatabase.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,6 @@ def deleteLink(self, id):
e = RemoveEvent("file", id, "collector" if not f.package().queue else "queue")

oldorder = f.order
package = f.package

if id in self.core.threadManager.processingIds():
self.cache[id].abortDownload()
Expand All @@ -212,7 +211,7 @@ def deleteLink(self, id):

pyfiles = self.cache.values()
for pyfile in pyfiles:
if pyfile.packageid == package and pyfile.order > oldorder:
if pyfile.packageid == pid and pyfile.order > oldorder:
pyfile.order -= 1
pyfile.notifyChange()

Expand Down Expand Up @@ -576,11 +575,6 @@ def restartFailed(self):
""" restart all failed links """
self.db.restartFailed()

@lock
@change
def fixPackageOrder(self, queue=0):
self.db.fixPackageOrder(queue)

class FileMethods():
@style.queue
def filecount(self, queue):
Expand Down Expand Up @@ -883,41 +877,10 @@ def deleteFinished(self):
self.c.execute("DELETE FROM links WHERE status IN (0,4)")
self.c.execute("DELETE FROM packages WHERE NOT EXISTS(SELECT 1 FROM links WHERE packages.id=links.package)")


@style.queue
def restartFailed(self):
self.c.execute("UPDATE links SET status=3,error='' WHERE status IN (8, 9)")


@style.queue
def fixPackageOrder(self, queue=0):
found = 0
order = 0
i = 0
self.c.execute("SELECT count(*) FROM packages WHERE queue = ?", (queue, ))
count = self.c.fetchone()[0]
if count == 0:
return
while order < count:
self.c.execute("SELECT id FROM packages WHERE packageorder = ? AND queue = ?", (i, queue))
all = self.c.fetchall()
if len(all) == 0:
i += 1
elif len(all) == 1:
self.c.execute("UPDATE packages SET packageorder=? WHERE id = ?", (order, all[0][0]))
order += 1
i += 1
elif len(all) > 1:
self.c.execute("UPDATE packages SET packageorder=? WHERE id = ?", (order, all[0][0]))
order += 1
i += len(all)
del all[0]
self.c.execute("UPDATE packages SET packageorder=packageorder+? WHERE packageorder >= ? AND queue=?", (len(all), order, queue))
for r in all:
self.c.execute("UPDATE packages SET packageorder=? WHERE id = ?", order, r[0])
order += 1


@style.queue
def findDuplicates(self, id, folder, filename):
""" checks if filename exists with different id and same package """
Expand Down
15 changes: 10 additions & 5 deletions module/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -454,9 +454,9 @@ def ask(self, qst, default, answers=[], bool=False, password=False):
info += ")"
elif bool:
if default == self.yes:
info = _("[y]/n")
info = "([%s]/%s)" % (self.yes, self.no)
else:
info = _("y/[n]")
info = "(%s/[%s])" % (self.yes, self.no)
else:
info = "[%s]" % default

Expand Down Expand Up @@ -488,18 +488,23 @@ def ask(self, qst, default, answers=[], bool=False, password=False):
print _("Passwords did not match.").decode("utf-8")

while True:
input = raw_input(qst + " %s: " % info)
try:
input = raw_input(qst + " %s: " % info)
except KeyboardInterrupt:
print "\nSetup interrupted"
exit()

input = input.decode(sys.stdin.encoding)

if input.strip() == "":
input = default

if bool:
# yes, true,t are inputs for booleans with value true
if input.lower().strip() in [self.yes, _("yes"), _("true"), _("t")]:
if input.lower().strip() in [self.yes, _("yes"), _("true"), _("t"), "yes"]:
return True
# no, false,f are inputs for booleans with value false
elif input.lower().strip() in [self.no, _("no"), _("false"), _("f")]:
elif input.lower().strip() in [self.no, _("no"), _("false"), _("f"), "no"]:
return False
else:
print _("Invalid Input")
Expand Down
5 changes: 5 additions & 0 deletions pavement.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@

from paver.easy import *
from paver.setuputils import setup
from paver.doctools import cog

import sys
import re
Expand Down Expand Up @@ -83,6 +84,9 @@
dir="env",
python="python2",
virtual="virtualenv2",
),
cog=Bunch(
pattern="*.py",
)
)

Expand All @@ -91,6 +95,7 @@
"--package-version=%s" % options.version, "--msgid-bugs-address='[email protected]'"]

@task
@needs('cog')
def html():
"""Build html documentation"""
module = path("docs") / "module"
Expand Down
3 changes: 0 additions & 3 deletions pyLoadCore.py
Original file line number Diff line number Diff line change
Expand Up @@ -472,9 +472,6 @@ def setupDB(self):

self.files = FileHandler(self)
self.db.manager = self.files #ugly?

self.files.fixPackageOrder(0)
self.files.fixPackageOrder(1)

def init_webserver(self):
if self.config['webinterface']['activated']:
Expand Down

0 comments on commit cfa3273

Please sign in to comment.