WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
131121
Remove code duplications when initializing InspectorServer (EFL and GTK)
https://bugs.webkit.org/show_bug.cgi?id=131121
Summary
Remove code duplications when initializing InspectorServer (EFL and GTK)
Laszlo Vidacs
Reported
2014-04-02 13:22:52 PDT
WebContextEfl.cpp and WebContextGTK.cpp contains similar static functions to initialize InspectorServer (initializeInspectorServer() vs initInspectorServer()). Create a common method called from both places.
Attachments
Patch
(8.69 KB, patch)
2014-04-02 13:34 PDT
,
Laszlo Vidacs
mcatanzaro
: review+
mcatanzaro
: commit-queue-
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Laszlo Vidacs
Comment 1
2014-04-02 13:34:18 PDT
Created
attachment 228423
[details]
Patch
Michael Catanzaro
Comment 2
2016-01-06 20:02:01 PST
Comment on
attachment 228423
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=228423&action=review
Sorry for the late review. Thanks for this nice cleanup.
> Source/WebKit2/UIProcess/InspectorServer/WebInspectorServer.cpp:41 > +#if PLATFORM(GTK) || PLATFORM(EFL)
This should be #if ENABLE(INSPECTOR_SERVER). INSPECTOR_SERVER is only used by GTK and EFL.
> Source/WebKit2/UIProcess/InspectorServer/WebInspectorServer.h:45 > +#if PLATFORM(GTK) || PLATFORM(EFL)
Ditto.
> Source/WebKit2/UIProcess/InspectorServer/WebInspectorServer.h:69 > + static bool initialized;
You'll want to split this out: #if PLATFORM(GTK) || PLATFORM(EFL) void buildPageList(Vector<char>& data, String& contentType); #endif #if ENABLE(INSPECTOR_SERVER) static bool initialized; #endif The extra #ifdef is messier here, but I think it's better to use the feature-specific rather than platform-specific conditionals where possible.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug