4911 Commits (2bfb38ef827e31c11c3fc7c4158c08e6dc3c6bd7)
 

Author SHA1 Message Date
Sascha Silbe 9d45394d40 fix whitespace mistake introduced by c7a80a1
Signed-off-by: Sascha Silbe <silbe@activitycentral.com>
Acked-by: Simon Schampijer <simon@laptop.org>
13 years ago
Sascha Silbe 11bfce1a31 sugar.activity.i18n: add pgettext()
Python 2 will never have pgettext() [1], so we need to ship our own version.
sugar.activity.i18n is the best place for that.

[1] http://bugs.python.org/issue2504#msg122482

Signed-off-by: Sascha Silbe <silbe@activitycentral.com>
Acked-by: Simon Schampijer <simon@laptop.org>
13 years ago
Simon Schampijer b30bc0151c bundlebuilder: genpot: don't use absolute paths in filenames (SL#2508)
[tweaked description; minor style fix]
Signed-off-by: Sascha Silbe <silbe@activitycentral.com>
Tested-By: Sascha Silbe <silbe@activitycentral.com>
Reviewed-By: Sascha Silbe <silbe@activitycentral.com>
13 years ago
Pootle daemon 6a4966f4ce Commit from Sugar Labs: Translation System by user RafaelOrtiz.: 40 of 40 messages translated (0 fuzzy). 13 years ago
Martin Dengler 45fc0b6186 Throw MalformedBundleException on broken zip files
sugar.bundle.bundle.Bundle users (e.g.
jarabe.model.bundleregistry.BundleRegistry._add_bundle) only expect
MalformedBundleException to be thrown, not exceptions of zipfile.

This patch solves the most severe issue in #1876: filling up the
filesystem with temporary files that won't be deleted afterwards.

Before we can consider this bug completely fixed, we still need
to do something for the remaining issues:

 1) Unpacking shouldn't be attempted if there isn't a safety margin

 2) System becomes unresponsive during unpacking

 3) No progress indication for the operation, so users are tempted
    to click multiple times

 4) No error messages displayed for unpacking errors, which is a
    common Sugar nuisance.

http://bugs.sugarlabs.org/ticket/1876#comment:5 offers possible
strategies for (1) and (2).

Signed-off-by: Martin Dengler <martin@martindengler.com>
Signed-off-by: Bernie Innocenti <bernie@codewiz.org>
[style fixes, adjusted description]
Signed-off-by: Sascha Silbe <silbe@activitycentral.com>
Reviewed-by: Aleksey Lim <alsroot@activitycentral.org>
13 years ago
Sascha Silbe 924e2e62bf fix sugar-emulator detection logic broken by 814ab2d (has_key() cleanup)
This broke Shutdown and Restart (buddy menu).

Signed-off-by: Sascha Silbe <silbe@activitycentral.com>
13 years ago
Pootle daemon b445032cac Commit from Sugar Labs: Translation System by user khaled.: 40 of 40 messages translated (0 fuzzy). 14 years ago
Pootle daemon 5c8256c264 Commit from Sugar Labs: Translation System by user mschlager.: 40 of 40 messages translated (0 fuzzy). 14 years ago
Pootle daemon 5055960c75 Commit from Sugar Labs: Translation System by user danishka.: 40 of 40 messages translated (0 fuzzy). 14 years ago
Sascha Silbe 3b0e761f4a XoColor: don't choke if passed the wrong type (SL#1408)
Color data is stored in the Journal as a JSON dump, so we can get back
arbitrary types. XoColor already checks the color string for validity and
handles invalid strings gracefully, so it makes sense to enhance this to
invalid types as well.

Acked-by: Simon Schampijer <simon@schampijer.de>
14 years ago
Simon Schampijer 18e39672ce Apply new version scheme as well to content bundles #2425
Reviewed-by: James Cameron <quozl@laptop.org>
14 years ago
Simon Schampijer aadfeed305 bundlebuilder: install mimetypes.xml and associated icon #2262
As we do create the ActivityBundle in the config of the bundlebuilder
we can use the code from the activitybundle as well to install
the mime type.

