mirror of
https://github.com/lospec/pixel-editor.git
synced 2023-08-10 21:12:51 +03:00
Fixed canvas size limitations
This commit is contained in:
parent
1d754f4852
commit
c2014682d0
@ -17,6 +17,12 @@ const Startup = (() => {
|
|||||||
var width = Util.getValue('size-width' + splashPostfix);
|
var width = Util.getValue('size-width' + splashPostfix);
|
||||||
var height = Util.getValue('size-height' + splashPostfix);
|
var height = Util.getValue('size-height' + splashPostfix);
|
||||||
var selectedPalette = Util.getText('palette-button' + splashPostfix);
|
var selectedPalette = Util.getText('palette-button' + splashPostfix);
|
||||||
|
|
||||||
|
//Checks whether width and height values are not invalid
|
||||||
|
if(width <= 0 || height <= 0) {
|
||||||
|
alert("Please enter valid width and height");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
newPixel(FileManager.defaultLPE(width,height));
|
newPixel(FileManager.defaultLPE(width,height));
|
||||||
resetInput();
|
resetInput();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user