Bug 85049 - Rename deviceDPI to devicePixelRatio
Summary: Rename deviceDPI to devicePixelRatio
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Qt (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alexander Færøy
URL:
Keywords: Qt, QtTriaged
Depends on:
Blocks: 70236
  Show dependency treegraph
 
Reported: 2012-04-27 04:25 PDT by Alexander Færøy
Modified: 2012-05-03 03:53 PDT (History)
9 users (show)

See Also:


Attachments
Patch (10.88 KB, patch)
2012-05-02 05:44 PDT, Alexander Færøy
no flags Details | Formatted Diff | Diff
Patch (10.90 KB, patch)
2012-05-02 06:47 PDT, Alexander Færøy
no flags Details | Formatted Diff | Diff
Patch (1.65 KB, patch)
2012-05-03 03:22 PDT, Alexander Færøy
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Færøy 2012-04-27 04:25:50 PDT
SSIA.
Comment 1 Alexander Færøy 2012-05-02 05:44:10 PDT
Created attachment 139794 [details]
Patch
Comment 2 Kenneth Rohde Christiansen 2012-05-02 05:46:21 PDT
Comment on attachment 139794 [details]
Patch

In the future lets add documentation
Comment 3 Konrad Piascik 2012-05-02 06:04:16 PDT
Comment on attachment 139794 [details]
Patch

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

> Source/WebKit2/WebProcess/WebPage/WebPage.cpp:893
> +    ViewportAttributes attr = computeViewportAttributes(m_page->viewportArguments(), minimumLayoutFallbackWidth, settings->deviceWidth(), settings->deviceHeight(), 160 * settings->devicePixelRatio(), m_viewportSize);

How is this correct?  devicePixelRatio is supposed to be a double, but device DPI is an int.  These are 2 different properties aren't they?  You can't pass devicePixelRatio into the deviceDPI value for computeViewportAttributers.
Comment 4 Jesus Sanchez-Palencia 2012-05-02 06:06:35 PDT
(In reply to comment #2)
> (From update of attachment 139794 [details])
> In the future lets add documentation

<nitpicking> I think the bug title here is a bit misleading on a first glance since this patch is more about adding the experimental API than actually refactoring that piece of code. 2 cents for the future ;) </nitpicking>
Comment 5 Alexander Færøy 2012-05-02 06:47:09 PDT
Created attachment 139803 [details]
Patch
Comment 6 Alexander Færøy 2012-05-03 01:55:36 PDT
Committed r115948: <http://trac.webkit.org/changeset/115948>
Comment 7 Csaba Osztrogonác 2012-05-03 02:41:20 PDT
Reopen, because it broke an API test on Qt5-WK2:
FAIL!  : tst_QQuickWebView::scrollRequest() 'webView()->contentY() == y' returned FALSE. ()
   Loc: [/home/webkitbuildbot/slaves/release64bitWebKit2_EC2/buildslave/qt-linux-64-release-webkit2/build/Source/WebKit2/UIProcess/API/qt/tests/qquickwebview/tst_qquickwebview.cpp(400)]

Could you check and fix it?
Comment 8 Alexander Færøy 2012-05-03 03:22:40 PDT
Created attachment 139979 [details]
Patch
Comment 9 Alexander Færøy 2012-05-03 03:50:09 PDT
Committed r115955: <http://trac.webkit.org/changeset/115955>