[IAEP] Tech roadmap

Gonzalo Odiard gonzalo at laptop.org
Wed Nov 6 18:37:02 EST 2013


In F18 we can do:
  from gi.repository import WebKit2

but later crash, not sure where.

Gonzalo



On Wed, Nov 6, 2013 at 8:20 PM, Daniel Narvaez <dwnarvaez at gmail.com> wrote:

> On 6 November 2013 18:32, Gonzalo Odiard <gonzalo at laptop.org> wrote:
>
>> >> No. the web-server issue is already solved.
>> >
>> > If we want to support WebKit1, I think we should do it upstream then.
>> I'm
>> > still not thrilled about that but not opposed to it either.
>>
>> Good. We can see what is the better way to do it. May be check the
>> webkit version installed?
>>
>> Just for reference, the changes we did are here:
>>
>>
>> https://github.com/godiard/au1b_rpms/blob/master/sugar-toolkit-gtk3/0001-Adapt-webactivity-to-work-with-webkit1.patch
>>
>
> I think the best way to detect it would be to import WebKit2, if it fails
> fall back to WebKit.
>
> I'm not sure what's the best way to maintain the two different
> implementations though. Maybe two modules with identical interfaces,
> imported "as webview".
>
> So something like this in webactivity.py:
>
> try:
>   from gi.repository import WebKit2
> except ImportError:
>   pass
>
> if WebKit2:
>   from sugar.activity import webkit1view as webview
> else:
>   from sugar.activity import webkit2view as webview
>
> class WebActivity:
>   def __init__(self):
>     self._web_view = webview.WebView()
> ...
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sugarlabs.org/archive/iaep/attachments/20131106/fb03bbd4/attachment.html>


More information about the IAEP mailing list