Bug 187922 - WebCore::primaryScreenDisplayID() always return 0
Summary: WebCore::primaryScreenDisplayID() always return 0
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Per Arne Vollan
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2018-07-23 13:52 PDT by Per Arne Vollan
Modified: 2018-07-30 08:43 PDT (History)
5 users (show)

See Also:


Attachments
Patch (1.40 KB, patch)
2018-07-23 13:54 PDT, Per Arne Vollan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Per Arne Vollan 2018-07-23 13:52:48 PDT
This function should return a valid display ID.
Comment 1 Per Arne Vollan 2018-07-23 13:54:59 PDT
Created attachment 345604 [details]
Patch
Comment 2 Per Arne Vollan 2018-07-23 13:56:00 PDT
<rdar://problem/42286933>
Comment 3 Geoffrey Garen 2018-07-23 14:19:46 PDT
Comment on attachment 345604 [details]
Patch

r=me

You could probably test this in an automated way if you added a function or property in window.internals to override screenProperties().primaryDisplayID. That would at least test the fact that primaryScreenDisplayID() no longer unconditionally returns 0. (You just need the test harness to remember to
Comment 4 Geoffrey Garen 2018-07-23 14:20:01 PDT
...reset the value when it's done.
Comment 5 Per Arne Vollan 2018-07-23 14:46:56 PDT
(In reply to Geoffrey Garen from comment #4)
> ...reset the value when it's done.

Thanks for reviewing! I added https://bugs.webkit.org/show_bug.cgi?id=187922 to track adding a test.
Comment 6 WebKit Commit Bot 2018-07-23 15:16:38 PDT
Comment on attachment 345604 [details]
Patch

Clearing flags on attachment: 345604

Committed r234113: <https://trac.webkit.org/changeset/234113>
Comment 7 WebKit Commit Bot 2018-07-23 15:16:40 PDT
All reviewed patches have been landed.  Closing bug.
Comment 8 Per Arne Vollan 2018-07-30 08:43:15 PDT
(In reply to Per Arne Vollan from comment #5)
> (In reply to Geoffrey Garen from comment #4)
> > ...reset the value when it's done.
> 
> Thanks for reviewing! I added https://bugs.webkit.org/show_bug.cgi?id=187922
> to track adding a test.

Sorry, that was not the correct bug. It should be https://bugs.webkit.org/show_bug.cgi?id=187925.