Use introspection instead of dbus to set wireless on/off

Using introspection simplify the code a lot,
and some systems have many dbus errors.
This is just a start to use NMClient instead of the dbus interfaces.

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
Find if an activity is GTK2 or 3 in the view source dialog
Delay saving the sound volume, to avoid saving many times

While the user move the slider avoid saving the volume,
and do it when the movement stops.

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
Replace use of dbus on aboutcomputer panel
Merge branch 'wifi_on_off_introspection' of https://github.com/godiard/sugar into godiard-wifi_on_off_introspection
Merge branch 'view-source-toolkit-version-rebase' of https://github.com/SAMdroid-apps/sugar into SAMdroid-apps-view-source-toolkit-version-rebase
Avoid pulsing icon at startup - Fixes #4767

Check if the window is a splash screen before add it,
in all the cases. This check solves the issue originated
by a race condition between the splash window creation and
the creation of the main activity window.

Signed-off-by: Gonzalo Odiard <godiard@sugarlabs.org>
Fix notification badges position and size

Do not use unscaled magic numbers badge size and position,
as this caused badges to look and locate differently with
different SUGAR_SCALING values.

Instead, honor Icon class _BADGE_SIZE for calculating the
badge size.

Also, locate the badge at the bottom-left corner of the icon.

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
Do not cache BuddyMenu in favorites view

Let BuddyMenu be created on-demand.

Remove set_registered method, as this palette is now
created on-demand, makes no sense to modify the current
items as these will be set properly in the next
initialization.

Remove _palette_enabled as this is deprecated code
from previous palette implementation.

Remove self._register_menu and simplify code.

This partch avoids #2184 issue for the buddy icon
palette in favorites view.

Signed-off-by: Martin Abente Lahaye <tch@sugarlabs.org>
More robust locale matching

The locale that is set by the manufacturing data can be of the format
es_UY.UTF-8 where as the format of the locales we get from parsing
available languages is es_UY.utf8

This patch converts UTF-8 suffixes to utf8

Note that this problem has only been observed on OLPC XO images. I was
unsuccessful in convincing OLPC to change their rules for generating
manufacturing data.

Replaces PR #338
Merge branch 'buddy-palette-nocache' of https://github.com/tchx84/sugar into tchx84-buddy-palette-nocache
Merge branch 'tchx84-buddy-palette-nocache'