Re: [sugar] Triaging Glucose laptop

2008-06-23 Thread Marco Pesenti Gritti
Yup, I will. Give it a couple days, since the exact process is being
discussed right now on the OLPC tech team mailing lists.

Marco

On Mon, Jun 23, 2008 at 7:03 AM, David Farning [EMAIL PROTECTED] wrote:
 On Sun, 2008-06-22 at 04:16 +0200, Marco Pesenti Gritti wrote:
 Hello,

 as you probably noticed trac is a mess, no one payed attention to it
 for too long.

 We have 503 bugs open for Glucose, most of them assigned to me and Tomeu.

 http://dev.laptop.org/query?status=assignedstatus=newstatus=reopenedcomponent=sugarcomponent=datastorecomponent=presence-servicecomponent=journal-activityorder=prioritycol=idcol=summarycol=statuscol=ownercol=typecol=prioritycol=keywords

 As we discussed on irc we need to clean it up. I'm going to do a first
 pass at it in the next few days. I'll start from bugs assigned to me.

 Marco, would you mind documenting your bug cleanup practices at
 http://wiki.sugarlabs.org/go/BugSquad ? It looks like it will be awhile
 before get back to work on the bugsquad.

 thanks
 Dfarning


___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] get_icon_name(): add step kwarg

2008-06-23 Thread Martin Dengler
At the risk of being annoying, may I draw attantion to this patch
again? It's a dependency of one of the patches to #7248 that I'd like
to be able to get in for the upcoming Sugar release...

On Thu, Jun 12, 2008 at 01:15:03AM +0100, Martin Dengler wrote:
 ---
  src/sugar/graphics/icon.py |4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)
 
 diff --git a/src/sugar/graphics/icon.py b/src/sugar/graphics/icon.py
 index d22b412..65f194b 100644
 --- a/src/sugar/graphics/icon.py
 +++ b/src/sugar/graphics/icon.py
 @@ -580,8 +580,8 @@ class CanvasIcon(hippo.CanvasBox, hippo.CanvasItem):
  
  palette = property(get_palette, set_palette)
  
 -def get_icon_state(base_name, perc):
 -step = 5
 +def get_icon_state(base_name, perc, step=5):
 +assert step  0, 'get_icon_state(): step must be positive'
  strength = round(perc / step) * step
  icon_theme = gtk.icon_theme_get_default()
  


pgpGX4inuMdQ5.pgp
Description: PGP signature
___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] get_icon_name(): add step kwarg

2008-06-23 Thread Marco Pesenti Gritti
r+, please add a \n after the assert.

(thanks for drawing attention on this again, and sorry for the delay)

Marco

On Mon, Jun 23, 2008 at 1:28 PM, Martin Dengler
[EMAIL PROTECTED] wrote:
 At the risk of being annoying, may I draw attantion to this patch
 again? It's a dependency of one of the patches to #7248 that I'd like
 to be able to get in for the upcoming Sugar release...

 On Thu, Jun 12, 2008 at 01:15:03AM +0100, Martin Dengler wrote:
 ---
  src/sugar/graphics/icon.py |4 ++--
  1 files changed, 2 insertions(+), 2 deletions(-)

 diff --git a/src/sugar/graphics/icon.py b/src/sugar/graphics/icon.py
 index d22b412..65f194b 100644
 --- a/src/sugar/graphics/icon.py
 +++ b/src/sugar/graphics/icon.py
 @@ -580,8 +580,8 @@ class CanvasIcon(hippo.CanvasBox, hippo.CanvasItem):

  palette = property(get_palette, set_palette)

 -def get_icon_state(base_name, perc):
 -step = 5
 +def get_icon_state(base_name, perc, step=5):
 +assert step  0, 'get_icon_state(): step must be positive'
  strength = round(perc / step) * step
  icon_theme = gtk.icon_theme_get_default()


 ___
 Sugar mailing list
 Sugar@lists.laptop.org
 http://lists.laptop.org/listinfo/sugar


___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


[sugar] [PATCH] Expose the cairo surface in CanvasIcon

2008-06-23 Thread Tomeu Vizoso
Hi,

this is needed for improving the experience when dragging icons around.

Thanks,

Tomeu
From c800a033b3047d63aa6fc4bcefee74255eb4c6b4 Mon Sep 17 00:00:00 2001
From: Tomeu Vizoso [EMAIL PROTECTED]
Date: Mon, 23 Jun 2008 12:52:22 +0200
Subject: [PATCH] Expose the cairo surface in CanvasIcon

