Bug 194686 - Refactor EditingStyle::textDirection to return an Optional<WritingDirection> instead of a bool
Summary: Refactor EditingStyle::textDirection to return an Optional<WritingDirection> ...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: HTML Editing (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Wenson Hsieh
URL:
Keywords: DoNotImportToRadar
Depends on:
Blocks:
 
Reported: 2019-02-14 17:37 PST by Wenson Hsieh
Modified: 2019-02-15 08:52 PST (History)
5 users (show)

See Also:


Attachments
Patch (8.33 KB, patch)
2019-02-14 18:35 PST, Wenson Hsieh
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Wenson Hsieh 2019-02-14 17:37:42 PST
bool textDirection(WritingDirection&) is a little clunky.

A more modern idiom for these kinds of methods is to return an Optional<T> instead, where nullopt corresponds to a false return value.
Comment 1 Wenson Hsieh 2019-02-14 18:35:08 PST
Created attachment 362089 [details]
Patch
Comment 2 WebKit Commit Bot 2019-02-15 08:52:39 PST
Comment on attachment 362089 [details]
Patch

Clearing flags on attachment: 362089

Committed r241588: <https://trac.webkit.org/changeset/241588>
Comment 3 WebKit Commit Bot 2019-02-15 08:52:41 PST
All reviewed patches have been landed.  Closing bug.