[sugar] Where did sugar._sugarext.get_pgrname() go?
Mike C. Fletcher
Mon Nov 12 20:28:41 EST 2007
Marco Pesenti Gritti wrote:
> What was you using the program name for? Maybe what you want is
> Activity.get_bundle_id(), at least I think that's what we used to set
> the program name to. (We had to give using the program name for this
> because there are libraries like xulrunner which mess with it).
This is from the olpcgames mesh.py module. It uses the name to
construct a "unique" DBUS service name for the various olpcgames-based
projects. That is, it tries to create a different name for each game
that uses the wrapper by asking for the program "name" and using that as
the DBUS name for the activity's sharing service.
Substituting a call to get_bundle_id() seems to work fine in the sense
that it lets the code move past the import of the module and I can at
least *seem* to share it (though TicTacToe.activity doesn't seem to
actually share any data).
> On Nov 12, 2007 9:10 PM, Mike C. Fletcher <mcfletch at vrplumber.com> wrote:
>> Hi all,
>> We're going to have quite a few people working on the games next
>> weekend. In preparation I'm attempting to get the olpcgames wrapper
>> working again under jhbuild, at the moment mesh.py is failing because
>> it's using a function called get_prgname() to determine it's dbus name.
>> That method appears to have been removed. It seems that it's just
>> trying to get a DBUS-friendly name for the service. I'm guessing I
>> could create my own version if I had a spec for what it needed to
>> produce to be useful.
>> Anyway, guidance on how to get the current program name would be
>> Sugar mailing list
>> Sugar at lists.laptop.org
Mike C. Fletcher
Designer, VR Plumber, Coder
More information about the Sugar-devel