Commit Graph

5826 Commits

Author SHA1 Message Date
Gonzalo Odiard
31d8de55a7 TTS: Cache the voices list 2014-11-12 15:17:33 -03:00
Gonzalo Odiard
57bd0890f5 Add a list of language names to translate
To display a list of translated language names in the UI,
we add a list of the available languages, because the espeak
language names are not translated.
2014-11-12 15:16:51 -03:00
Gonzalo Odiard
d7c9645b60 Move SpeechManager from sugar to sugar-toolkit-gtk3
This is done to be able to use this implementation of the feature
in the activities. A complementary patch is needed in sugar module.
2014-11-12 15:16:40 -03:00
Gonzalo Odiard
952b8275a1 Add a testing method to open a activity with a uri
This can be used in the test to check if the activity can manage
different file formats.
2014-11-11 12:03:02 -03:00
Sam Parkinson
f48c3247f6 Merge branch 'godiard-bundlebuilder_gitls' 2014-10-18 19:31:08 +11:00
Martin Abente Lahaye
177fcba84b Release 0.103.0 2014-10-15 15:08:03 -03:00
Gonzalo Odiard
e50a90c243 Bundlebuilder check if activity files are in git
git version 1.9.3, in a activity directory created inside sugar-build/activities
return a empty string when the command "git ls-files" is executed,
and no repository is configured.
We need verify that condition, and process a file list from the filesystem.
2014-10-13 23:01:29 -03:00
Walter Bender
d6ea265e7f Merge branch 'tchx84-spent-times-try1' 2014-10-08 09:46:25 -04:00
Martin Abente Lahaye
98a29ae12c Save spent time on activities
Use set_active and save events to keep track of the time,
in seconds, that the activity is on the main screen. The
time is calculated and stored each time an activity is
open/resumed and closed. Therefore, each activity entry
will have an array of seconds for each time it was used.

This makes a 1 to 1 relationship between the spent and
lauch times. In orders words, we can reflect not only the
"when", but also the " for how long".

Even though this time does not necessarily represents the
real time the user "used" the activity, it is a low-cost
approach for reflecting time.

This is a long requested featured from deployments that have
been using statistics tools on journal metadata, and this
patch is already being used by OLPC-AU.

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
2014-10-02 13:24:59 -04:00
Martin Abente Lahaye
16617b22d7 Release 0.102.0 2014-07-01 07:08:42 -04:00
Martin Abente Lahaye
85b173eb25 Remove Palette logic out of PaletteWindow
PaletteWindow is the parent class of two different subclases,
Palette and _ToolBarPalette. Palette uses state changes intensively
in order to display secondary content, but _ToolBarPalette does not.

Because of this, Palette overwrites PaletteWindow's popup and popdown
methods adding one extra param called "state". This param is not required
either in PaletteWindow and specially not in _ToolBarPalette.

Therefore, any piece of code inside PaletteWindow which is meant for
Palette subclassing, should be moved out of PaletteWindow and placed
in the Palette class, where it corresponds.

This patch fixes the cases where _ToolBarPalette breaks because of this
mismatch.

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
2014-06-24 16:27:05 -03:00
Martin Abente Lahaye
2f19a41432 Fix black palettes
Push the palette widget opening process to the latest
in order to avoid the race condition where the animation
takes of the place of the real palette.

Fixes #2184

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
2014-06-24 15:57:35 -03:00
Gonzalo Odiard
2456465d79 Enable collaboration by default on activities
When we implemented read max_participants from activity.info [1]
we changed the default value of max_participants, from 0 to 1.
Before, was responsability of the activities set max_participants == 1,
when the activity not implemented collaboration.
This change make the default backwards compatible.

[1] d0cca91fe8
2014-06-18 14:06:10 -04:00
Sam Parkinson
6e81c67622 Remove a double / in webkit1 activity's request's filenames 2014-06-13 09:43:50 -03:00
Gonzalo Odiard
c70e5c678d Fix regression introduced by b9d6b628a9
When calculated the palette height based in the size of children,
forgoten add the border size. That moved the palette in the device icons
4 pixels to the bottom, then the gap was miscalcuated and the border
button border was not draw.

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-05-30 15:51:11 -04:00
Gonzalo Odiard
dfeba6184e Fix drawing of gap on palettes attached to widget - Fixes #4776
In Gtk 3.10, Gtk.Window is drawing a gray border around the palette.
This patch draw a black rectangle defore we draw Gtk.render_frame_gap
to draw the border but with a gap to connect to the attached widget.

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-05-30 15:50:37 -04:00
Martin Abente Lahaye
45e7ba5ed6 Fix and clean Palette secondary label
Removes unnecessary code ie., changing label color.

Refactor label settings, to put all in the same place.

Fix changes to label_alignment that does not honor
original vertical padding settings.

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
2014-05-28 17:26:45 -03:00
Gonzalo Odiard
b9d6b628a9 Show palettes at the screen bottom with the right size - Fixes #4673
On Gtk 3.10, Gtk.Menu at the bottom of the screen are resized
to avoid fall out of the screen, then report a wrong height.
We need calculate the size of the children and move the Menu up.

This problem is visible on the Clipboard icon palettes,
and in journal objects palettes at the bottom of the screen.

This patch also rename a variable 'rect' to 'req', because is
a Requisition (width, height) and not a Rectangle (x, y, width, height).

