Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(44)

Unified Diff: third_party/WebKit/Source/core/html/shadow/MediaControlElements.cpp

Issue 2616343004: Media Controls: invalidate volume slider when value changes. (Closed)
Patch Set: Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/html/shadow/MediaControlElements.cpp
diff --git a/third_party/WebKit/Source/core/html/shadow/MediaControlElements.cpp b/third_party/WebKit/Source/core/html/shadow/MediaControlElements.cpp
index 9cfad2953dc9454d0d0f1224e3319614bd5c7667..b5a95e3f43509d32fd5744917377a56a92e13d7c 100644
--- a/third_party/WebKit/Source/core/html/shadow/MediaControlElements.cpp
+++ b/third_party/WebKit/Source/core/html/shadow/MediaControlElements.cpp
@@ -856,8 +856,12 @@ bool MediaControlVolumeSliderElement::willRespondToMouseClickEvents() {
}
void MediaControlVolumeSliderElement::setVolume(double volume) {
- if (value().toDouble() != volume)
- setValue(String::number(volume));
+ if (value().toDouble() == volume)
whywhat 2017/01/09 16:06:59 nit: is it okay to compare doubles like this? I re
mlamouri (slow - plz ping) 2017/01/10 14:13:19 In general, we can assume that any change is meani
+ return;
+
+ setValue(String::number(volume));
+ if (LayoutObject* layoutObject = this->layoutObject())
+ layoutObject->setShouldDoFullPaintInvalidation();
}
bool MediaControlVolumeSliderElement::keepEventInNode(Event* event) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698