Bug 14619 - [gdk] Make ScrollView handle static backgrounds
Summary: [gdk] Make ScrollView handle static backgrounds
Status: RESOLVED WONTFIX
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 523.x (Safari 3)
Hardware: Mac OS X 10.4
: P2 Normal
Assignee: Nobody
URL:
Keywords: Gtk
Depends on:
Blocks:
 
Reported: 2007-07-14 11:58 PDT by Holger Freyther
Modified: 2007-07-30 12:43 PDT (History)
0 users

See Also:


Attachments
Fix static backgrounds (46.86 KB, patch)
2007-07-14 11:59 PDT, Holger Freyther
zecke: review-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Holger Freyther 2007-07-14 11:58:22 PDT
Currently static backgrounds are not handled and lead to ugly drawing. This patch is going to fix it by forking GtkLayout. Forking was one of three strategies tried and is IMHO the best.
Comment 1 Holger Freyther 2007-07-14 11:59:13 PDT
Created attachment 15517 [details]
Fix static backgrounds
Comment 2 Maciej Stachowiak 2007-07-16 00:00:52 PDT
Is copying this big hunk of Gtk code really the only way to do this? Maybe it would work to just connect "value_changed" signal handlers from outside the class? Or maybe we can subclass GtkLayout? Cut & pasting the whole thing seems like a pretty extreme approach.
Comment 3 Holger Freyther 2007-07-16 00:54:08 PDT
The are two changes to GtkLayout where I think only one is important. Before calling gdk_window_move we need to unmap the GtkWidget and afterwards map it again. The method/closure connected to the value_changed signal of adjustments is private, so subclassing is not possible.

The approaches I saw where:
    -I don't know if it is possible but disconnect the gtk_layout_value_changed closure and implement this inside webkit. The downside was that the secret of moving the window is shared between Gtk+ and WebKit and I assumed this will be error prone.
     -One could try to connect the value_changed signal twice. The first closure would unmap the GtkWidget in case of static backgrounds and the other one would map it again. I was not certain if I can gurantee to always be called before the GtkLayout closure.

I think one shouldn't share secrets and I'm not certain the second approach will work, this is why I decided to copy/fork GtkLayout. I need some clarification regarding Frame, FrameView and FrameTree interaction so we might end up with a completely different approach (will send an email).
Comment 4 Holger Freyther 2007-07-16 10:31:20 PDT
Comment on attachment 15517 [details]
Fix static backgrounds

We will move away from GtkLayout, including a forked copy of it doesn't make sense.
Comment 5 Holger Freyther 2007-07-23 13:14:34 PDT
Add the Gtk keyword, even to the curl bugs.
Comment 6 Holger Freyther 2007-07-30 12:43:29 PDT
#14729 has a ScrollView 'rewrite' fixing this issue as well.