Changeset 135672 in webkit


Ignore:
Timestamp:
Nov 25, 2012, 11:06:22 AM (13 years ago)
Author:
zhajiang@rim.com
Message:

[BlackBerry] Get rid of resetBitmapZoomScale()
https://bugs.webkit.org/show_bug.cgi?id=103200

Patch by Jacky Jiang <zhajiang@rim.com>.
Reviewed by Rob Buis.
Internally reviewed by Gen Mak.

PR: 235707
Right now, resetBitmapZoomScale() takes an unused paramter and
dispatches a message to end the bitmap zooming. However, the
interaction has its own state machine to start bitmap zooming when it
is active and end bitmap zooming when it is inactive. This is
expecially for pinch zoom and scroll. From WebKit side, block zoom
which will call zoomBlock when the bitmap zoom finished doesn't even
need to dispatch the useless ending message to ZoomHandler.
resetBitmapZoomScale() is basically a noop for block zoom. And likewise
that is useless for zoomToInitialScaleOnLoad(). It can also potentially
cause problem if it is used somewhere else in the future and
incidentally breaks the interaction's own state machine. So just remove
this completely.

  • Api/WebPage.cpp:

(BlackBerry::WebKit::WebPagePrivate::zoomToInitialScaleOnLoad):
(BlackBerry::WebKit::WebPagePrivate::zoomBlock):

  • Api/WebPageClient.h:
Location:
trunk/Source/WebKit/blackberry
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/blackberry/Api/WebPage.cpp

    r135615 r135672  
    16371637#endif
    16381638        requestLayoutIfNeeded();
    1639         m_client->resetBitmapZoomScale(currentScale());
    16401639        notifyTransformedContentsSizeChanged();
    16411640        return;
     
    16681667        // We only notify if we didn't perform zoom, because zoom will notify on
    16691668        // its own...
    1670         m_client->resetBitmapZoomScale(currentScale());
    16711669        notifyTransformedContentsSizeChanged();
    16721670    }
     
    29602958    zoom.scale(m_blockZoomFinalScale);
    29612959    *m_transformationMatrix = zoom;
    2962     m_client->resetBitmapZoomScale(m_blockZoomFinalScale);
    29632960    // FIXME: Do we really need to suspend/resume both backingstore and screen here?
    29642961    m_backingStore->d->suspendBackingStoreUpdates();
  • trunk/Source/WebKit/blackberry/Api/WebPageClient.h

    r135639 r135672  
    202202    virtual BlackBerry::Platform::ViewportAccessor* userInterfaceViewportAccessor() const = 0;
    203203
    204     virtual void resetBitmapZoomScale(double scale) = 0;
    205204    virtual void animateBlockZoom(double finalScale, const Platform::FloatPoint& finalDocumentScrollPosition) = 0;
    206205
  • trunk/Source/WebKit/blackberry/ChangeLog

    r135664 r135672  
     12012-11-25  Jacky Jiang  <zhajiang@rim.com>
     2
     3        [BlackBerry] Get rid of resetBitmapZoomScale()
     4        https://bugs.webkit.org/show_bug.cgi?id=103200
     5
     6        Reviewed by Rob Buis.
     7        Internally reviewed by Gen Mak.
     8
     9        PR: 235707
     10        Right now, resetBitmapZoomScale() takes an unused paramter and
     11        dispatches a message to end the bitmap zooming. However, the
     12        interaction has its own state machine to start bitmap zooming when it
     13        is active and end bitmap zooming when it is inactive. This is
     14        expecially for pinch zoom and scroll. From WebKit side, block zoom
     15        which will call zoomBlock when the bitmap zoom finished doesn't even
     16        need to dispatch the useless ending message to ZoomHandler.
     17        resetBitmapZoomScale() is basically a noop for block zoom. And likewise
     18        that is useless for zoomToInitialScaleOnLoad(). It can also potentially
     19        cause problem if it is used somewhere else in the future and
     20        incidentally breaks the interaction's own state machine. So just remove
     21        this completely.
     22
     23        * Api/WebPage.cpp:
     24        (BlackBerry::WebKit::WebPagePrivate::zoomToInitialScaleOnLoad):
     25        (BlackBerry::WebKit::WebPagePrivate::zoomBlock):
     26        * Api/WebPageClient.h:
     27
    1282012-11-24  Andy Chen  <andchen@rim.com>
    229
Note: See TracChangeset for help on using the changeset viewer.