5789 Commits (68058cf8a4c74cea5aa6c82ef504ae9fdd7635cf)
 

Author SHA1 Message Date
tch 68058cf8a4 Commit from Sugar Labs by user tch.: 109 of 109 strings translated (0 need review). 9 years ago
Gonzalo Odiard 034706a482 Secondary text on palettes should respect the max width - Fixes #4862
When a activity have a title very long without spaces,
the text can't be wraped with the default wrap mode (WORD)
Use WRAP_CHAR to solve this issue.
9 years ago
Martin Abente Lahaye 5d0e06f07d Release 0.105.2 9 years ago
James Cameron 00c541af4f sugar-activity-web: remove bash specific code 9 years ago
Martin Abente Lahaye e8553c13a1 Add skip-install-mime option to bundlebuilder
Historically, distro packagers have been using bunblebuilder, via
"setup.py install", to populate packages directories and files.

The install procedure uses ActivityBundle.install_mime_type to install
custom mime types, by creating symlinks and updating the system mime
types database via the update-mime-database tool.

When ActivityBundle.install_mime_type is executed during packages
creation, the symlinks end-up broken in the final package and the use
of update-mime-database populates the final packages with a new copy
of the database files which could clash with the system copy.

This patch adds a new option, called --skip-install-mime to "setup.py
install" to skip the execution of ActivityBundle.install_mime_type and
avoid the issues mentioned above.

Activity packagers should use this new option. The creation of symlinks
and the execution of update-mime-database should be done in post install
packaging steps.

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
9 years ago
Gonzalo Odiard fc4d629b50 TTS in the toolkit need initialize gstreamer - Fixes #4851
If is not initialized, the check for the espeak plugin will fail.
This patch also check for the espeak plugin at the beginnig
avoiding check every time the function enabled() is called.
9 years ago
James Cameron 4c22ba5b35 Add escape key to palette windows
Popdown a palette window in response to escape key.
9 years ago
Martin Abente Lahaye 9e34750ffd Release 0.105.1 9 years ago
Gonzalo Odiard 8224fefc50 Pep8 and pyflakes fixes 9 years ago
Gonzalo Odiard 2186c53aeb Palettes based in GtkMenu do not have present() method
There are two different palette widgets in Sugar.
_PaletteMenuWidget is a Gtk.Menu and  _PaletteWindowWidget is a Gtk.Window.
Only the palettes where the widget is a Gtk.Window can do present()
9 years ago
Gonzalo Odiard 5818721818 Merge branch 'treeview_perf2-try2' of https://github.com/godiard/sugar-toolkit-gtk3 into godiard-treeview_perf2-try2 9 years ago
Gonzalo Odiard bbdebce0d4 Simplify routine used to get the list of files from git
This change remove duplicated code
9 years ago
Gonzalo Odiard 34b0e17e95 Add screenshots to ignored dirs in bundlebuilder
After add the directory to the IGNORE_DIRS array,
we need make the standard procedure to get the list off files
for the bundle, get_files_in_git honor the configured ignored
files and dirs. That was not a problem until now,
because that files was already not added to git,
but in the case of the screenshots, are included in git,
but we don't want include them in our bundles.
9 years ago
Gonzalo Odiard 7a9510a187 Remove CellRendererInvoker
This invoker is not used anymore, now is replaced by TreeViewInvoker.
9 years ago
Gonzalo Odiard 49365e132c New invoker, TreeViewInvoker
This new invoker is able to handle all the palettes on a treeview,
removing the need of one invoker per cell renderer (CellRendererInvoker).
This simplifies the code and makes it more efficient.
Also removes the logic from the CellRendererIcon, which
should only care about drawing itself. [1]

Is important to note than in Gtk3 a CellRenderer is not a GtkWidget
then can't know when the mouse is over it or have the usual events
used by other invokers, making the implementation CellRendererInvoker
very complicate.

This commit also removes the invoker of CellRendererIcon.

The ScrollingDetector logic is simplified too,
because now there are only one invoker instead of one by renderer
and the example code updated.

[1] https://developer.gnome.org/gtk3/stable/GtkCellRenderer.html
9 years ago
Gonzalo Odiard 5626a6c182 Detect scrolling in treviews and optimize drawing
Detecting if the treeview is scrolling we can improve the performance of
the CellRendererIcon by avoiding unneeded calculations.

The example scrollingdetector.py shows how this can be used.  The
changes are backward compatible.

Signed-off-by: Manuel Quiñones <manuel.por.aca@gmail.com>
Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
9 years ago
Gonzalo Odiard 862176de38 Merge branch 'cell_renderer_icon_optimizations' of https://github.com/godiard/sugar-toolkit-gtk3 into godiard-cell_renderer_icon_optimizations 9 years ago
James Cameron f1fc9886cc power: avoid filesystem access if powerd absent
On commodity hardware without olpc-powerd, there is unnecessary
filesystem access.

On XO laptop hardware there are unnecessary errors in log for every
object delete:

	ERROR root: Inhibit Suspend: Could not delete file
	/var/run/powerd-inhibit-suspend/1773

	Exception AttributeError: "'NoneType' object has no attribute
	'endswith'" in <bound method PowerManager.__del__ of
	<sugar3.power.PowerManager instance at 0xa15962c>> ignored

The Clock activity in speaking mode is a good reproducer.

Following changes are made:

- move the directory check to __init__, and set self._path to None if
  olpc-powerd is not present,

- on inhibit_suspend, use self._path, which avoids a check of the
  directory,

- on restore_suspend or __del__, avoid a call to os.unlink if
  olpc-powerd is not present.
