WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
174182
[iOS] User agent string incorrectly says "iPhone" instead of "iPad" on newer iPads
https://bugs.webkit.org/show_bug.cgi?id=174182
Summary
[iOS] User agent string incorrectly says "iPhone" instead of "iPad" on newer ...
Chris Dumez
Reported
2017-07-05 15:41:12 PDT
User agent string incorrectly says "iPhone" instead of "iPad" on newer iPads.
Attachments
Patch
(2.68 KB, patch)
2017-07-05 16:04 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(3.17 KB, patch)
2017-07-05 16:19 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(3.05 KB, patch)
2017-07-05 16:50 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Patch
(3.04 KB, patch)
2017-07-05 17:05 PDT
,
Chris Dumez
commit-queue
: commit-queue-
Details
Formatted Diff
Diff
Patch for landing
(3.03 KB, patch)
2017-07-05 18:23 PDT
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
Show Obsolete
(4)
View All
Add attachment
proposed patch, testcase, etc.
Chris Dumez
Comment 1
2017-07-05 15:41:29 PDT
<
rdar://problem/32868369
>
Chris Dumez
Comment 2
2017-07-05 16:04:07 PDT
Created
attachment 314661
[details]
Patch
Chris Dumez
Comment 3
2017-07-05 16:19:34 PDT
Created
attachment 314663
[details]
Patch
Tim Horton
Comment 4
2017-07-05 16:36:33 PDT
Comment on
attachment 314663
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=314663&action=review
> Source/WebCore/page/ios/UserAgentIOS.mm:45 > + bool isClassicOnPad = deviceClass() == MGDeviceClassiPad && [[getUIApplicationClass() sharedApplication] _isClassic]; > + return isClassicOnPad && [getUIApplicationClass() _classicMode] != UIApplicationSceneClassicModeOriginalPad;
I think (for reasons explained on IRC) we should go with something that does this: if (is classic) { if (is UIApplicationSceneClassicModeOriginalPad) return @"iPad" return @"iPhone" } ... return deviceName
Chris Dumez
Comment 5
2017-07-05 16:50:13 PDT
Created
attachment 314667
[details]
Patch
Tim Horton
Comment 6
2017-07-05 16:55:28 PDT
Comment on
attachment 314667
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=314667&action=review
> Source/WebCore/page/ios/UserAgentIOS.mm:49 > + return isClassic() && [getUIApplicationClass() _classicMode] == UIApplicationSceneClassicModeOriginalPad;
Technically no reason to check isClassic here because it just checks that _classicMode is not the "none" mode :P
Chris Dumez
Comment 7
2017-07-05 17:05:44 PDT
Created
attachment 314669
[details]
Patch
WebKit Commit Bot
Comment 8
2017-07-05 17:12:36 PDT
Comment on
attachment 314669
[details]
Patch Rejecting
attachment 314669
[details]
from commit-queue. Failed to run "['/Volumes/Data/EWS/WebKit/Tools/Scripts/webkit-patch', '--status-host=webkit-queues.webkit.org', '--bot-id=webkit-cq-03', 'validate-changelog', '--check-oops', '--non-interactive', 314669, '--port=mac']" exit_code: 1 cwd: /Volumes/Data/EWS/WebKit ChangeLog entry in Source/WebCore/ChangeLog contains OOPS!. Full output:
http://webkit-queues.webkit.org/results/4059537
Chris Dumez
Comment 9
2017-07-05 18:23:09 PDT
Created
attachment 314673
[details]
Patch for landing
WebKit Commit Bot
Comment 10
2017-07-05 19:01:33 PDT
Comment on
attachment 314673
[details]
Patch for landing Clearing flags on attachment: 314673 Committed
r219177
: <
http://trac.webkit.org/changeset/219177
>
WebKit Commit Bot
Comment 11
2017-07-05 19:01:35 PDT
All reviewed patches have been landed. Closing bug.
Chris Dumez
Comment 12
2017-07-05 20:11:26 PDT
Follow-up build fixes:
https://trac.webkit.org/r219183
&
https://trac.webkit.org/r219184
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug