WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
103679
[EFL][WK2] MiniBrowser should have a legacy mode
https://bugs.webkit.org/show_bug.cgi?id=103679
Summary
[EFL][WK2] MiniBrowser should have a legacy mode
Yael
Reported
2012-11-29 15:37:56 PST
It is very useful to start MiniBrowser in Legacy mode. e.g. to compare how a test looks in MiniBrowser to the pixel tests results.
Attachments
Patch
(7.90 KB, patch)
2012-11-29 17:44 PST
,
Yael
no flags
Details
Formatted Diff
Diff
Patch
(4.11 KB, patch)
2012-11-30 07:13 PST
,
Yael
no flags
Details
Formatted Diff
Diff
Patch
(4.46 KB, patch)
2012-11-30 08:05 PST
,
Yael
no flags
Details
Formatted Diff
Diff
Show Obsolete
(2)
View All
Add attachment
proposed patch, testcase, etc.
Yael
Comment 1
2012-11-29 17:44:50 PST
Created
attachment 176865
[details]
Patch The new API name was suggested in
https://bugs.webkit.org/show_bug.cgi?id=100674#c47
Kenneth Rohde Christiansen
Comment 2
2012-11-30 00:54:12 PST
Comment on
attachment 176865
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=176865&action=review
> Source/WebKit2/UIProcess/API/efl/ewk_context.cpp:213 > +void EwkContext::setViewBehavior(Ewk_View_Behavior behavior) > +{ > + m_behavior = behavior; > +} > + > +Ewk_View_Behavior EwkContext::viewBehavior() const > +{ > + return m_behavior; > +}
Do we really want this to be public api? You could also just use a hidden environment variable. Every thing we expose has to be supported
Gyuyoung Kim
Comment 3
2012-11-30 01:02:59 PST
Comment on
attachment 176865
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=176865&action=review
>> Source/WebKit2/UIProcess/API/efl/ewk_context.cpp:213 >> +} > > Do we really want this to be public api? You could also just use a hidden environment variable. > > Every thing we expose has to be supported
I agree with Kenneth. We should avoid to add unneeded APIs.
Yael
Comment 4
2012-11-30 05:26:06 PST
(In reply to
comment #2
)
> (From update of
attachment 176865
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=176865&action=review
> > > Source/WebKit2/UIProcess/API/efl/ewk_context.cpp:213 > > +void EwkContext::setViewBehavior(Ewk_View_Behavior behavior) > > +{ > > + m_behavior = behavior; > > +} > > + > > +Ewk_View_Behavior EwkContext::viewBehavior() const > > +{ > > + return m_behavior; > > +} > > Do we really want this to be public api? You could also just use a hidden environment variable. > > Every thing we expose has to be supported
From
https://bugs.webkit.org/show_bug.cgi?id=100674#c47
I assumed that we do, but this can be done without a new API.
Yael
Comment 5
2012-11-30 07:13:51 PST
Created
attachment 176962
[details]
Patch Removed the new API.
Kenneth Rohde Christiansen
Comment 6
2012-11-30 07:47:41 PST
Comment on
attachment 176962
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=176962&action=review
> Source/WebKit2/ChangeLog:10 > + > + Allow calling WKViewCreate without creating a context first. A default context > + will be used. > +
You should explain what that actually means. How is that related to the legacy mode.
> Tools/MiniBrowser/efl/main.c:1063 > - window->ewk_view = ewk_view_smart_add(evas, smart, ewk_context_default_get()); > + window->ewk_view = legacy_behavior_enabled ? (Evas_Object*)WKViewCreate(evas, 0, 0) : ewk_view_smart_add(evas, smart, ewk_context_default_get());
Why not make this more clean if (legacy_behavior_enabled) { // Use raw WK2 api to create a view using legacy mode. window->ewk_view = (Evas_Object*)WKViewCreate(evas, 0, 0); } else window->ewk_view = ewk_view_smart_add(evas, smart, ewk_context_default_get());
Yael
Comment 7
2012-11-30 07:49:05 PST
(In reply to
comment #6
)
> (From update of
attachment 176962
[details]
) > View in context:
https://bugs.webkit.org/attachment.cgi?id=176962&action=review
> > > Source/WebKit2/ChangeLog:10 > > + > > + Allow calling WKViewCreate without creating a context first. A default context > > + will be used. > > + > > You should explain what that actually means. How is that related to the legacy mode. > > > Tools/MiniBrowser/efl/main.c:1063 > > - window->ewk_view = ewk_view_smart_add(evas, smart, ewk_context_default_get()); > > + window->ewk_view = legacy_behavior_enabled ? (Evas_Object*)WKViewCreate(evas, 0, 0) : ewk_view_smart_add(evas, smart, ewk_context_default_get()); > > Why not make this more clean > > if (legacy_behavior_enabled) { > // Use raw WK2 api to create a view using legacy mode. > window->ewk_view = (Evas_Object*)WKViewCreate(evas, 0, 0); > } else > window->ewk_view = ewk_view_smart_add(evas, smart, ewk_context_default_get());
Because people usually ask me to condense lines as much as possible :)
Kenneth Rohde Christiansen
Comment 8
2012-11-30 07:50:04 PST
> > if (legacy_behavior_enabled) { > > // Use raw WK2 api to create a view using legacy mode. > > window->ewk_view = (Evas_Object*)WKViewCreate(evas, 0, 0); > > } else > > window->ewk_view = ewk_view_smart_add(evas, smart, ewk_context_default_get()); > Because people usually ask me to condense lines as much as possible :)
We are doing something a bit out of the ordinary here, let's make that clear.
Kenneth Rohde Christiansen
Comment 9
2012-11-30 07:51:40 PST
Comment on
attachment 176962
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=176962&action=review
>> Tools/MiniBrowser/efl/main.c:1063 >> + window->ewk_view = legacy_behavior_enabled ? (Evas_Object*)WKViewCreate(evas, 0, 0) : ewk_view_smart_add(evas, smart, ewk_context_default_get()); > > Why not make this more clean > > if (legacy_behavior_enabled) { > // Use raw WK2 api to create a view using legacy mode. > window->ewk_view = (Evas_Object*)WKViewCreate(evas, 0, 0); > } else > window->ewk_view = ewk_view_smart_add(evas, smart, ewk_context_default_get());
As you don't add the smart now, why create it?
Yael
Comment 10
2012-11-30 08:05:14 PST
Created
attachment 176971
[details]
Patch Address Kenneth's comments
WebKit Review Bot
Comment 11
2012-12-02 02:13:41 PST
Comment on
attachment 176971
[details]
Patch Clearing flags on attachment: 176971 Committed
r136320
: <
http://trac.webkit.org/changeset/136320
>
WebKit Review Bot
Comment 12
2012-12-02 02:13:46 PST
All reviewed patches have been landed. Closing bug.
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