maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   Tear 0.3 - Simple WebKit browser, now with Dashboard (https://talk.maemo.org/showthread.php?t=26475)

daperl 2009-03-01 20:55

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by Bundyo (Post 260336)
  • Popup menu changed to use the internal WebKit one. Since it is an ugly hack it doesn't detect links and images under the cursor. Works better for selections and input elements

I haven't looked at your latest code yet, but here's a Python right-button-click solution that you should translate 'cause links and images are detected:
Code:

class BrowserPage(webkit.WebView):
    def __init__(self, ...
        ...
        self.connect("button-press-event", self.on_button_press)
        ...
        try:
            self.connect("tap-and-hold", self.on_tap_and_hold)
            self.tap_and_hold_setup(None, None, 0)
        except:
            self.maemo = False
        ...
    ...
    def on_button_press(self, view, event):
        self._event = event.copy()
        ...
    ...
    def on_tap_and_hold(self, menu, widget=None, data=None):
        self.menudown = True
        self._event.button = 3
        gtk.main_do_event(self._event)


bunanson 2009-03-01 22:27

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
WebKitGTK+ 1.1.1 is out today, http://blogs.gnome.org/xan/2009/03/01/webkitgtk-111/! Are we looking for some new tear very soon? Thanks again to Bundyo and the tear project contributors.

======================================
WebKitGTK+ 1.1.1

March 1, 2009 5:26 pm xan General
...What’s new in WebKitGTK+ 1.1.1?

- ABI compatibility with 1.0.3 was broken, so you will need to
recompile your application against 1.1.1
- Support for the CURL backend was dropped, libsoup is the only HTTP
backend now.
- webkit_get_default_session, to get the SoupSession used internally
by WebKit.
- ‘create-web-view’ signal, emitted when the creation of a new
window is requested.
- ‘navigation-policy-decision-requested’ signal, emitted when a
navigation to another page is requested.
- ‘mime-type-policy-decision-requested’ signal, emitted each time
WebKit is about to show a URI with a given MIME type.
- Support for the Web Inspector
(see http://webkit.org/blog/197/web-inspector-redesign/)
- HTTP authentication support, with optional gnome-keyring storage.
- New load functions: webkit_web_view_open, webkit_web_view_load_uri
and webkit_web_view_load_request. The old
webkit_web_view_load_string and webkit_web_view_load_html_string
are now deprecated.
- webkit_web_view_reload_bypass_cache
- webkit_web_view_{get,set}_custom_encoding, to override the
encoding of the current page.
- Improved stability and lots of bugfixes.
================================================== ==========
bun

Bundyo 2009-03-02 00:11

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by bongo (Post 268116)
I think for you and Bundyo it's time to implement folders :)

Yeah, that's what path is for :)

Bundyo 2009-03-02 00:13

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by daperl (Post 268123)
I haven't looked at your latest code yet, but here's a Python right-button-click solution that you should translate 'cause links and images are detected:
Code:

class BrowserPage(webkit.WebView):
    def __init__(self, ...
        ...
        self.connect("button-press-event", self.on_button_press)
        ...
        try:
            self.connect("tap-and-hold", self.on_tap_and_hold)
            self.tap_and_hold_setup(None, None, 0)
        except:
            self.maemo = False
        ...
    ...
    def on_button_press(self, view, event):
        self._event = event.copy()
        ...
    ...
    def on_tap_and_hold(self, menu, widget=None, data=None):
        self.menudown = True
        self._event.button = 3
        gtk.main_do_event(self._event)


That should do quite nicely i think :) No need for the hack too.

Bundyo 2009-03-02 00:18

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by bunanson (Post 268139)
- Support for the CURL backend was dropped, libsoup is the only HTTP backend now.

That actually is my problem. They did it not even a week ago and Maemo 4 doesn't have support for libsoup 2.4 which is required. Everything else is already taken into account and some things are used. SVN41128 is only some days away from 1.1.1 anyway so it should do until I port libsoup and convert a number of things to use it instead of CURL.

bongo 2009-03-02 07:23

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by Bundyo (Post 268161)
Yeah, that's what path is for :)

He He, I know. ;)

What I thought about is to support a folder element in your database. Something like "bookmark_folder" and not just "bookmark" because it should be possible to create empty folders.

Bundyo 2009-03-02 08:47

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Oh, okay, didn't thought of that :) bookmark_folder is okay I think.

fms 2009-03-02 10:02

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Hello, Bundyo!

I have found an interesting problem with Tear. It looks like under certain circumstances, the SPACE key on the virtual keyboard stops working. So far, I have not found the exact preconditions for that, but here is how it happened:

1. Opened virtual keyboard while trying to write a response in the forum at n8xx.com.
2. Typed something using Roman letters (EN), SPACE works so far.
3. Switched to Cyrillics (RU) and tried typing, SPACE no longer works.
4. Switched back to EN, but SPACE still does not work.

Is this something you encountered before? Any way to fix it?

Bundyo 2009-03-02 12:59

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
I think I encountered it once but wasn't able to reproduce it later. The only way to fix it was to restart Tear. Cyrillic wasn't involved though.

qole 2009-03-02 18:50

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by fms (Post 268228)
It looks like under certain circumstances, the SPACE key on the virtual keyboard stops working.

I have also had this problem.

Quote:

Originally Posted by qole (Post 266575)
I was having issues with N800 OSK too. Spacebar was non-functional.

My locale is en_GB and I have standard qwerty (virtual) keyboard.

Interestingly, I had the same problem when trying to get Hildon Input Method working in my Debian chroot. The new Mer implementation of H-I-M works much better.

Old Debian H-I-M screenshot:

http://farm4.static.flickr.com/3115/...865db92390.jpg

bongo 2009-03-02 18:53

Bookmark Manager
 
1 Attachment(s)
This is just a tiny update. Now you'll get a osso notification when tear ich launched. I've prepared some internal things so folder support is near ;)

I've included a little proof-of-concept:
The archive contains an app called tear-bookmarks-webui.py.

- run as root: 'python tear-bookmarks-webui.py'
- visit http://localhost (or http://YOUR_TABLETS_IP) with your browser

You'll get a list of your Tear bookmarks. My plan is to extend this to a complete ui for the bookmark manager.

Why I'm doing this?
- you can use it as a dashboard replacement
- you can use/manage your Tear bookmarks from your desktop computer

bongo

tso 2009-03-02 18:57

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
to "bad" the only way to go to start page so far is to basically open a new window...

as for that keyboard thing, i think i had something similar happen at one point. dont recall the specifics tho.

oh, and selecting text in a input area is troublesome...

Bundyo 2009-03-02 19:38

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by tso (Post 268354)
to "bad" the only way to go to start page so far is to basically open a new window..

Hmm, this annoy me as well for some time, I'm just wondering where to put it, maybe last item in tap and hold backward list.

tso 2009-03-02 19:49

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
or maybe somewhere on the bookmark list?

thats where its found in the default browser at least ;)

