<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>105497</bug_id>
          
          <creation_ts>2012-12-19 22:00:04 -0800</creation_ts>
          <short_desc>[EFL][WK2] Optimize zooming and scrolling.</short_desc>
          <delta_ts>2017-03-11 10:49:23 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Layout and Rendering</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>WONTFIX</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          <blocked>103105</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Dongseong Hwang">dongseong.hwang</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>d-r</cc>
    
    <cc>joone</cc>
    
    <cc>kenneth</cc>
    
    <cc>laszlo.gombos</cc>
    
    <cc>mcatanzaro</cc>
    
    <cc>mikhail.pozdnyakov</cc>
    
    <cc>ostap73</cc>
    
    <cc>tonikitoo</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>795186</commentid>
    <comment_count>0</comment_count>
    <who name="Dongseong Hwang">dongseong.hwang</who>
    <bug_when>2012-12-19 22:00:04 -0800</bug_when>
    <thetext>Qt can make fast scrolling and fast zooming. However, efl always make zooming and scrolling when receiving didRenderFrame mesage from Web Process. It makes big UI responsibility latency.
Refer to Bug 78602

In detail, PageViewportControllerClientQt calls movementStarted() and contentXChanged() if needed.

PageViewportControllerClientQt::PageViewportControllerClientQt(QQuickWebView* viewportItem, QQuickWebPage* pageItem)
    ...
{
    ...
    connect(m_viewportItem, SIGNAL(movementStarted()), SLOT(flickMoveStarted()), Qt::DirectConnection);
    connect(m_viewportItem, SIGNAL(movementEnded()), SLOT(flickMoveEnded()), Qt::DirectConnection);
    connect(m_viewportItem, SIGNAL(contentXChanged()), SLOT(pageItemPositionChanged()));
    connect(m_viewportItem, SIGNAL(contentYChanged()), SLOT(pageItemPositionChanged()));


    connect(m_scaleAnimation, SIGNAL(stateChanged(QAbstractAnimation::State, QAbstractAnimation::State)),
            SLOT(scaleAnimationStateChanged(QAbstractAnimation::State, QAbstractAnimation::State)));
}

I does not have enough knowledge of efl UI toolkit framework. It is good if someone fix this bug before I study efl framework :)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>796283</commentid>
    <comment_count>1</comment_count>
    <who name="Kenneth Rohde Christiansen">kenneth</who>
    <bug_when>2012-12-21 06:53:56 -0800</bug_when>
    <thetext>I don&apos;t understand this.

Currently EFL doesn&apos;t have a way to pinch and pan, so you can only scroll by selection text/images or by using the wheel. That then sends scroll requests to the UI side.

Could you explain better?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>797208</commentid>
    <comment_count>2</comment_count>
    <who name="Dongseong Hwang">dongseong.hwang</who>
    <bug_when>2012-12-25 18:14:41 -0800</bug_when>
    <thetext>Currently, when EFL scrolls, EFL needs two message communications: request (UI Process -&gt; Web Process) and response (Web Process -&gt; UI Process).
However, we can speculatively scroll in UI side like Qt.

In detail, EFL runs following process for scrolling.

1. Request scrolling web process to ui process
- UI Process : WebPageProxy::scrollBy()
- Web Process : WebCore computes

2. Response scrolling
- Web Process : notify did scrolling
- UI Process : PageViewportController::pageDidRequestScroll is called.
-- Update scroll position of EwkView and request rendering of EwkView.

void PageViewportControllerClientEfl::setViewportPosition(const WebCore::FloatPoint&amp; contentsPoint)
{
    m_contentPosition = contentsPoint;

    FloatPoint pos(contentsPoint);
    pos.scale(scaleFactor(), scaleFactor());
    m_viewImpl-&gt;setPagePosition(pos);

    m_controller-&gt;didChangeContentsVisibility(m_contentPosition, scaleFactor());
}

However, Qt can scroll in UI side. currently, Qt did when flicking.
When Qt view&apos;s scroll position is changed, flickMoveStarted(), pageItemPositionChanged() and flickMoveEnded() are called.
Three methods update windows with changed scoll position.

void PageViewportControllerClientQt::flickMoveStarted()
{
    m_controller-&gt;suspendContent();

    m_lastScrollPosition = m_viewportItem-&gt;contentPos();

    m_ignoreViewportChanges = false;
}

void PageViewportControllerClientQt::flickMoveEnded()
{
    // This method is called on the end of the pan or pan kinetic animation.

    m_ignoreViewportChanges = true;
    if (!m_isUserInteracting)
        m_controller-&gt;resumeContent();
}

void PageViewportControllerClientQt::pageItemPositionChanged()
{
    if (m_ignoreViewportChanges)
        return;

    QPointF newPosition = m_viewportItem-&gt;contentPos();

    updateViewportController(m_lastScrollPosition - newPosition);

    m_lastScrollPosition = newPosition;
}

I think if efl implemented fast scolling like qt, scrolling latency can be significantly reduced.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>797818</commentid>
    <comment_count>3</comment_count>
    <who name="Kenneth Rohde Christiansen">kenneth</who>
    <bug_when>2012-12-28 01:32:30 -0800</bug_when>
    <thetext>Ah of course we will implement this. Btw, Qt also does the same as us for mouse wheel scrolls. Potentially that could also be done on UI side (with smoothing)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1286716</commentid>
    <comment_count>4</comment_count>
    <who name="Michael Catanzaro">mcatanzaro</who>
    <bug_when>2017-03-11 10:49:23 -0800</bug_when>
    <thetext>Closing this bug because the EFL port has been removed from trunk.

If you feel this bug applies to a different upstream WebKit port and was closed in error, please either update the title and reopen the bug, or leave a comment to request this.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>