---
 src/sugar/graphics/icon.py |5 +
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/src/sugar/graphics/icon.py b/src/sugar/graphics/icon.py
index d22b412..fccef2e 100644
--- a/src/sugar/graphics/icon.py
+++ b/src/sugar/graphics/icon.py
@@ -580,6 +580,11 @@ class CanvasIcon(hippo.CanvasBox, hippo.CanvasItem):
 
 palette = property(get_palette, set_palette)
 
+def get_surface(self):
+return self._buffer.get_surface()
+
+surface = property(get_surface, None)
+
 def get_icon_state(base_name, perc):
 step = 5
 strength = round(perc / step) * step
-- 
1.5.4.3

___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


[sugar] [PATCH] Show the actual icon when dragging activities in the favorites view.

2008-06-23 Thread Tomeu Vizoso
Hi,

any simpler and/or more efficient way to do this is very welcome.

Thanks,

Tomeu
From 8a719943c0c77b1217246169587ae2b948c7114c Mon Sep 17 00:00:00 2001
From: Tomeu Vizoso [EMAIL PROTECTED]
Date: Mon, 23 Jun 2008 13:34:43 +0200
Subject: [PATCH] Show the actual icon when dragging activities in the favorites view.

---
 src/view/home/favoritesview.py |   19 +++
 1 files changed, 15 insertions(+), 4 deletions(-)

diff --git a/src/view/home/favoritesview.py b/src/view/home/favoritesview.py
index 1c948e8..217e909 100644
--- a/src/view/home/favoritesview.py
+++ b/src/view/home/favoritesview.py
@@ -204,10 +204,21 @@ class FavoritesView(hippo.Canvas):
 return False
 
 def __drag_begin_cb(self, widget, context):
-icon_file_name = self._last_clicked_icon.props.file_name
-# TODO: we should get the pixbuf from the widget, so it has colors, etc
-pixbuf = gtk.gdk.pixbuf_new_from_file(icon_file_name)
-
+if self._last_clicked_icon is None:
+return
+
+width, height = self._last_clicked_icon.get_allocation()
+pixmap = gtk.gdk.Pixmap(self.window, width, height)
+cr = pixmap.cairo_create()
+
+cr.set_source_surface(self._last_clicked_icon.surface, 0, 0)
+cr.paint()
+
+pixbuf = gtk.gdk.Pixbuf(gtk.gdk.COLORSPACE_RGB, has_alpha=True,
+bits_per_sample=8, width=width, height=height)
+pixbuf = pixbuf.get_from_drawable(pixmap, pixmap.get_colormap(),
+  0, 0, 0, 0, -1, -1)
+
 hot_spot = style.zoom(10)
 context.set_icon_pixbuf(pixbuf, hot_spot, hot_spot)
 
-- 
1.5.4.3

___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] Sugar 0.81.3 livecd

2008-06-23 Thread Marco Pesenti Gritti
On Sun, Jun 22, 2008 at 8:10 PM, Sameer Verma [EMAIL PROTECTED] wrote:
 Hi Marco,
 How is this different from the Live CD from Rohrmoser and Gramlich
 (http://wiki.laptop.org/go/LiveCd#LiveBackup_XO-LiveCDs)?

The main difference is that this is a Live CD of the latest
development version of Sugar, while LiveBackup_XO-LiveCDs seems to be
built on the official OLPC images.

Marco
___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] Show the actual icon when dragging activities in the favorites view.

2008-06-23 Thread Marco Pesenti Gritti
I thought there was better ways to build a pixbuf from a cairo surface
then fetching in from the X server?

Marco

On Mon, Jun 23, 2008 at 1:35 PM, Tomeu Vizoso [EMAIL PROTECTED] wrote:
 Hi,

 any simpler and/or more efficient way to do this is very welcome.

 Thanks,

 Tomeu

 ___
 Sugar mailing list
 Sugar@lists.laptop.org
 http://lists.laptop.org/listinfo/sugar


___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] Show the actual icon when dragging activities in the favorites view.

2008-06-23 Thread Tomeu Vizoso
Me too :/

I have implemented this following the links in Previous discussions
in http://live.gnome.org/GtkCairoIntegration .

Tomeu

