mirror of
https://github.com/Ttanasart-pt/Pixel-Composer.git
synced 2024-12-25 06:26:42 +01:00
- Fix bug when editing area in two point mode.
This commit is contained in:
parent
b229ecd671
commit
1a6149c3ce
4 changed files with 15 additions and 6 deletions
|
@ -38,7 +38,7 @@
|
||||||
LATEST_VERSION = 11700;
|
LATEST_VERSION = 11700;
|
||||||
VERSION = 11740;
|
VERSION = 11740;
|
||||||
SAVE_VERSION = 11700;
|
SAVE_VERSION = 11700;
|
||||||
VERSION_STRING = "1.17.4.001";
|
VERSION_STRING = "1.17.4.002";
|
||||||
BUILD_NUMBER = 11740;
|
BUILD_NUMBER = 11740;
|
||||||
|
|
||||||
globalvar HOTKEYS, HOTKEY_CONTEXT;
|
globalvar HOTKEYS, HOTKEY_CONTEXT;
|
||||||
|
|
|
@ -22,6 +22,7 @@ function Node_MK_Fracture(_x, _y, _group = noone) : Node_Processor(_x, _y, _grou
|
||||||
surface_set_target(_outSurf);
|
surface_set_target(_outSurf);
|
||||||
DRAW_CLEAR
|
DRAW_CLEAR
|
||||||
|
|
||||||
|
|
||||||
surface_reset_target();
|
surface_reset_target();
|
||||||
|
|
||||||
return _outSurf;
|
return _outSurf;
|
||||||
|
|
|
@ -1401,7 +1401,7 @@ function Panel_Preview() : PanelContent() constructor {
|
||||||
_hv = true;
|
_hv = true;
|
||||||
|
|
||||||
draw_circle_ui(_d3x, _d3y, d3_view_wz, _hv? 0 : 0.04, COLORS._main_icon, 0.3);
|
draw_circle_ui(_d3x, _d3y, d3_view_wz, _hv? 0 : 0.04, COLORS._main_icon, 0.3);
|
||||||
draw_sprite_ext(THEME.view_zoom, 0, _d3x, _d3y, 1, 1, 0, view_zoom_tool? COLORS._main_accent : COLORS._main_icon, 1);
|
draw_sprite_ui(THEME.view_zoom, 0, _d3x, _d3y, 1, 1, 0, view_zoom_tool? COLORS._main_accent : COLORS._main_icon, 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -53,8 +53,7 @@ function preview_overlay_area_padding(interact, active, _x, _y, _s, _mx, _my, _s
|
||||||
else if(drag_type == 4) _b = value_snap(drag_sy - (_my - drag_my) / _s, _sny);
|
else if(drag_type == 4) _b = value_snap(drag_sy - (_my - drag_my) / _s, _sny);
|
||||||
|
|
||||||
if(drag_type) {
|
if(drag_type) {
|
||||||
var _svl = showValue();
|
var _sval = array_clone(showValue());
|
||||||
var _sval = array_clone(_svl);
|
|
||||||
if(unit.mode == VALUE_UNIT.reference) {
|
if(unit.mode == VALUE_UNIT.reference) {
|
||||||
var _ref = unit.reference();
|
var _ref = unit.reference();
|
||||||
_sval[0] *= _ref[0];
|
_sval[0] *= _ref[0];
|
||||||
|
@ -170,11 +169,21 @@ function preview_overlay_area_two_point(interact, active, _x, _y, _s, _mx, _my,
|
||||||
var _hov = [ 0, 0, 0 ];
|
var _hov = [ 0, 0, 0 ];
|
||||||
var _r = 10;
|
var _r = 10;
|
||||||
|
|
||||||
|
if(drag_type) {
|
||||||
|
var _sval = array_clone(showValue());
|
||||||
|
if(unit.mode == VALUE_UNIT.reference) {
|
||||||
|
var _ref = unit.reference();
|
||||||
|
_sval[0] *= _ref[0];
|
||||||
|
_sval[1] *= _ref[1];
|
||||||
|
_sval[2] *= _ref[0];
|
||||||
|
_sval[3] *= _ref[1];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if(drag_type == 1) {
|
if(drag_type == 1) {
|
||||||
var _xx = value_snap(drag_sx + (_mx - drag_mx) / _s, _snx);
|
var _xx = value_snap(drag_sx + (_mx - drag_mx) / _s, _snx);
|
||||||
var _yy = value_snap(drag_sy + (_my - drag_my) / _s, _sny);
|
var _yy = value_snap(drag_sy + (_my - drag_my) / _s, _sny);
|
||||||
|
|
||||||
var _sval = array_clone(showValue());
|
|
||||||
_sval[0] = _xx;
|
_sval[0] = _xx;
|
||||||
_sval[1] = _yy;
|
_sval[1] = _yy;
|
||||||
|
|
||||||
|
@ -189,7 +198,6 @@ function preview_overlay_area_two_point(interact, active, _x, _y, _s, _mx, _my,
|
||||||
var _xx = value_snap(drag_sx + (_mx - drag_mx) / _s, _snx);
|
var _xx = value_snap(drag_sx + (_mx - drag_mx) / _s, _snx);
|
||||||
var _yy = value_snap(drag_sy + (_my - drag_my) / _s, _sny);
|
var _yy = value_snap(drag_sy + (_my - drag_my) / _s, _sny);
|
||||||
|
|
||||||
var _sval = array_clone(showValue());
|
|
||||||
_sval[2] = _xx;
|
_sval[2] = _xx;
|
||||||
_sval[3] = _yy;
|
_sval[3] = _yy;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue