[Webkit-unassigned] [Bug 149496] [GTK][WPE] Use mobile user-agent on tablet
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Thu Jul 9 07:48:28 PDT 2020
https://bugs.webkit.org/show_bug.cgi?id=149496
--- Comment #36 from Carlos Garcia Campos <cgarcia at igalia.com> ---
Comment on attachment 403863
--> https://bugs.webkit.org/attachment.cgi?id=403863
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=403863&action=review
> Source/WebCore/ChangeLog:8
> + No new tests (OOPS!).
This line should be removed, otherwise commit-queue will reject the patch.
> Source/WTF/wtf/glib/ChassisType.cpp:121
> +Optional<ChassisType> chassisType()
This shouldn't be optional since we are always falling back to Desktop, it never returns nullopt.
> Source/WTF/wtf/glib/ChassisType.cpp:123
> + static Optional<ChassisType> chassisType;
Same here, we will always return a valid enum value.
> Source/WTF/wtf/glib/ChassisType.cpp:126
> + chassisType = readMachineInfoChassisType();
We will need an optional here though.
> Source/WTF/wtf/glib/ChassisType.cpp:127
> + if (chassisType == WTF::nullopt)
Don't compare to nullopt, use !chassisType
> Source/WTF/wtf/glib/ChassisType.cpp:132
> + if (chassisType == WTF::nullopt)
> + chassisType = ChassisType::Desktop;
And here we could do chassisType = optionalChassisType.valueOr(ChassisType::Desktop);
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20200709/33b8e4a1/attachment.htm>
More information about the webkit-unassigned
mailing list