On Mon, Jun 23, 2008 at 2:19 PM, Marco Pesenti Gritti
[EMAIL PROTECTED] wrote:
 I thought there was better ways to build a pixbuf from a cairo surface
 then fetching in from the X server?

 Marco

 On Mon, Jun 23, 2008 at 1:35 PM, Tomeu Vizoso [EMAIL PROTECTED] wrote:
 Hi,

 any simpler and/or more efficient way to do this is very welcome.

 Thanks,

 Tomeu

 ___
 Sugar mailing list
 Sugar@lists.laptop.org
 http://lists.laptop.org/listinfo/sugar



___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] get_icon_name(): add step kwarg

2008-06-23 Thread Martin Dengler
On Mon, Jun 23, 2008 at 01:33:38PM +0200, Marco Pesenti Gritti wrote:
 r+, please add a \n after the assert.

Thanks -- amended patch at the end...I am not a commiter to
sugar-toolkit, in case you thought I could push the patch.  If someone
wants they can pull from my sugar-toolkit repo at somewhere related to
http://dev.laptop.org/git?p=users/mdengler/sugar-toolkit;a=summary .

 (thanks for drawing attention on this again, and sorry for the delay)

Thank *you*.

 Marco

Martin

From 762ad00777e37324b76941ce07b34dec64d54566 Mon Sep 17 00:00:00 2001
From: Martin Dengler [EMAIL PROTECTED]
Date: Mon, 23 Jun 2008 12:58:46 +0100
Subject: [PATCH] get_icon_name() now takes step kwarg for #7248.1

---
 src/sugar/graphics/icon.py |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/sugar/graphics/icon.py b/src/sugar/graphics/icon.py
index d22b412..24b5ca5 100644
--- a/src/sugar/graphics/icon.py
+++ b/src/sugar/graphics/icon.py
@@ -580,8 +580,8 @@ class CanvasIcon(hippo.CanvasBox, hippo.CanvasItem):
 
 palette = property(get_palette, set_palette)
 
-def get_icon_state(base_name, perc):
-step = 5
+def get_icon_state(base_name, perc, step=5):
+assert step  0, 'get_icon_state(): step must be positive\n'
 strength = round(perc / step) * step
 icon_theme = gtk.icon_theme_get_default()
 
-- 
1.5.5.1





pgpRxFLTVKYQG.pgp
Description: PGP signature
___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


[sugar] duplicate favorites

2008-06-23 Thread Mikus Grinbergs
Running Joyride, manually updated to 2056 level.  Happened to look 
at .sugar/default/favorite_activities.  Found many duplicates.

Most duplicate entries were for the same Activity, but at different 
versions.  However, some of the duplicate entries were for the same 
Activity at the same version.

Shouldn't whatever adds entries to favorite_activities be *deleting* 
previous entries for that same Activity ?

mikus

___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] Show the actual icon when dragging activities in the favorites view.

2008-06-23 Thread Erik Blankinship
Here are some utils we've used in the past:

http://mediamods.com/public-svn/camera-activity/tags/54/_camera.c

On Mon, Jun 23, 2008 at 8:25 AM, Tomeu Vizoso [EMAIL PROTECTED] wrote:

 Me too :/

 I have implemented this following the links in Previous discussions
 in http://live.gnome.org/GtkCairoIntegration .

 Tomeu

 On Mon, Jun 23, 2008 at 2:19 PM, Marco Pesenti Gritti
 [EMAIL PROTECTED] wrote:
  I thought there was better ways to build a pixbuf from a cairo surface
  then fetching in from the X server?
 
  Marco
 
  On Mon, Jun 23, 2008 at 1:35 PM, Tomeu Vizoso [EMAIL PROTECTED]
 wrote:
  Hi,
 
  any simpler and/or more efficient way to do this is very welcome.
 
  Thanks,
 
  Tomeu
 
  ___
  Sugar mailing list
  Sugar@lists.laptop.org
  http://lists.laptop.org/listinfo/sugar
 
 
 
 ___
 Sugar mailing list
 Sugar@lists.laptop.org
 http://lists.laptop.org/listinfo/sugar

___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] get_icon_name(): add step kwarg

2008-06-23 Thread Martin Dengler
On Mon, Jun 23, 2008 at 02:08:45PM +0100, Martin Dengler wrote:
 On Mon, Jun 23, 2008 at 01:33:38PM +0200, Marco Pesenti Gritti wrote:
  r+, please add a \n after the assert.
 
 Thanks -- amended patch at the end...I am not a commiter to
 sugar-toolkit [...]

