mirror of
https://github.com/piskelapp/piskel.git
synced 2023-08-10 21:12:52 +03:00
commit
d370cf8130
@ -45,6 +45,10 @@
|
|||||||
background-image: url(../img/tools/icons/rectangle.png);
|
background-image: url(../img/tools/icons/rectangle.png);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.tool-icon.tool-move {
|
||||||
|
background-image: url(../img/tools/icons/hand.png);
|
||||||
|
}
|
||||||
|
|
||||||
/*.tool-icon.tool-palette {
|
/*.tool-icon.tool-palette {
|
||||||
background-image: url(../img/tools/icons/color-palette.png);
|
background-image: url(../img/tools/icons/color-palette.png);
|
||||||
}*/
|
}*/
|
||||||
@ -69,6 +73,10 @@
|
|||||||
cursor: url(../img/tools/cursors/rectangle.png) 4 21, pointer;
|
cursor: url(../img/tools/cursors/rectangle.png) 4 21, pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.tool-move .drawing-canvas-container:hover {
|
||||||
|
cursor: url(../img/tools/cursors/hand.png) 14 12, pointer;
|
||||||
|
}
|
||||||
|
|
||||||
.tool-icon.selected {
|
.tool-icon.selected {
|
||||||
cursor: auto;
|
cursor: auto;
|
||||||
background-color: #eee;
|
background-color: #eee;
|
||||||
|
@ -30,6 +30,7 @@
|
|||||||
<li class="tool-icon tool-paint-bucket" data-tool-id="tool-paint-bucket" title="Bucket tool"></li>
|
<li class="tool-icon tool-paint-bucket" data-tool-id="tool-paint-bucket" title="Bucket tool"></li>
|
||||||
<li class="tool-icon tool-stroke" data-tool-id="tool-stroke" title="Stroke tool"></li>
|
<li class="tool-icon tool-stroke" data-tool-id="tool-stroke" title="Stroke tool"></li>
|
||||||
<li class="tool-icon tool-rectangle" data-tool-id="tool-rectangle" title="Rectangle tool"></li>
|
<li class="tool-icon tool-rectangle" data-tool-id="tool-rectangle" title="Rectangle tool"></li>
|
||||||
|
<li class="tool-icon tool-move" data-tool-id="tool-move" title="Move tool"></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<ul class="tools-group">
|
<ul class="tools-group">
|
||||||
@ -102,6 +103,7 @@
|
|||||||
<script src="js/drawingtools/Stroke.js"></script>
|
<script src="js/drawingtools/Stroke.js"></script>
|
||||||
<script src="js/drawingtools/PaintBucket.js"></script>
|
<script src="js/drawingtools/PaintBucket.js"></script>
|
||||||
<script src="js/drawingtools/Rectangle.js"></script>
|
<script src="js/drawingtools/Rectangle.js"></script>
|
||||||
|
<script src="js/drawingtools/Move.js"></script>
|
||||||
<script src="js/ToolSelector.js"></script>
|
<script src="js/ToolSelector.js"></script>
|
||||||
|
|
||||||
<!-- Application controller and initialization -->
|
<!-- Application controller and initialization -->
|
||||||
|
@ -14,7 +14,8 @@ pskl.ToolSelector = (function() {
|
|||||||
"eraser" : new pskl.drawingtools.Eraser(),
|
"eraser" : new pskl.drawingtools.Eraser(),
|
||||||
"paintBucket" : new pskl.drawingtools.PaintBucket(),
|
"paintBucket" : new pskl.drawingtools.PaintBucket(),
|
||||||
"stroke" : new pskl.drawingtools.Stroke(),
|
"stroke" : new pskl.drawingtools.Stroke(),
|
||||||
"rectangle" : new pskl.drawingtools.Rectangle()
|
"rectangle" : new pskl.drawingtools.Rectangle(),
|
||||||
|
"move" : new pskl.drawingtools.Move()
|
||||||
};
|
};
|
||||||
var currentSelectedTool = toolInstances.simplePen;
|
var currentSelectedTool = toolInstances.simplePen;
|
||||||
var previousSelectedTool = toolInstances.simplePen;
|
var previousSelectedTool = toolInstances.simplePen;
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
// The fake canvas where we will draw the preview of the stroke:
|
// The fake canvas where we will draw the preview of the stroke:
|
||||||
// Drawing the first point of the stroke in the fake overlay canvas:
|
// Drawing the first point of the stroke in the fake overlay canvas:
|
||||||
drawer.updateOverlay(col, row, color);
|
drawer.overlay.setPixel(col, row, color);
|
||||||
drawer.renderOverlay();
|
drawer.renderOverlay();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -81,5 +81,4 @@
|
|||||||
this.pixels = this.previousStates[this.stateIndex];
|
this.pixels = this.previousStates[this.stateIndex];
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
})();
|
})();
|
Loading…
Reference in New Issue
Block a user