Commit 90d21071 authored by pfeldman@chromium.org's avatar pfeldman@chromium.org

DevTools: spectrum should switch to rgba upon adding alpha on drag.

BUG=525031

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

git-svn-id: svn://svn.chromium.org/blink/trunk@201251 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent f91b1ca6
......@@ -159,7 +159,7 @@ WebInspector.Spectrum = function()
var hsva = this._hsv.slice();
hsva[3] = Number.constrain(newAlpha, 0, 1);
var colorFormat = undefined;
if (this._color().hasAlpha() && (this._colorFormat === WebInspector.Color.Format.ShortHEX || this._colorFormat === WebInspector.Color.Format.HEX || this._colorFormat === WebInspector.Color.Format.Nickname))
if (hsva[3] !== 1 && (this._colorFormat === WebInspector.Color.Format.ShortHEX || this._colorFormat === WebInspector.Color.Format.HEX || this._colorFormat === WebInspector.Color.Format.Nickname))
colorFormat = WebInspector.Color.Format.RGB;
this._innerSetColor(hsva, "", colorFormat, WebInspector.Spectrum._ChangeSource.Other);
}
......
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