Sorry, forgot to use the right remote/config entry.  Pushed.

  Marco
 
 Martin

Martin


pgpZKk3BWTRO9.pgp
Description: PGP signature
___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] sugar-presence-service 0.81.2 released

2008-06-23 Thread Guillaume Desmottes
Le vendredi 20 juin 2008 à 20:54 +0200, Morgan Collett a écrit :
 The Features on ice release.
 
 tar:
 https://dev.laptop.org/pub/sugar/sources/sugar-presence-service/sugar-presence-service-0.81.2.tar.bz2
 
 

Thanks for managing the release Morgan (I was in holidays last week). :)


G.

___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [Techteam] Making updating easier and Planning for Support

2008-06-23 Thread David Farning
On Mon, 2008-06-23 at 10:36 -0400, Martin Langhoff wrote:
 On Sun, Jun 22, 2008 at 11:29 PM, David Farning [EMAIL PROTECTED] wrote:
  Two releases per year make sense.  Particularly when add in the fact that
  we have two hemispheres with opposing springs and falls.
 
 Only if you assume we can get countries in lockstep with us. Any
 number of things can distract the local team from making the upgrade,
 and - wham - they'll be unsupported. When it happens, rather than
 leaving them in the cold I suspect we'll end up with 3 or 4 versions
 to support -
 
  One way of handling the 'stale' issue is to detach activity releases
  from OS releases.  I currently am working on modifying
  addons.mozilla.org to serve activities for
  activities.sugarlabs.org.
 
 Sugar and activities can be making releases a lot more often - and I
 think OLPC should be doing the same. It only makes sense to tag a
 long-term-support release once you've been making smaller ones.

As Kim stated earlier, in the end this becomes a cost of effort issue.
From a developer point of view the more releases the better.  From a
support perspective maintaining several long releases can quickly suck
the energy from a project. 

Dfarning

___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] Home Design: Free Layout View

2008-06-23 Thread Jim Gettys
On Mon, 2008-06-16 at 09:45 -0400, Walter Bender wrote:

 But rather than argue about hand waving, Tomeu's work on making the
 favorite icon layout pluggable seems to be a great compromise. Let a
 thousand flowers bloom.

Yup.  1000 flowers bloom, 990 stink, and we'll pick the sweetest in 6
months or a year.  I've watched it play out that way with compositing
window managers, where the early essays in the art were over the top,
and yet I now have something reasonably tasteful at the end of the
day...
  - Jim

-- 
Jim Gettys [EMAIL PROTECTED]
One Laptop Per Child

___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


[sugar] OLPC News - (2008-06-23)

2008-06-23 Thread Jim Gettys

Tomeu Visozo implemented the Home view UI that allows the user to drag
and drop activities to desired locations on the screen (freeform)
rather than restricting them to the circle. Other activities move
nicely out of the way if you try to drop one on top of another. Look
for this in an upcoming test build soon!

Marco Pesenti Gritti reviewed patches for the freeform Home view as
well as and Benjamin Berg's patches to implement quick activity
switching using the keyboard. He also packaged xulrunner 1.9 final and
adapted the Browse activity to it. Finally he coordinated the Sugar
0.81.3 release and made big progresses on a Fedora 9 based Sugar liveCD.
Note that xulrunner 1.9 final is the version used in Firefox 3, which
provides much better memory use than previous versions.  This should
significantly help our memory usage.  Less than a week after release,
Firefox 3 already accounts for 4% of web browser use on the Internet.

Morgan Collett released Chat-41 and Presence Service 0.81.2 with the
changes required for non-Sugar Jabber clients to chat with XOs. He
registered as an Afrikaans translator on Pootle and translated Sugar
and some of the core activities.

Faisal Anwar of Media Modifications further developed the online
Sugar Almanac of best practices and working code snippets.  This
week he documented and debated with the community how to best use the
datastore api, and began entries on logging and internationalization.

Sayamindu Dasgupta arrived at the OLPC offices this week for a two
week long visit. He made a presentation on the OLPC translation
infrastructure, and had some discussions with members of the tech team
on the various aspects of translation. He also had a meeting with
Evelyn Eastmond, one of the co-authors of Scratch, and explained the
various aspects of Pootle to her. Sayamindu also made some progress on
the support for administrative messages for translation teams in Pootle
during the course of the week.