9 years ago
James Cameron 2ddd64bace power: suppress failure to remove file
It does not matter if the file cannot be removed, so do not report it.
9 years ago
James Cameron 561271bad1 power: set path to file once 9 years ago
Gonzalo Odiard d9e6fa6813 CellRendererIcon: cache offsets
Instead of calculating them on each render.  The cache is removed when
the size is changed.

Signed-off-by: Manuel Quiñones <manuel.por.aca@gmail.com>
9 years ago
Gonzalo Odiard f08757d75f CellRendererIcon: remove unused frame
The white frame is not visible over the white background.

Signed-off-by: Manuel Quiñones <manuel.por.aca@gmail.com>
9 years ago
Gonzalo Odiard 3a6427cdc6 CellRendererIcon: improve calculation in do_render
Use a more efficient method to check if the pointer is inside the cell,
because we have the cell_area in the do_render method.

Signed-off-by: Manuel Quiñones <manuel.por.aca@gmail.com>
Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
9 years ago
Sam Parkinson a56282991f Add ability to launch a bundle
This commit adds the `launch_bundle` function in `sugar3.activity.
activity` which accesses the same function in the shell is over dbus.
This is means the shell process launches the bundle.  Activities
should not launch child processes as per the Rainbow security model
[1].

[1]  http://wiki.laptop.org/go/Rainbow
9 years ago
Martin Abente Lahaye b8cca638d6 Release 0.105.0 9 years ago
Gonzalo Odiard 026146a081 Pep8 fixes 9 years ago
Gonzalo Odiard 954be953ca Remove new line chars when create linfo files
If a translator add a '\n' char in the summary translation
ConfigParser can't parse the linfo file.
Remove them when the file is created and show a message to warning
to the developer.
9 years ago
Martin Abente Lahaye 06c3f01998 Revert "Add ability to launch a bundle"
This reverts commit 8fcb0b48d3.
9 years ago
Manuel Quiñones 8fcb0b48d3 Add ability to launch a bundle
FIXME, to be written.
9 years ago
Gonzalo Odiard f7966382b8 Read icon attach points when is not possible get the info from gtk
Gtk has deprecated gtk-icon-get-attach-points on version 3.14
We need that information to place pur badges,
this fix read the information from the .icon file

[1] https://developer.gnome.org/gtk3/stable/GtkIconTheme.html#gtk-icon-info-get-attach-points
9 years ago
Sam Parkinson 597721877f Merge branch 'godiard-try-2' 9 years ago
Gonzalo Odiard a43b972d1b Don't break activity startup if .info have 'class' instead of 'exec'
When we ported sugar to Gtk3 we removed the support of the fields
exec and service_name due they were deprecated for a long time [1].
But this is still a problem in deployments, and we already added
compatibility for the service_name field.
Here [3] there is a long thred were we discussed this issue.

[1] ae85dd62d4
[2] 32f97b48c3
[3] http://lists.sugarlabs.org/archive/sugar-devel/2013-October/045404.html
9 years ago
Martin Abente Lahaye 3c88e987e4 Release 0.104.1 9 years ago
Martin Abente Lahaye 12a6d2bccb Update Igbo translations from ibo.po
Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
9 years ago
translation server 802396062d New files added from Sugar Labs based on templates 9 years ago
tch 88881e8261 Commit from Sugar Labs by user tch.: 109 of 109 strings translated (0 need review). 9 years ago
tch da550253b3 Commit from Sugar Labs by user tch.: 109 of 109 strings translated (0 need review). 9 years ago
tch 504aa5a574 Commit from Sugar Labs by user tch.: 109 of 109 strings translated (0 need review). 9 years ago
tch d6a0b5bdef Commit from Sugar Labs by user tch.: 109 of 109 strings translated (0 need review). 9 years ago
tch 68ba00ae48 Commit from Sugar Labs by user tch.: 109 of 109 strings translated (0 need review). 9 years ago
tch da6b4f34f9 Commit from Sugar Labs by user tch.: 1 of 109 strings translated (0 need review). 9 years ago
translation server e705391886 Merge branch 'master' of github.com:sugarlabs/sugar-toolkit-gtk3 9 years ago
translation server 663b1436b0 New files added from Sugar Labs based on templates 9 years ago
translation server f95715c6fe New files added from Sugar Labs based on templates 9 years ago
Martin Abente Lahaye a10da70102 Release 0.104.0 9 years ago
tch 00ee27df63 Commit from Sugar Labs by user tch.: 109 of 109 strings translated (0 need review). 9 years ago
Martin Abente Lahaye f9bfab273d Release 0.103.2 9 years ago
Ignacio Rodríguez ee564948bc Raise the palette window when its mapped
This patch raise the palette window when its mapped
Its use: Gtk.Window.present [1] the user will
be able to saw the palette now when your apply the
test case of #4463

[1] https://developer.gnome.org/gtk3/stable/GtkWindow.html#gtk-window-present
Fixes #4463
9 years ago
Martin Abente Lahaye 7739336fb6 Provide access to Gtk.Clipboard.set_with_data
As described in SL#4307 Gtk.Clipboard.set_with_data is not
introspectable, therefore it can't be accessed though python
Gtk bindings.

Therefore, as a workaround for this issue, we provide acesss
to this method though a custom SugarExt binding.

This solution uses Carlos Garnacho annotations as described in
https://bugzilla.gnome.org/show_bug.cgi?id=656312#c18

Fixes SL#4307.

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
9 years ago
Ignacio Rodríguez 47692f56f0 Log error when the espeak plugin is not installed.
Now when the espeak plugin is not installed there will be an
error (logging.error) in the log. Instead of the ugly message
of Gst
Also, if Gst isnt installed it debug a error too.

Fixes #3345
9 years ago