Ensure FragmentData::UniqueId is only called when an object will have an id
FragmentData::UniqueId is not intended to be relied upon as an indicator. Instead, any call to the method should only happen if you know there should be a UniqueId, and failures should be handled by figuring out when a UniqueId should have been created (by paint properties or otherwise). This CL adds a DCHECK to enforce this, and fixes up two locations that were trying to rely on FragmentData::UniqueId to check state. Bug: None Change-Id: I168ad2e91a3418e98d351df8fa3ad879ab2e3427 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1730859Reviewed-by:Philip Rogers <pdr@chromium.org> Reviewed-by:
Robert Flack <flackr@chromium.org> Commit-Queue: Stephen McGruer <smcgruer@chromium.org> Cr-Commit-Position: refs/heads/master@{#684361}
Showing
Please register or sign in to comment