HTML-based/Browser apps (was Re: anti-cheating)

Tomeu Vizoso tomeu at sugarlabs.org
Thu Feb 12 05:43:38 EST 2009


On Thu, Feb 12, 2009 at 11:25, Mike Dawson <mikeofmanchester at gmail.com> wrote:
> Hey All,
>
> The offline spec is indeed something very cool - I had some time back
> done some work with XSL to try to create something that would have a
> similar effect with Apache cocoon - but nothing can (or should) beat a
> w3c standard.
>
> What we are trying to do in Afghanistan to see if we can offset the
> cost of the laptop is deliver info to the parents using the XO to see
> if we can help them to increase their income - things like home
> business ideas (e.g. Afghan carpets), CV writing etc. for when the
> kids are asleep...
>
> As HTML seems to be the most portable / compact choice we have made a
> collection of info as such - but as per the previous post we would
> rather have it a bit more prominent than making the .xol collection
> file.
>
> I hence copied the help activity to a new folder Econdev.activity:
>
> Left helpactivity.py as it was except for changing the line:
>
> HOME = os.path.join(activity.get_bundle_path(), 'econdev/index.html')
>
> Created activity
> [Activity]
> name = Economic Development
> activity_version = 10
> service_name = af.asmed.EconomicDevelopment
> icon = activity-econdev
> class = helpactivity.HelpActivity
> license = GPLv2
>
> Then there is an SVG I made in Inkscape activity/activity-econdev.svg
> - yet somehow when this folder Econdev.activity is copied to
> ~/Activities and sugar etc. is restarted - no icon turning up.  I also
> tried packaging it as a .xo file and then running the install script
> that put it under /usr/share - it turns up, but no icon...
>
> I went through the log viewer and there didn't seem to be any special
> mention of it...   Is there possibly a problem from not changing the
> Class name of the helpactivity to be unique - or some naming
> convention that I have neglected here?

Only the service_name needs to be unique. Which version of Sugar are
you using? If 0.82, the activity icon is not appearing on the activity
list?

See http://en.flossmanuals.net/Sugar/HomeView in case you dind't knew about it.

Also feel free to email the sugar-devel mailing list for questions
about sugar development.

Regards,

Tomeu

> Our stuff (in English, Dari and Pashto) will go up on olpc.af and as a
> collection...
>
> Thanks,
>
> -Mike
>
> PS:
> I have to hang my head in shame that I have not yet done much Python /
> XO activity coding (yet) - I've done more Java/J2EE and Linux server
> admin thus far.  I will take time over the "weekend"...
>
> 2009/1/13 Sameer Verma <sverma at sfsu.edu>:
>> On Mon, Jan 12, 2009 at 2:15 AM, S Page <info at skierpage.com> wrote:
>>> Carlos Nazareno wrote:
>>>
>>>> - I'd also like to see more work done on a method to easily bundle
>>>> Gnash or HTML-based/Browser applications as stand-alone activities, or
>>>> at least launch the browser with the wrapped activity loaded upon
>>>> startup.
>>>
>>> See the Help activity in 8.2.0, it instantiates the WebView from hulahop
>>> that underlies Browse and points it at help/XO_Introduction.html.
>>>
>>> But is it so bad to make your "HTML-based application" an installable
>>> collection that shows up in the "OLPC Library" navigation on the Browse
>>> home page?  See <http://wiki.laptop.org/go/Creating_a_collection>.  Just
>>> because most library content is static non-interactive ebook material is
>>> no reason really cool browser apps shouldn't go in the OLPC Library.
>>>
>>> One thing that might make collections more appealing and feel like
>>> applications is if the collection's library.info icon (which seems
>>> otherwise unused?!) or the web site's favicon would appear in the
>>> Journal instead or as well as the generic globe icon of Browse.  I filed
>>> a confused ticket #9188 for this enhancement.
>>>
>>>> - Using a local daemon or service of some sort, the method I
>>>> previously outlined can also be used here for "standalone" mode of the
>>>> tests. This way, the learner can also practice with them and learn
>>>> outside of class hours.
>>>
>>> The WikiBrowse activity (WikipediaEN.activity on G1G1 8.2 laptops)
>>> starts a local python Web server and fires up a WebActivity (Browse)
>>> instance pointing at it.
>>>
>>> Better, Browse's engine is XULRunner 1.9 and it has support for most of
>>> the HTML 5 offline application spec
>>> <http://www.w3.org/TR/2008/WD-html5-20080122/#offline>.
>>> E.g. http://starkravingfinkle.org/projects/offline/todo.html is an
>>> expanding form you can fill out while offline that will update the web
>>> server when next online.  It should work on an XO (I can't try it, my
>>> wireless router is bust! :-( ).
>>>
>>> I concur with where you're going.  *Never* ever bet against the browser.
>>>  Browse or a custom WebView activity can do everything that Firefox 3
>>> can do, without worrying about compatibility with abysmal MS Internet
>>> Explorer that's keeping the web stuck in 2004.
>>> E.g. http://wiki.laptop.org/go/FindTheCountry -- why bother with crappy
>>> static PDF atlases when interactive technology like that is available?
>>> And you can View > Source it!
>>>
>>
>> This is one of the coolest things I've seen in a long time!!! This is
>> definitely going down in the SVG examples section for my class in
>> Spring.
>>
>> Sameer
>> --
>> Dr. Sameer Verma, Ph.D.
>> Associate Professor of Information Systems
>> San Francisco State University
>> San Francisco CA 94132 USA
>> http://verma.sfsu.edu/
>> http://opensource.sfsu.edu/
>> _______________________________________________
>> Devel mailing list
>> Devel at lists.laptop.org
>> http://lists.laptop.org/listinfo/devel
>>
> _______________________________________________
> Devel mailing list
> Devel at lists.laptop.org
> http://lists.laptop.org/listinfo/devel
>



More information about the Devel mailing list