mirror of
https://github.com/piskelapp/piskel.git
synced 2023-08-10 21:12:52 +03:00
fix color picker regression with intToColor missing
This commit is contained in:
@@ -48,7 +48,7 @@
|
|||||||
overlay.clear();
|
overlay.clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
var frameColor = frame.getPixel(col, row);
|
var frameColor = pskl.utils.intToColor(frame.getPixel(col, row));
|
||||||
var highlightColor = this.getHighlightColor_(frameColor);
|
var highlightColor = this.getHighlightColor_(frameColor);
|
||||||
var size = this.supportsDynamicPenSize() ? pskl.app.penSizeService.getPenSize() : 1;
|
var size = this.supportsDynamicPenSize() ? pskl.app.penSizeService.getPenSize() : 1;
|
||||||
pskl.PixelUtils.resizePixel(col, row, size).forEach(function (point) {
|
pskl.PixelUtils.resizePixel(col, row, size).forEach(function (point) {
|
||||||
|
|||||||
@@ -19,7 +19,7 @@
|
|||||||
*/
|
*/
|
||||||
ns.ColorPicker.prototype.applyToolAt = function(col, row, frame, overlay, event) {
|
ns.ColorPicker.prototype.applyToolAt = function(col, row, frame, overlay, event) {
|
||||||
if (frame.containsPixel(col, row)) {
|
if (frame.containsPixel(col, row)) {
|
||||||
var sampledColor = frame.getPixel(col, row);
|
var sampledColor = pskl.utils.intToColor(frame.getPixel(col, row));
|
||||||
if (pskl.app.mouseStateService.isLeftButtonPressed()) {
|
if (pskl.app.mouseStateService.isLeftButtonPressed()) {
|
||||||
$.publish(Events.SELECT_PRIMARY_COLOR, [sampledColor]);
|
$.publish(Events.SELECT_PRIMARY_COLOR, [sampledColor]);
|
||||||
} else if (pskl.app.mouseStateService.isRightButtonPressed()) {
|
} else if (pskl.app.mouseStateService.isRightButtonPressed()) {
|
||||||
|
|||||||
Reference in New Issue
Block a user