Connecting a non python activity to sugar

Paul Fox pgf at foxharp.boston.ma.us
Mon Mar 31 08:52:10 EDT 2008


bert wrote:
 > On 31.03.2008, at 06:44, Steve Lewis wrote:
 > > Any foreign application - say opera or program I write in Java has two
 > > entried as an avtivity - one with the SVG and a second anonymous  
 > > window
 > > which is the real application
 > >  I have been trying to figure out how a smart application capable of
 > > talking to the D-BUS and with access to the bindle and application  
 > > ids can
 > > integrate with sugar in the same ways that a python application can
 > > Can anyone give me pointers
 > 
 > 
 > http://wiki.laptop.org/go/Low-level_Activity_API
 > 
 > Also, try the sugarize script and library:
 > 
 > http://lists.laptop.org/pipermail/devel/2008-January/009387.html
 > 
 > (maybe that should be added to the Wiki)

indeed -- that would be a nice addition.  i'm using that script,
along with the little libsugarize shared lib hook, with good
success.  i think many people have found versions of that script
via the forums, but it would be good to have it in a
quasi-official place.  (i didn't realize where it had originated.)

on that subject, i've been wondering about a related issue.

my activity (RoadMap, which is a GPS-enabled street-mapping
program) runs in a single X-window (modulo the occasional
dialog box).  it has the ability to spawn a second program (a GPS
"console", which gives an "available satellite" display) which
of course creates a second X-window.  this is fine, as long as you
quit from the spawned program before doing something sugary to
move away from its window (e.g., alt-tab).  but if you obscure its
window, you can never get back to it, since sugar knows nothing
about it.  this isn't really a program that should be a
full-fledged activity -- it can run standalone, but one
usually invokes it from RoadMap ("Hmm -- I'm not getting a fix --
where are my satellites?").  is there a way of wrapping the
second application in a shared lib similar to libsugarize such
that sugar would know about its window in at least some minimal
way?  without this, the program gets "lost" from a UI point of
view.

(i realize that needing a second window is rather un-sugary.  in a
new activity, it would probably be a tab, for instance.)

paul
=---------------------
 paul fox, pgf at foxharp.boston.ma.us (arlington, ma, where it's 32.5 degrees)



More information about the Devel mailing list