RESOLVED FIXED 56216
Rework IconDatabase disabling while allowing for a "pluggable" icon database
https://bugs.webkit.org/show_bug.cgi?id=56216
Summary Rework IconDatabase disabling while allowing for a "pluggable" icon database
Brady Eidson
Reported 2011-03-11 12:58:28 PST
Rework IconDatabase disabling while allowing for a "pluggable" icon database. For WebKit2, we'll want to plug-in a different IconDatabase for both WebCore and WK2 to use. For WebKit1 mac/win, we want the current WebCore IconDatabase to keep working as it does now. And for ports who disable the IconDatabase, we want that to keep working. By making a virtual base "IconDatabaseBase" class for anyone to inherit from, we can accomplish all of the above: -The "DISABLE(IconDatabase)" folks will just get IconDatabaseBase as a no-op implementation. -The current WebCore IconDatabase users will get the current IconDatabase code, now inheriting from IconDatabaseBase -WK2 can make its own IconDatabaseBase subclass and assign it as the current IconDatabase. That will be in a different bug. Patch for the above refactoring is on its way.
Attachments
Patch v1 (28.77 KB, patch)
2011-03-11 13:04 PST, Brady Eidson
sam: review+
Patch v2 - Left out the WebKit pieces (34.53 KB, patch)
2011-03-11 15:14 PST, Brady Eidson
andersca: review+
Brady Eidson
Comment 1 2011-03-11 13:04:44 PST
Created attachment 85514 [details] Patch v1
Brady Eidson
Comment 2 2011-03-11 13:05:13 PST
Sam Weinig
Comment 3 2011-03-11 13:10:05 PST
Comment on attachment 85514 [details] Patch v1 View in context: https://bugs.webkit.org/attachment.cgi?id=85514&action=review > Source/WebCore/loader/icon/IconDatabaseBase.cpp:58 > +} //namespace WebCore Missing space. > Source/WebCore/loader/icon/IconDatabaseBase.h:87 > +}; // class IconDatabaseBase We don't put these // class comments usually.
Brady Eidson
Comment 4 2011-03-11 15:14:30 PST
Created attachment 85546 [details] Patch v2 - Left out the WebKit pieces
WebKit Review Bot
Comment 5 2011-03-11 15:17:21 PST
Attachment 85546 [details] did not pass style-queue: Failed to run "['Tools/Scripts/check-webkit-style', '--diff-files', u'Source/WebCore/Android.mk', u'Source/WebCo..." exit_code: 1 Source/WebCore/loader/icon/IconDatabase.h:61: Should only a single space after a punctuation in a comment. [whitespace/comments] [5] Source/WebCore/loader/icon/IconDatabase.h:93: The parameter name "enabled" adds no information, so it should be removed. [readability/parameter_name] [5] Total errors found: 2 in 14 files If any of these errors are false positives, please file a bug against check-webkit-style.
Brady Eidson
Comment 6 2011-03-11 16:17:59 PST
Landed in r80900
Build Bot
Comment 7 2011-03-11 16:25:37 PST
Brady Eidson
Comment 8 2011-03-11 16:29:38 PST
Windows build fix in 80902
WebKit Review Bot
Comment 9 2011-03-11 16:30:08 PST
http://trac.webkit.org/changeset/80900 might have broken Qt Linux Release minimal, Qt Linux ARMv7 Release, Qt Windows 32-bit Release, and Qt Windows 32-bit Debug
Brady Eidson
Comment 10 2011-03-11 16:45:31 PST
Hopefully fixed Qt in r80905
Brady Eidson
Comment 12 2011-03-11 17:24:22 PST
Reasonably confident fix for Windows in r80908 Complete shot in the dark fix for Qt in r80909
Ryosuke Niwa
Comment 13 2011-03-11 17:31:41 PST
(In reply to comment #12) > Reasonably confident fix for Windows in r80908 > > Complete shot in the dark fix for Qt in r80909 Still broken :( At this point, I'd really like you to consider rolling it out for now and re-land it later after verifying that your patch builds on all platforms.
Brady Eidson
Comment 14 2011-03-11 17:33:58 PST
(In reply to comment #13) > (In reply to comment #12) > > Reasonably confident fix for Windows in r80908 > > > > Complete shot in the dark fix for Qt in r80909 > > Still broken :( At this point, I'd really like you to consider rolling it out for now and re-land it later after verifying that your patch builds on all platforms. Since I'm here and actively trying to fix this, perhaps it would help us both if you could help track down what Qt is complaining about?
Brady Eidson
Comment 15 2011-03-11 17:34:52 PST
Ah figured out why my last attempt didn't take. Let's go again...
Ryosuke Niwa
Comment 16 2011-03-11 17:35:31 PST
(In reply to comment #14) > Since I'm here and actively trying to fix this, perhaps it would help us both if you could help track down what Qt is complaining about? It seems like Qt's WebSettings access it: ../../../../Source/WebCore/loader/icon/IconDatabase.h: In static member function 'static void QWebSettings::setIconDatabasePath(const QString&)': ../../../../Source/WebCore/loader/icon/IconDatabase.h:63:17: error: 'static void WebCore::IconDatabase::delayDatabaseCleanup()' is private ../../../../Source/WebKit/qt/Api/qwebsettings.cpp:648:49: error: within this context
Brady Eidson
Comment 17 2011-03-11 17:36:49 PST
Ryosuke Niwa
Comment 18 2011-03-11 17:37:31 PST
It seems like the current Windows build failure is due to http://trac.webkit.org/changeset/80899.
Brady Eidson
Comment 19 2011-03-11 17:38:41 PST
(In reply to comment #16) > (In reply to comment #14) > > Since I'm here and actively trying to fix this, perhaps it would help us both if you could help track down what Qt is complaining about? > > It seems like Qt's WebSettings access it: > > ../../../../Source/WebCore/loader/icon/IconDatabase.h: In static member function 'static void QWebSettings::setIconDatabasePath(const QString&)': > ../../../../Source/WebCore/loader/icon/IconDatabase.h:63:17: error: 'static void WebCore::IconDatabase::delayDatabaseCleanup()' is private > ../../../../Source/WebKit/qt/Api/qwebsettings.cpp:648:49: error: within this context Yah, I added that in my 2nd to last build fix, but forgot to make it public. I did in my last build fix. I was pretty sure this whole time - until landing the initial patch - that Qt didn't use the icon database. Therefore I was surprised they provided any form of support for it in its API layer. Sorry for all the troubles - I'm going to keep an eye on it and make sure this one takes.
Ryosuke Niwa
Comment 20 2011-03-11 17:40:41 PST
(In reply to comment #19) > Yah, I added that in my 2nd to last build fix, but forgot to make it public. I did in my last build fix. > I was pretty sure this whole time - until landing the initial patch - that Qt didn't use the icon database. > Therefore I was surprised they provided any form of support for it in its API layer. > Sorry for all the troubles - I'm going to keep an eye on it and make sure this one takes. No problem! Thanks for the timely build fixes.
Note You need to log in before you can comment on or make changes to this bug.