Reviewed-By: Sascha Silbe <sascha-pgp@silbe.org>
14 years ago
Sascha Silbe 1adc165a8c bundlebuilder: ignore incorrect pylint warning
pylint isn't smart enough to figure out the return type of Popen.communicate(),
so squelch the warning.

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 46deeb64e6 pylint: sugar.wm._property_change_trapped: allow overriding built-in method
"format" is the name of a parameter of the function we are wrapping, so we
shouldn't change it.

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 0521234fec CellRendererInvoker._redraw_path(): assure column is defined
We know that our code is correct and column should always be assigned, but it
never hurts to act defensively and guard against bugs in other pieces of the
code (or other components like GTK).

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 05fd5fe2d7 ToolInvoker._get_alignments: fix missing self parameter
Caught by pylint. I wonder if we need this piece of code as nobody every
triggered it.

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 7983242f7a pylint cleanup: initialise all attributes in __init__()
Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe adba508d8f pylint cleanup: pass format parameters to log functions instead of using %
This avoids the overhead from the string formatting on production systems.

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe ff16cb0fa9 pylint cleanup: disable warnings for reasonable catch-all exception handlers
Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 431e36a427 sugar.util: use logging.exception instead of traceback.format_exc()
logging.exception() handles exceptions nicely for us, no need to explicitly
use traceback.

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 3d227102c4 pylint cleanup: remove unused imports
Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe eacce98f88 pylint cleanup: replace disable-msg with disable
Adapt to upstream format change.

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 7acfbd070f style cleanup: prefer ' for strings
Tomeu prefers ' for strings, so let's use it wherever we don't have a good
reason to use ".

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 5f13fcfc84 style cleanup: use """ everywhere
Most of the code uses """, so adjust the few deviations.

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 5f8ec81023 PEP8 cleanup: fix deprecated raise syntax
Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 9c7769cc21 PEP8 cleanup: fix whitespace before ':'
Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 73de340d27 PEP8 cleanup: fix spaces around keyword parameters
Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 72ed58cbca PEP8 cleanup: fix inline comment spacing
pep8 wants inline comments to be prefixed by at least two spaces. Let's just
move them to a separate line as that's easier to read anyway.

Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 60707443ea PEP8 cleanup: fix whitespace around operator
Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 814ab2ddf9 PEP8 cleanup: don't use has_key()
has_key() has been deprecated for quite some time now.

Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 4d978fda14 PEP8 cleanup: ensure lines are shorter than 80 characters
Caught by PEP8. This is important for Sugar because the XO has a small screen
where long lines would make the code hard to understand (because you need to
constantly scroll horizontally).

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer<simon@schampijer.de>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe e2231d5620 PEP8 cleanup: fix number of blank lines
Caught by pep8.

Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Sascha Silbe 131c28bb72 fix EOL spaces
Reviewed-by: James Cameron <quozl@laptop.org>
Acked-by: Simon Schampijer <simon@laptop.org>
CC: Aleksey Lim <alsroot@member.fsf.org>
14 years ago
Simon Schampijer c7a80a1e56 Add new numbering scheme #2425
- add class NormalizedVersion to parse and compare the new activity versions
- change the bundlebuilder and activitybundle to use the new scheme, instead
of an int version we expect a string that matches the format defined in
NormalizedVersion
14 years ago
Pootle daemon d8217d293e Commit from Sugar Labs: Translation System by user mschlager.: 40 of 40 messages translated (0 fuzzy). 14 years ago
Simon Schampijer db46363e9d Release 0.90.2 14 years ago
Tomeu Vizoso 29582de67f Add 'cache-palette' property to Invoker #1742
Meaning that the palette will be cached after it's created.
14 years ago
Simon Schampijer b91c2102b4 Release 0.90.1 14 years ago
Tomeu Vizoso 4fb2943ec4 Fix running multiple instances of Browse by adapting to API changes #2404
* sugar/presence/presenceservice.py: Specify the D-Bus interface when
  calling ActivityProperties.GetActivity
* sugar/activity/main.py: Set a default for the --invite option and
  make the create() D-Bus method accept a{sv} so we can pass the
  boolean value.
14 years ago
Tomeu Vizoso 7dedaeb7bb Cast floats to ints before calling cairo.ImageSurface() #2291
Otherwise Python 2.7 will raise an exception.
14 years ago
Simon Schampijer 969421b0d5 Release 0.90.0 14 years ago
Simon Schampijer 9f1fc0416e Merge branch 'master' of git.sugarlabs.org:sugar-toolkit/mainline 14 years ago
Simon Schampijer 106b9fba68 Do not break if the string contains no conversion specifier #2354 14 years ago
Pootle daemon 1540436bb8 Commit from Sugar Labs: Translation System by user tomeu.: 40 of 40 messages translated (0 fuzzy). 14 years ago
Pootle daemon 5326ebf53c Commit from Sugar Labs: Translation System by user mschlager.: 40 of 40 messages translated (0 fuzzy). 14 years ago
Tomeu Vizoso a2b8518489 Don't try to share the activity if we couldn't find a suitable connection #2217 14 years ago
Simon Schampijer e398f58e92 Release 0.89.5 14 years ago
Tomeu Vizoso 0002c93e96 sugar.presence: Remove dead code and make clear which methonds are deprecated 14 years ago
Tomeu Vizoso e21ab06e34 Read the public and private keys lazily 14 years ago
Tomeu Vizoso d780248e87 Use Account.ConnectionStatus instead of Account.Connection.Status 14 years ago