diff --git a/clapper_src/controls.js b/clapper_src/controls.js index 6ebcbb16..20261f48 100644 --- a/clapper_src/controls.js +++ b/clapper_src/controls.js @@ -436,8 +436,20 @@ class ClapperControls extends Gtk.Box player.set_volume(linearVolume); - /* FIXME: Should be placed in 'volume-changed' + /* FIXME: All of below should be placed in 'volume-changed' * event once we move to message bus API */ + let cssClass = 'overamp'; + let hasOveramp = (scale.has_css_class(cssClass)); + + if(volume > 1) { + if(!hasOveramp) + scale.add_css_class(cssClass); + } + else { + if(hasOveramp) + scale.remove_css_class(cssClass); + } + this._updateVolumeButtonIcon(volume); } diff --git a/css/styles.css b/css/styles.css index 86d66bdd..6c6992d7 100644 --- a/css/styles.css +++ b/css/styles.css @@ -96,6 +96,9 @@ scale marks { .osd .volumescale trough highlight { min-width: 6px; } +.overamp trough highlight { + background: @error_color; +} /* Floating Mode */ .floatingwindow {