Commit c7ad8c20 authored by rdevlin.cronin's avatar rdevlin.cronin Committed by Commit bot

[Views] Don't reset button state after dragging if the button is disabled.

Review URL: https://codereview.chromium.org/868473002

Cr-Commit-Position: refs/heads/master@{#313580}
parent 6f185c3f
......@@ -273,7 +273,10 @@ void CustomButton::ShowContextMenu(const gfx::Point& p,
}
void CustomButton::OnDragDone() {
SetState(STATE_NORMAL);
// Only reset the state to normal if the button isn't currently disabled
// (since disabled buttons may still be able to be dragged).
if (state_ != STATE_DISABLED)
SetState(STATE_NORMAL);
}
void CustomButton::GetAccessibleState(ui::AXViewState* state) {
......
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