better error messages when tryng to do forbidden actions on rotated objects

This commit is contained in:
viliusle 2023-04-21 11:43:48 +03:00
parent e5022921e2
commit b71c64b227
7 changed files with 11 additions and 11 deletions

View File

@ -46,7 +46,7 @@ class Blur_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}
this.started = true;

View File

@ -127,7 +127,7 @@ class Clone_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}
if (e.which == 3 && mouse.valid == true) {
@ -156,7 +156,7 @@ class Clone_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}
@ -189,7 +189,7 @@ class Clone_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}
if (this.clone_coords === null) {
@ -197,13 +197,13 @@ class Clone_class extends Base_tools_class {
return;
}
if (layer.width != layer.width_original || layer.height != layer.height_original) {
alertify.error('Clone tool disabled for resized image. Sorry.');
alertify.error('Clone tool disabled for resized image. Please rasterize first.');
return;
}
if (params.source_layer.value == 'Previous' &&
(previous_layer.width != previous_layer.width_original
|| previous_layer.height != previous_layer.height_original)) {
alertify.error('Clone tool disabled for resized image. Sorry.');
alertify.error('Clone tool disabled for resized image. Please rasterize first.');
return;
}
if (params.source_layer.value == 'Previous') {

View File

@ -46,7 +46,7 @@ class Desaturate_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}
this.started = true;

View File

@ -64,7 +64,7 @@ class Erase_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}
this.started = true;

View File

@ -43,7 +43,7 @@ class Fill_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}

View File

@ -41,7 +41,7 @@ class Magic_erase_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}

View File

@ -46,7 +46,7 @@ class Sharpen_class extends Base_tools_class {
return;
}
if (config.layer.rotate || 0 > 0) {
alertify.error('Erase on rotate object is disabled. Sorry.');
alertify.error('Erase on rotate object is disabled. Please rasterize first.');
return;
}
this.started = true;