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>
2010-11-23 17:14:34 +01:00
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>
2010-11-23 17:14:34 +01:00
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>
2010-11-23 17:14:33 +01:00
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>
2010-11-23 17:14:33 +01:00
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>
2010-11-23 17:14:33 +01:00
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>
2010-11-23 17:14:33 +01:00
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>
2010-11-23 17:14:32 +01:00
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>
2010-11-23 17:14:32 +01:00
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>
2010-11-23 17:14:32 +01:00
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>
2010-11-23 17:14:31 +01:00
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
2010-11-09 10:53:05 +01:00
Tomeu Vizoso
29582de67f
Add 'cache-palette' property to Invoker #1742
...
Meaning that the palette will be cached after it's created.
2010-10-14 19:06:31 +02:00
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.
2010-10-05 16:36:13 +02:00
Tomeu Vizoso
7dedaeb7bb
Cast floats to ints before calling cairo.ImageSurface() #2291
...
Otherwise Python 2.7 will raise an exception.
2010-10-04 16:56:26 +02:00
Simon Schampijer
106b9fba68
Do not break if the string contains no conversion specifier #2354
2010-09-29 16:15:59 +02:00
Tomeu Vizoso
a2b8518489
Don't try to share the activity if we couldn't find a suitable connection #2217
2010-09-10 09:45:06 +02:00
Tomeu Vizoso
0002c93e96
sugar.presence: Remove dead code and make clear which methonds are deprecated
2010-08-30 19:21:35 +02:00
Tomeu Vizoso
e21ab06e34
Read the public and private keys lazily
2010-08-26 17:07:15 +02:00
Tomeu Vizoso
d780248e87
Use Account.ConnectionStatus instead of Account.Connection.Status
2010-08-26 15:26:33 +02:00
Martin Abente
4260a53d3f
Merge branch 'master' of gitorious@git.sugarlabs.org:sugar-toolkit/mainline
2010-08-23 14:22:49 -04:00
Martin Abente
f0a570b5ae
Delete activities profile data when uninstall #2074
...
When activities are uninstalled, profile data persists. Profile
data can consume a lot of storage space. Therefore it is necessary
to delete it when required.
Signed-off-by: Martin Abente <mabente@paraguayeduca.org>
2010-08-23 14:09:33 -04:00
Tomeu Vizoso
c56154d938
Remove sugar/__init__.py, it should come from sugar-base #1868
2010-08-23 19:27:57 +02:00
Tomeu Vizoso
d156ff56a8
Address comments from Simon's review
2010-08-20 16:25:13 +02:00
Tomeu Vizoso
1af1bc9713
Address several nitpicks from Marco
2010-08-20 15:33:54 +02:00
Tomeu Vizoso
56679a3de6
Rename ActivityHandle.handle_invite to ActivityHandle.invited
2010-08-20 15:33:54 +02:00
Tomeu Vizoso
d66eb39c9b
Remove unused constant
2010-08-20 15:33:54 +02:00
Tomeu Vizoso
6a12411477
Add copyright statement due to the collaboration refactoring
2010-08-20 15:33:54 +02:00
Tomeu Vizoso
fdfacaf26f
Misc. pylint fixes
2010-08-20 15:33:54 +02:00
Tomeu Vizoso
fab271ac9c
Wrap lines with more than 80 chars
2010-08-20 15:33:54 +02:00
Tomeu Vizoso
ead42a6945
Remove some unused imports
2010-08-20 15:33:54 +02:00
Tomeu Vizoso
1d16629d1b
For several reasons, a shared activity won't survive to its connection
...
disconnecting and coming back.
2010-08-20 15:33:54 +02:00
Tomeu Vizoso
cd6c0101af
No need to dispose the buddies currently in the activity, as it is information that is needed through the whole life of the activity instance
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
694c456ed3
Remove misleading comment, we are already listening Closed
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
24df594203
Add the MAC address to the data that gets hashed to get an activity_id
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
d5dbe3616f
Correctly use the connections from ConnectionManager
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
c0ed611aee
Make sure that the connection we choose is connected
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
ba80f2a2c1
Set the properties of the channel after we have joined it
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
1e7f499029
Translate handles if the channel has channel-specific handles (gabble)
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
11d0574b3f
Log when we fail to find a share activity for a given id
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
633214e2b6
Call the new invite method in ActivityService InviteCommand and keep a stub for Invite
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
7136145667
Add WOCKY_DEBUG to ~/.sugar/debug
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
6b965fa98d
Add mission control env vars for debugging
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
8da18fe2aa
Track the buddies inside the activity
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
363f828205
Handle invitations using Mission Control 5.
...
src/sugar/activity/activity.py: If the activity is being invoked to
handle an invite, create a Client.Handler instance and share the
activity when HandleChannels is invoked.
src/sugar/activity/activityfactory.py,
src/sugar/activity/activityhandle.py,
src/sugar/activity/main.py: Add a -i switch that indicates to the
activity that it should handle the channel from an invitation.
src/sugar/presence/activity.py: Expose Activity.room_handle.
src/sugar/presence/presenceservice.py: Add get_activity_by_handle().
src/sugar/presence/util.py: Add get_account_for_connection().
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
af6e3aa5ef
Restore use of ActivityProperties.GetActivity
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
46159e987b
Pass the account path to the Activity on creation
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
1a4c721f3d
Identify buddies and activities by their account and ids instead
...
of connection and handle.
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
cc8ecd81e7
Add src/sugar/presence/util.py
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
bd3a4ca747
Take into account the "private" property when updating the scope toolbutton
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
ce87bb3ff6
Only add ourselves to a channel if we are in local_pending
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
fbee730549
Implement inviting buddies to a private activity
2010-08-20 15:33:53 +02:00
Tomeu Vizoso
37d7fc1075
Add src/sugar/util.py to the Makefile
2010-08-20 15:33:52 +02:00
Tomeu Vizoso
6f6b86d1e2
Implement Buddy.object_path()
2010-08-20 15:33:52 +02:00
Tomeu Vizoso
9c1275e4c8
Implement Activity.get_channels()
2010-08-20 15:33:52 +02:00
Tomeu Vizoso
043d3b0ee7
Emit the buddy-left signal
2010-08-20 15:33:52 +02:00
Tomeu Vizoso
12cd353620
Implement leaving an activity
2010-08-20 15:33:52 +02:00
Tomeu Vizoso
2db82c1722
Emit the buddy-joined signal
2010-08-20 15:33:52 +02:00
Tomeu Vizoso
f9b0d68a48
Refactor the logic for sharing into _ShareCommand and implement
...
joining a shared instance with _JoinCommand.
2010-08-20 15:33:52 +02:00
Tomeu Vizoso
a0b9394846
Replace enough of the old PS so we can share an activity instance publically
...
on the network.
2010-08-20 15:33:52 +02:00
Tomeu Vizoso
98cc77f1fb
Replace enough of the old PS so we can join an activity instance on the network.
...
* src/sugar/activity/activity.py: Get the shared activity wrapper from
sugar.presence.
* src/sugar/activity/activityfactory.py: Disable checking in the PS for
activity_id duplicates.
* src/sugar/presence/activity.py: Remove the PS dependency and query Telepathy
directly. Implemented enough to join an activity.
* src/sugar/presence/buddy.py: Remove the PS dependency and query Telepathy
directly. Implemented enough to join an activity. Added an Owner subclass of
Buddy()
* src/sugar/presence/presenceservice.py: Remove the PS dependency and query Telepathy
directly. Implemented enough to join an activity.
* src/sugar/presence/util.py: Add ConnectionManager for discovering and tracking
connections.
2010-08-20 15:33:52 +02:00
Simon Schampijer
981707c112
Print warnings about the deprecated activity.info fields
2010-08-17 17:25:19 +02:00
Simon Schampijer
acd8095a29
Revert "Support dropped for activity.info fields 'service_name' and 'class'"
...
This reverts commit e11b7d3196
.
2010-08-17 16:57:02 +02:00
Simon Schampijer
e11b7d3196
Support dropped for activity.info fields 'service_name' and 'class'
...
You have to use 'bundle_id' and 'exec' instead now.
2010-08-16 16:12:11 +02:00
anishmangal2002
3f68813dd6
Add ErrorAlert inherited from Alert
...
Adds the ErrorAlert class which is an alert inherited from
the base Alert class. This is very similar to the
ConfirmationAlert class with the difference being that it
only displays an 'Ok' button in the Alert popup.
Signed-off-by: anishmangal2002 <anishmangal2002@gmail.com>
2010-08-10 17:46:38 +00:00
Simon Schampijer
f82c2bad4d
Not able to access files on external device from within an activity on new system d.l.o #10218
...
The error we were seeing was that the '(env.get_profile_path(),
'data'))' does not exist yet at system start. Symlinks are created
there when accessing data on an external device. The directory
gets created when an activity like Browse or Terminal has been
run for the first time or you start Read for the first time by
resuming the file on the external device.
http://dev.laptop.org/ticket/10218
2010-08-09 09:25:18 +02:00
Simon Schampijer
abda2edc04
Remove unneeded debug logs #1861
2010-07-07 11:08:59 +02:00
Bernie Innocenti
e90fccfd37
Use set_toolbar_box() in example code.
...
The set_toolbox() method is obsolete, so let's not advertise it.
Signed-off-by: Bernie Innocenti <bernie@codewiz.org>
2010-07-01 09:12:51 -04:00
Bernie Innocenti
e2ab351b36
Set default accelerators for Copy and Paste buttons
2010-07-01 09:12:51 -04:00
Simon Schampijer
3aa0995096
Bundelbuilder should not use localized activity name #1968 (Walter Bender)
...
The localized activity name is only used for
user-facing strings. The .xo and .tar files are
left in the original name.
2010-06-03 08:56:42 +02:00
Aleksey Lim
883fefe782
Cannot delete stalled download from journal #1987
2010-06-02 15:01:45 +00:00
Aleksey Lim
845d2534e6
Reset timeout delay on every TitleEntry change #1948
2010-06-02 14:56:28 +00:00
Simon Schampijer
e497eb15ba
Fix keep functionality in activities
...
Introduced by #1765
2010-03-29 23:48:23 +02:00
Aleksey Lim
161aec771e
Display a message when an activity fails to start (based on wadeb patches) #1447
2010-03-10 16:35:09 +00:00
Simon Schampijer
2a52c9493b
A little bit of pylint cleanup
2010-03-10 10:23:30 +01:00
Sascha Silbe
bb323a4efa
check syntax of private key ( #1568 )
...
Check that header and footer of the private key are present in order to detect
corrupted key files.
Signed-off-by: Sascha Silbe <sascha-pgp@silbe.org>
2010-03-09 23:34:59 +00:00
Sascha Silbe
d38d865c7c
Revert "Merge commit 'refs/top-bases/t/bug-1568' into t/bug-1568"
...
This reverts commit 12016d5408
, reversing
changes made to d006092d37
.
2010-03-09 23:28:18 +00:00
Sascha Silbe
12016d5408
Merge commit 'refs/top-bases/t/bug-1568' into t/bug-1568
2010-03-09 22:59:57 +00:00
Tomeu Vizoso
d006092d37
Log saving errors in activities #1703
2010-03-09 22:33:23 +01:00
Wade Brainerd
63a5dcef05
Deprecate host_version #1509
2010-03-09 22:28:50 +01:00
James Cameron
f8ef93bd21
Removes the use of O_SYNC on logs #1656
...
With O_SYNC on open of log files, on systems with slow filesystem random
write performance, there is random activity startup time.
2010-03-09 22:23:55 +01:00
Aleksey Lim
6921bcd67d
Do not fail while closing object less activities #1714
2010-03-09 18:56:21 +00:00
Sascha Silbe
b64930b2eb
check private key syntax
2010-03-08 20:54:05 +00:00
Aleksey Lim
3bf70d642c
Override canvas property in Activity class #1795
2010-03-08 19:01:53 +00:00
Simon Schampijer
7978c55fdf
Create the DSObject update listener as well for existing entries
2010-02-13 14:59:05 +01:00
Sayamindu Dasgupta
e6aa91ba3f
Merge branch 'master' of git://git.sugarlabs.org/sugar-toolkit/gettext-enhancements
2010-02-10 20:56:32 +05:30
Sayamindu Dasgupta
d00d9b6431
More cleanups for i18n.py
2010-02-10 20:53:09 +05:30
Sayamindu Dasgupta
1b600b147d
Make the dictionary sorting a bit more sensible
2010-02-09 17:43:18 +05:30
Sayamindu Dasgupta
4552050136
Clean up docstring
2010-02-09 17:41:10 +05:30
Sayamindu Dasgupta
1817caf30f
Consistent variable names
2010-02-09 17:13:04 +05:30
Sayamindu Dasgupta
ffe3504e0a
Should be and, and not or
2010-02-08 23:46:22 +05:30
Sayamindu Dasgupta
85840b269f
Style and PEP8 fixes
2010-02-08 23:45:39 +05:30
Simon Schampijer
394870f4ad
Synchronize changes made to a Journal entry #1358
2010-02-06 23:08:17 +01:00
Tomeu Vizoso
b5bcbe2ed4
Remove file that was there by mistake
2010-02-06 12:55:43 +01:00
Sayamindu Dasgupta
415f3a3066
Describe the args of the i18n methods
2010-02-01 16:28:19 +05:30
Sayamindu Dasgupta
259fca2caa
Import in two lines instead of one
2010-02-01 16:24:58 +05:30
Aleksey Lim
9f9adda1ab
Merge branch 'master' of git.sugarlabs.org:sugar-toolkit/mainline
2010-01-31 16:42:18 +00:00
Aleksey Lim
4a4ea538ca
Supplement #1687 by docstring
2010-01-31 16:41:34 +00:00
Simon Schampijer
a3c68d5109
removed leftover
2010-01-31 17:14:19 +01:00
Aleksey Lim
6f3ecbdb1f
New color to highlight items while hovering over #1693
2010-01-31 16:10:00 +00:00
Aleksey Lim
fea8acec84
Get pure icon surface w/o creating any widgets #1687
2010-01-25 17:40:58 +00:00