Bug 111075 - [WK2][EFL] WebView should own page position and scale factor
Summary: [WK2][EFL] WebView should own page position and scale factor
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit EFL (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Mikhail Pozdnyakov
URL:
Keywords:
Depends on:
Blocks: 107657 107662
  Show dependency treegraph
 
Reported: 2013-02-28 06:38 PST by Mikhail Pozdnyakov
Modified: 2013-04-05 06:15 PDT (History)
6 users (show)

See Also:


Attachments
WIP (8.63 KB, patch)
2013-02-28 07:00 PST, Mikhail Pozdnyakov
no flags Details | Formatted Diff | Diff
WIP 2 (8.97 KB, patch)
2013-03-19 07:57 PDT, Mikhail Pozdnyakov
no flags Details | Formatted Diff | Diff
patch (11.23 KB, patch)
2013-04-05 04:08 PDT, Mikhail Pozdnyakov
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mikhail Pozdnyakov 2013-02-28 06:38:18 PST
SSIA.
Comment 1 Mikhail Pozdnyakov 2013-02-28 07:00:14 PST
Created attachment 190721 [details]
WIP

The code looks better now and EwkView usage is decreased inside WebView. But on the other hand 1) having scale factors both inside view and page is confusing 2) maybe it's better to use "viewport position" than "page position"?
Comment 2 Kenneth Rohde Christiansen 2013-03-03 06:52:40 PST
Comment on attachment 190721 [details]
WIP

View in context: https://bugs.webkit.org/attachment.cgi?id=190721&action=review

> Source/WebKit2/UIProcess/API/C/efl/WKView.cpp:69
> +
> +void WKViewSetScaleFactor(WKViewRef viewRef, float scale)
> +{
> +    toImpl(viewRef)->setScaleFactor(scale);
> +}

Should this be SetPageScaleFactor for consistency?
Comment 3 Mikhail Pozdnyakov 2013-03-05 05:20:26 PST
(In reply to comment #2)
> (From update of attachment 190721 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=190721&action=review
> 
> > Source/WebKit2/UIProcess/API/C/efl/WKView.cpp:69
> > +
> > +void WKViewSetScaleFactor(WKViewRef viewRef, float scale)
> > +{
> > +    toImpl(viewRef)->setScaleFactor(scale);
> > +}
> 
> Should this be SetPageScaleFactor for consistency?

wouldn't it be confusing for the client considering the existing 'void WKPageSetScaleFactor(WKPageRef page, double scale, WKPoint origin);' ?
Comment 4 Mikhail Pozdnyakov 2013-03-19 06:31:52 PDT
(In reply to comment #3)
> (In reply to comment #2)
> > (From update of attachment 190721 [details] [details])
> > View in context: https://bugs.webkit.org/attachment.cgi?id=190721&action=review
> > 
> > > Source/WebKit2/UIProcess/API/C/efl/WKView.cpp:69
> > > +
> > > +void WKViewSetScaleFactor(WKViewRef viewRef, float scale)
> > > +{
> > > +    toImpl(viewRef)->setScaleFactor(scale);
> > > +}
> > 
> > Should this be SetPageScaleFactor for consistency?
> 
> wouldn't it be confusing for the client considering the existing 'void WKPageSetScaleFactor(WKPageRef page, double scale, WKPoint origin);' ?

Having IRC discussion with Kenneth came to conclusion that WKViewSetContentScaleFactor would be most appropriate name for it.
Comment 5 Mikhail Pozdnyakov 2013-03-19 07:57:19 PDT
Created attachment 193830 [details]
WIP 2
Comment 6 Kenneth Rohde Christiansen 2013-03-19 08:09:59 PDT
Comment on attachment 193830 [details]
WIP 2

LGTM, but a good changelog explaining the difference between WKPageSetScaleFactor etc would be needed. Also explaining that these are in UI units
Comment 7 Mikhail Pozdnyakov 2013-04-05 04:08:50 PDT
Created attachment 196615 [details]
patch

Rebased. Added change log.
Comment 8 WebKit Commit Bot 2013-04-05 06:15:39 PDT
Comment on attachment 196615 [details]
patch

Clearing flags on attachment: 196615

Committed r147741: <http://trac.webkit.org/changeset/147741>
Comment 9 WebKit Commit Bot 2013-04-05 06:15:42 PDT
All reviewed patches have been landed.  Closing bug.