fms 2009-03-02 20:00

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by Bundyo (Post 268243)
I think I encountered it once but wasn't able to reproduce it later. The only way to fix it was to restart Tear. Cyrillic wasn't involved though.

I am able to recreate it with 100% reliability. My guess is that any language change will do the trick.

qole 2009-03-02 20:01

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Maybe if there is a mismatch in locale info between the app and the keyboard?

tso 2009-03-02 20:13

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
well then i should really see it as im running the time and stuff as norwegian, gui language as english, and have been swapping between english and norwegian keyboard a lot (easier to type paths with the english one, no shift needed for forward slash).

Bundyo 2009-03-02 20:43

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
I'm also often swapping between english and bulgarian phonetic.

TrueJournals 2009-03-02 23:06

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by tso (Post 268354)
to "bad" the only way to go to start page so far is to basically open a new window...

Typing about:blank into the address bar doesn't work for you?

Bundyo 2009-03-02 23:10

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Managed to get my eeepc scratchbox updated and running and posted a quick update, see the first post.

tso 2009-03-03 00:46

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by TrueJournals (Post 268431)
Typing about:blank into the address bar doesn't work for you?

it does, its just somewhat bothersome.

thanks tho, you made me think that it may be bookmarked ;)
(oops, should have checked first post earlier...)

btw, using the small osk seems to produce a good deal of double letters lately...

tso 2009-03-03 01:03

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
is there a way to make the menu open towards the center of the acreen? rot now it seems to allways drop down, and gets badly shrunk if it hts the lower edge...

ouch, creating a about:blank bookmark was a very bad idea!

1. it leads to a google search
2. dashboard now shows up empty

interesting, problem 1 goes away after restarting tear...

tso 2009-03-03 01:35

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
two new issues...

1. scrollbars in text areas do not stretch the full edge of a area...

2. while the options for scripts, plugins and images are shared between windows, at least the images setting is silently ignored by all other windows then the one where it was changed...

daperl 2009-03-03 05:21

Re: Tear 0.3 - A WebKit-based browser, now with Dashboard
 
Quote:

Originally Posted by tso (Post 268455)
is there a way to make the menu open towards the center of the acreen? rot now it seems to allways drop down, and gets badly shrunk if it hts the lower edge...

I found the following comment in the r41242 webkit version of
WebKit/gtk/webkit/webkitwebview.cpp in the popup menu handler:
Code:

    // FIXME: The IntSize(0, -1) is a hack to get the hit-testing to result in the selected element.
    // Ideally we'd have the position of a context menu event be separate from its target node.