Chris Ball found and fixed a bug preventing suspend from working on
our new 2.6.25 kernels.  With that out of the way, the extreme power
management mode could be tested -- a machine with wireless off, the
backlight on but dimmed, and occasional wakeups to check the battery
level ran for 16 hours and 15 minutes before turning off.  Next steps
will be to integrate this work in the UI and get it into a build.

Michael Stone reviewed code for the Datastore, XS Backup, Gadget, and
NetworkManager-0.7 projects. He produced and signed a 708 + G1G1
activity pack image which he delivered to QA. Finally, he pushed for
more contributions in the weekly public Software Status meeting, in
personal conversations with Emiliano Pastorino, Sjoerd Simons, Bill
Mccormick, and in conversations with several key Fedora and RedHat
developers present at FUDCON Boston 2008.

Bert Freudenberg reports a new etoys release: fresh from the press:

http://dev.laptop.org/pub/sugar/sources/etoys/etoys-3.0.2029.tar.gz
http://dev.laptop.org/pub/sugar/sources/etoys-activity/etoys-activity-83.tar.gz

bundled:

http://etoys.laptop.org/rpms/etoys-3.0.2007-1.noarch.rpm
http://etoys.laptop.org/rpms/Etoys-83.xo

Improvements include: Pango fixes (tested with Nepalese), new DBus
bindings, updated QuickGuides, a few more strings made translatable.
Pango's importance is that it forms the basis for fully international
text layout.

Paul Fox made good progress on the sdcc-based EC firmware -- the code
now fits, but the data segment needs work.  Paul is looking forward to
actually running this code soon.

Ankur Verma continued his work on Internet connectivity using modems
from Sprint and ATT and updated
http://wiki.laptop.org/go/XO_%2B_Modem page with the steps.

Daniel Drake worked on various problems with the Fedora 9 (OLPC-3)
stream including USB automount issues, inability to shutdown/reboot,
sound nodes not accessible to user, and camera functionality.

Faisal Anwar of Media Modifications further developed the online
Sugar Almanac of best practices and working code snippets.  This
week he documented and debated with the community how to best use the
datastore api, and began entries on logging and internationalization.

Walter Bender's sugar digest from last week is available here:
http://lists.laptop.org/pipermail/sugar/2008-June/006546.html


Testing:
Joe Feinstein (with Kim Quirk and Michael Stone) worked on setting up
the community testing project
(http://wiki.laptop.org/go/Friends_in_testing). He also has been
testing the proposed back-up build for G1G1 (8.1.1, or build 708). A
critical bug associated with attaching an external USB mouse was found
in Joyride 2026, where suspend and resume is turned on more
aggressively than the Update.1 builds.

Charlie Murphy set up 15 XOs for Polychronis Ypodimatopoulos'
multi-hop network/cerebro testing project, which involved installing
the most recent 708 build, git and cerebro. Pol kicked of the testing
of the first 10 laptops for this campus testing.

Support:
It finally feels 

Re: [sugar] [PATCH] Expose the cairo surface in CanvasIcon

2008-06-23 Thread Eben Eliason
You may as well expose this in the Icon class as well; we'll certainly
want to make dragging of people, activities, devices, clippings, etc.
look nice and pretty too.

- Eben


On Mon, Jun 23, 2008 at 7:34 AM, Tomeu Vizoso [EMAIL PROTECTED] wrote:
 Hi,

 this is needed for improving the experience when dragging icons around.

 Thanks,

 Tomeu

 ___
 Sugar mailing list
 Sugar@lists.laptop.org
 http://lists.laptop.org/listinfo/sugar


___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] Change GETTEXT_PACKAGE for sugar-toolkit

2008-06-23 Thread Sayamindu Dasgupta
Ok - done.
And pushed to d.l.o
-sdg-