Finally, to avoid a error with the secondary text on the palette,
when copy text from the terminal, reove the '¬r' character.

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-05-28 14:35:20 -04:00
Gonzalo Odiard
f157b1148e Avoid breaking activity startup by dbus timeout on sigle instance - Fixes #4773
This problem only happen in activities configured with the option -s
in the activity.info "exec" field, and the objective is use a single process,
even when starting more than one instance. If the process do not reply,
start a new process, instead of show a error.

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-05-21 14:40:51 -04:00
Gonzalo Odiard
43a4611d75 Pep8 and pyflakes fixes to sugar-activity 2014-05-20 17:16:20 -04:00
Daniel Narvaez
987068959f Test commit 2014-05-11 22:21:12 +02:00
Daniel Narvaez
34e7a7fc55 Test commit 2014-05-11 22:19:59 +02:00
Gonzalo Odiard
4a565dacac Add a method to get all the extensions associated to a mime type
This is needed to solve problems with mismanaged extensions in the journal.
2014-05-08 11:18:50 -04:00
Gonzalo Odiard
568e0254d7 Pep8 fix 2014-05-05 09:26:37 -03:00
Daniel Narvaez
ec2ebb9ecb Release 0.101.5 2014-05-03 13:15:27 +02:00
Walter Bender
d0cca91fe8 Assign max_participants in activity.info
As part of an effort to "honor" max_participants, this patch supports setting
max_participants in activity.info, thus making it available in the bundle.

By default, if it is not set in the bundle, the previous behavior persists.

In support of this change, a cache of Activity bundles is
maintained. The goal is to eliminate unnecessary calls to the file
system.
2014-05-02 10:41:12 -03:00
Martin Abente Lahaye
72994bd73c Add Icon.get_badge_size
Add get_badge_size method to Icon class, so it can be accessed
by other Icon sub-classes.

ie., jarabe.frame.notification.NotificationPulsingIcon.

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
2014-04-25 15:46:20 -03:00
Gonzalo Odiard
e47feb3b0f Make webactivity and webkit1 implementations independient
We can't import webkit and Webkit2 in the same process
and that was introduced in 4ea52b3173

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-04-09 13:04:37 -03:00
Prasoon Shukla
9e253b5965 Add description in journal object palette - Fixes #4686 2014-04-07 10:20:46 -03:00
Daniel Narvaez
093d18199f Release 0.101.4 2014-04-01 10:52:48 +01:00
edudev
7f1061acbd Add capture device support
Extend acme-volume-alsa.c so it be used to handle not
only the speaker but also the microphone.
2014-03-31 17:41:30 -04:00
Daniel Narvaez
d79815a86d Add missing translations 2014-03-30 11:58:36 +01:00
Daniel Narvaez
6074817264 Modernize gettext setup 2014-03-30 11:54:48 +01:00
Sam Parkinson
4ea52b3173 Now show sugar object choosers as file pickers in web activities 2014-03-29 21:48:28 +00:00
Daniel Narvaez
01ed63ee4b Fixes for pep8 1.5 2014-03-29 19:25:34 +00:00
Sam Parkinson
cbf325d994 Extend API for activities notifications
Add a new method, called notify_user, to the base
Activity class.

This method can be used by activity developers to
send notifications to the new notification front
end. ie.,

    self.notify_user('New High Score!',
                     'Your score is over 8999')
2014-03-28 12:20:51 -04:00
Daniel Narvaez
f92f0efe06 Fix pep8 2014-03-24 09:43:20 +00:00
Sebastian Silva
2a7d4da38a Implementation of pixbufs for use with X11 window icons. 2014-03-23 22:23:02 -05:00
James Michael DuPont
a082cf1cca better debugging 2014-03-19 18:36:20 -05:00
gauravp94
cf45a7a732 Add verbosity to the activity tests 2014-03-17 00:25:24 +05:30
gauravp94
d4b2e87276 port optparse to argparse in bundlebuilder.py 2014-03-11 02:06:35 +05:30
Gonzalo Odiard
7678540056 Remove c implementation of mime methods
Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-03-08 15:34:23 +01:00
Gonzalo Odiard
b02ade879a Implement mime.get_mime_parents using python
This is the only method pending implemented in c,
then we can remove seven files previously used.

Add a test for a corner case untested previously

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-03-08 15:34:23 +01:00
Gonzalo Odiard
faa0d42084 Use Gio.content_type_guess to identify mime type - Fixes #4715
Replace the use of a custom implentation in SugarExt

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-03-08 15:34:23 +01:00
Daniel Narvaez
3c46bf1430 Release 0.101.3 2014-03-08 15:03:09 +01:00
Daniel Narvaez
76fe1d2595 Release 0.101.2 2014-02-14 18:50:40 +01:00
Gonzalo Odiard
e762fa938c Add accelerator to PaletteMenuItem - Fixes #4716
With the port to Gtk3, we lost the display of the keybord shortcut
available in MenuItem.

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-01-31 18:56:42 -03:00
Gonzalo Odiard
53a148f88c Restore suspend catch the wrong exception
Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-01-31 12:30:43 -03:00
Gonzalo Odiard
62b60fa1e1 Inhibit suspend while a activity is shared
In some network environments, suspend/reume can make loose
messages and break collaboration. This patch inhibit suspend
when collaboration start. The implementation can be used by activities
or Sugar to inhibit suspend/resume when needed.

More information in http://dev.laptop.org/ticket/10363

Signed-off-by: Gonzalo Odiard <gonzalo@laptop.org>
2014-01-31 11:08:41 -03:00
Gonzalo Odiard
cf7a5905fd Remove unused code
Fixes pyflakes error

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
2014-01-31 01:48:32 +01:00