RESOLVED FIXED 99751
PageViewportController::m_rawAttributes.devicePixelRatio is not initialized
https://bugs.webkit.org/show_bug.cgi?id=99751
Summary PageViewportController::m_rawAttributes.devicePixelRatio is not initialized
Yael
Reported 2012-10-18 13:28:01 PDT
PageViewportController::m_rawAttributes.devicePixelRatio is not initialized and can cause the zoom level to become infinity. It seems in qt port it starts with garbage value but in EFL port starts with 0, and then the zoom level is set to infinity in computeMinimumScaleFactorForContentContained . Once minimum scale starts as infinity, it never goes down.
Attachments
Patch (1.72 KB, patch)
2012-10-18 13:37 PDT, Yael
no flags
Yael
Comment 1 2012-10-18 13:37:58 PDT
WebKit Review Bot
Comment 2 2012-10-18 14:20:20 PDT
Comment on attachment 169458 [details] Patch Clearing flags on attachment: 169458 Committed r131802: <http://trac.webkit.org/changeset/131802>
WebKit Review Bot
Comment 3 2012-10-18 14:20:23 PDT
All reviewed patches have been landed. Closing bug.
Kenneth Rohde Christiansen
Comment 4 2012-10-19 01:34:08 PDT
Comment on attachment 169458 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=169458&action=review > Source/WebKit2/UIProcess/PageViewportController.cpp:74 > + m_rawAttributes.devicePixelRatio = 1; ARgh, this device pixel ratio should be removed from here instead and we should use Page::deviceScaleFactor like everyone else
Andras Becsi
Comment 5 2012-10-19 02:08:07 PDT
(In reply to comment #4) > (From update of attachment 169458 [details]) > View in context: https://bugs.webkit.org/attachment.cgi?id=169458&action=review > > > Source/WebKit2/UIProcess/PageViewportController.cpp:74 > > + m_rawAttributes.devicePixelRatio = 1; > > ARgh, this device pixel ratio should be removed from here instead and we should use Page::deviceScaleFactor like everyone else Since the recent refactor, we do not use m_rawAttributes.devicePixelRatio any more, so this patch does not really have an effect. I'll prepare a patch to remove it from the attributes.
Yael
Comment 6 2012-10-19 05:17:25 PDT
(In reply to comment #5) > (In reply to comment #4) > > (From update of attachment 169458 [details] [details]) > > View in context: https://bugs.webkit.org/attachment.cgi?id=169458&action=review > > > > > Source/WebKit2/UIProcess/PageViewportController.cpp:74 > > > + m_rawAttributes.devicePixelRatio = 1; > > > > ARgh, this device pixel ratio should be removed from here instead and we should use Page::deviceScaleFactor like everyone else > > Since the recent refactor, we do not use m_rawAttributes.devicePixelRatio any more, so this patch does not really have an effect. > > I'll prepare a patch to remove it from the attributes. Well, without this patch, I saw a black screen in my version of EFL MIniBrowser, after hooking it up with PageViewController. The reason was that the zoom level was infinity. m_rawAttributes.devicePixelRatio is actually used in computeMinimumScaleFactorForContentContained (ViewportAgruments.cpp)
Andras Becsi
Comment 7 2012-10-19 05:27:51 PDT
(In reply to comment #6) > (In reply to comment #5) > > (In reply to comment #4) > > > (From update of attachment 169458 [details] [details] [details]) > > > View in context: https://bugs.webkit.org/attachment.cgi?id=169458&action=review > > > > > > > Source/WebKit2/UIProcess/PageViewportController.cpp:74 > > > > + m_rawAttributes.devicePixelRatio = 1; > > > > > > ARgh, this device pixel ratio should be removed from here instead and we should use Page::deviceScaleFactor like everyone else > > > > Since the recent refactor, we do not use m_rawAttributes.devicePixelRatio any more, so this patch does not really have an effect. > > > > I'll prepare a patch to remove it from the attributes. > > Well, without this patch, I saw a black screen in my version of EFL MIniBrowser, after hooking it up with PageViewController. > The reason was that the zoom level was infinity. > > m_rawAttributes.devicePixelRatio is actually used in computeMinimumScaleFactorForContentContained (ViewportAgruments.cpp) Yes, you are right restrictMinimumScaleFactorToViewportSize and computeMinimumScaleFactorForContentContained could be called before didChangeViewportAttributes.
Note You need to log in before you can comment on or make changes to this bug.