On Wed, Jun 18, 2008 at 1:32 PM, Tomeu Vizoso [EMAIL PROTECTED] wrote:
 Yes, but please also switch to the new domain the two instances below
 still referring to the old one:

 [EMAIL PROTECTED]:~/sugar-jhbuild/source/sugar-toolkit$ rgrep dgettext src/
 src/sugar/activity/activity.py:_ = lambda msg: gettext.dgettext('sugar', msg)
 src/sugar/graphics/alert.py:_ = lambda msg: gettext.dgettext('sugar', msg)

 Thanks,

 Tomeu

 On Tue, Jun 17, 2008 at 10:32 PM, Sayamindu Dasgupta
 [EMAIL PROTECTED] wrote:
 Patch attached. Does it look OK ?
 Thanks,
 Sayamindu


 --
 Sayamindu Dasgupta
 [http://sayamindu.randomink.org/ramblings]

 ___
 Sugar mailing list
 Sugar@lists.laptop.org
 http://lists.laptop.org/listinfo/sugar






-- 
Sayamindu Dasgupta
[http://sayamindu.randomink.org/ramblings]
___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


[sugar] [PATCH] Complete i18n support for sugar-base

2008-06-23 Thread Sayamindu Dasgupta
Patch attached. I also needed to add po/POTFILES.in (I'm not sure how
to make Git show that).
Thanks,
Sayamindu


-- 
Sayamindu Dasgupta
[http://sayamindu.randomink.org/ramblings]


sugar_base_gettext_package.patch
Description: Binary data
___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] Complete i18n support for sugar-base

2008-06-23 Thread Tomeu Vizoso
Hmm, in sugar-base, we may need to do the same as we do in sugar-toolkit.

If for example the shell imports mime, gettext will think that its
domain is 'sugar', not 'sugar-base'.

I think that you need to add this to the top of mime.py:

_ = lambda msg: gettext.dgettext('sugar-base', msg)

There may be a cleaner solution, though...

Regards,

Tomeu

On Mon, Jun 23, 2008 at 8:55 PM, Sayamindu Dasgupta [EMAIL PROTECTED] wrote:
 Thanks to Tomeu on IRC - here's the complete patch. Sorry for the noise :-)
 Thanks,
 Sayamindu


 On Tue, Jun 24, 2008 at 12:14 AM, Sayamindu Dasgupta
 [EMAIL PROTECTED] wrote:
 Patch attached. I also needed to add po/POTFILES.in (I'm not sure how
 to make Git show that).
 Thanks,
 Sayamindu


 --
 Sayamindu Dasgupta
 [http://sayamindu.randomink.org/ramblings]




 --
 Sayamindu Dasgupta
 [http://sayamindu.randomink.org/ramblings]

 ___
 Sugar mailing list
 Sugar@lists.laptop.org
 http://lists.laptop.org/listinfo/sugar


___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] Complete i18n support for sugar-base

2008-06-23 Thread Sayamindu Dasgupta
On Tue, Jun 24, 2008 at 12:45 AM, Tomeu Vizoso [EMAIL PROTECTED] wrote:
 Hmm, in sugar-base, we may need to do the same as we do in sugar-toolkit.

 If for example the shell imports mime, gettext will think that its
 domain is 'sugar', not 'sugar-base'.

 I think that you need to add this to the top of mime.py:

 _ = lambda msg: gettext.dgettext('sugar-base', msg)



Yeah - that seems like a good idea. IIRC, I think we got bit by this
towards the beginning of the year. Apart from that - does the patch
look OK ?
Thanks,
Sayamindu


-- 
Sayamindu Dasgupta
[http://sayamindu.randomink.org/ramblings]
___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar


Re: [sugar] [PATCH] Complete i18n support for sugar-base

2008-06-23 Thread Tomeu Vizoso
Yes, the rest of the patch looks good to me.

Thanks,

Tomeu

On Mon, Jun 23, 2008 at 9:32 PM, Sayamindu Dasgupta [EMAIL PROTECTED] wrote:
 On Tue, Jun 24, 2008 at 12:45 AM, Tomeu Vizoso [EMAIL PROTECTED] wrote:
 Hmm, in sugar-base, we may need to do the same as we do in sugar-toolkit.

 If for example the shell imports mime, gettext will think that its
 domain is 'sugar', not 'sugar-base'.

 I think that you need to add this to the top of mime.py:

 _ = lambda msg: gettext.dgettext('sugar-base', msg)



 Yeah - that seems like a good idea. IIRC, I think we got bit by this
 towards the beginning of the year. Apart from that - does the patch
 look OK ?
 Thanks,
 Sayamindu


 --
 Sayamindu Dasgupta
 [http://sayamindu.randomink.org/ramblings]

___
Sugar mailing list
Sugar@lists.laptop.org
http://lists.laptop.org/listinfo/sugar