I'm looking into fooling it as-is (30 more minutes max :rolleyes:), but Bundyo could probably just patch webkit with most of his old placement code. This person probably punted because it's a little tricky if you're in a hurry. Let's face it, having scrolling, roving popup menus on a small screen is a high-class problem! Maybe Nokia has shared some of their tight-to-the-chest browser code in the latest SDK. :) But I bet there's something in the Android stuff. Anyway, I think these are the obvious main issues; their order is my best-guess as to their priority:
  1. No menu item can be underneath the tap point
  2. Neither the right or left edge can be off-screen because the menu only scrolls up and down
  3. vertical_menu_exposure = vertical_menu_exposure_max with A and B still true
  4. The menu's distance from the tap point is the minimum with A and B still true and C at max
  5. And I think the menu has to grab the input focus, especially if the current tap point is not on the menu frame
And since things seem to be picking up, let's be optimistic and remove "Simple" from our comment titles. But knowing where I want to go with this I might have to start using clichés such as "Kitchen Sink" or "Swiss Army Knife" or "Left Nut."

tso 2009-03-03 06:52

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
just noticed that if i try to use any of the scroll arrows of that code area, the page takes of scrolling when i release screen pressure...

daperl 2009-03-03 09:20

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by tso (Post 268516)
just noticed that if i try to use any of the scroll arrows of that code area, the page takes of scrolling when i release screen pressure...

You don't like that feature? :) Yeah, seems as if the main_frame is handling child_frame button events. Makes sense; they're most likely being passed up. Damn, great catch.

@Bundyo, I think when scrolling you need to check the webview handlers for:

Code:

ev.window == wv.get_main_frame()
or maybe:

Code:

ev.window == wv.get_main_frame().window
Not really sure. They might be equivalent.

EDIT: No, the above is inaccurate. It only seems to have to do with auto_scrolling. Under non-auto_scrolling conditions (click-drag-pause/stop-release) everything seems fine.

bongo 2009-03-03 22:01

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
2 Attachment(s)
There's something wrong ...
You know the itt frontpage? Now look at these shots.. Different and wrong layout every time i call this page :confused:
There were no problems with 0.3-4

bongo 2009-03-03 22:17

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
It makes me crazy. The problem disappeared after I made my last post with microb :D
(No, I don't think it has anything to do microb ;) )
I'll observe this ...

Bundyo 2009-03-03 22:21

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
No, I've seen this before and couldn't reproduce it later. Not that I'm going much to the front page these days. :)

...On a side note, maybe one of the banners there is missing some closing tag or something. That can explain why it isn't always reproducible.

munky261 2009-03-04 01:04

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Love it! Look forward to the finished product with ad-blocker. Is there any way you can implement letting people organize their bookmarks in what ever order they want?

Laughing Man 2009-03-04 06:05

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
If I want to run Preview 5, can I still just follow nobodysbusiness's instructions but use the .deb for preview 5? Or do I have to install everything you linked in the first page for preview 5?

Edit: Figured it out myself, just installed what he said through command line, then just the regular not the developer version of webkit along with the tear.deb.

And WOW it's fast.

bongo 2009-03-04 07:42

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by munky261 (Post 268752)
Love it! Look forward to the finished product with ad-blocker. Is there any way you can implement letting people organize their bookmarks in what ever order they want?

I'm working on it. See my previous posts in this thread for more info.
Please wait 2 or 3 weeks as changing order/sorting is a low priority task ;)

bongo 2009-03-04 07:55

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Hi, All links in this forum which open a popup menu stopped working. Click on a user name or on search to reproduce) - using preview 5.1, worked with 4

Un27Pee 2009-03-04 08:06

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by bongo (Post 268826)
Hi, All links in this forum which open a popup menu stopped working. Click on a user name or on search to reproduce) - using preview 5.1, worked with 4

my pop ups are working here tapped your username and it works, 5.1

bongo 2009-03-04 08:20

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
2 Attachment(s)
Strange ...
Nothing happens when I tap your name. When I tap on search the popup appears on a wrong position and I havve to scroll down to see it. Maybe something similar happens to other popups.

EDIT:

I "found" the popup. Look at the scrollbar position :rolleyes:

Un27Pee 2009-03-04 09:13

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
2 Attachment(s)
Still working here just verified, what app do you use for the screenshots will try to post one.

munky261 2009-03-04 09:38

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Hell, theres problems with the menus like that on ITT with microb still.

bongo 2009-03-04 09:56

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by Un27Pee (Post 268843)
Still working here just verified, what app do you use for the screenshots will try to post one.

I used the load-applet statusbar plugin.

daperl 2009-03-04 15:25

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by Un27Pee (Post 268828)
my pop ups are working here tapped your username and it works, 5.1

Do you know what version of webkit you're using? If so, what version?

bongo 2009-03-04 15:40

Re: Tear 0.3 - Simple WebKit browser, now with Dashboard
 
Quote:

Originally Posted by Un27Pee (Post 268843)
Still working here just verified, what app do you use for the screenshots will try to post one.

You use the minimalistic forum view. It has no popups ;)


All times are GMT. The time now is 13:07.

vBulletin® Version 3.8.8