Commit f2ae32c8 authored by mlamouri's avatar mlamouri Committed by Commit bot

Fix reversed DCHECK() in ScreenOrientationProvider.

Also fixes a typo.

This is a follow-up from https://codereview.chromium.org/2391883006

BUG=612339

Review-Url: https://codereview.chromium.org/2564953003
Cr-Commit-Position: refs/heads/master@{#437874}
parent c4308a50
...@@ -28,10 +28,9 @@ ScreenOrientationProvider::~ScreenOrientationProvider() { ...@@ -28,10 +28,9 @@ ScreenOrientationProvider::~ScreenOrientationProvider() {
void ScreenOrientationProvider::LockOrientation( void ScreenOrientationProvider::LockOrientation(
blink::WebScreenOrientationLockType orientation, blink::WebScreenOrientationLockType orientation,
const LockOrientationCallback& callback) { const LockOrientationCallback& callback) {
// ScreenOrientation should have cancelled all pending request at thie point. // ScreenOrientation should have cancelled all pending request at this point.
DCHECK(on_result_callback_.is_null()); DCHECK(on_result_callback_.is_null());
DCHECK(pending_lock_orientation_.has_value()); DCHECK(!pending_lock_orientation_.has_value());
DCHECK(pending_lock_orientation_.value() >= 0);
on_result_callback_ = callback; on_result_callback_ = callback;
if (!delegate_ || !delegate_->ScreenOrientationProviderSupported()) { if (!delegate_ || !delegate_->ScreenOrientationProviderSupported()) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment