2022-01-13 11:24:03 +07:00
|
|
|
/// @description init
|
|
|
|
event_inherited();
|
|
|
|
|
|
|
|
#region data
|
2022-11-03 17:44:49 +07:00
|
|
|
dialog_w = ui(320);
|
2022-12-19 19:35:30 +07:00
|
|
|
dialog_h = ui(300);
|
2022-01-13 11:24:03 +07:00
|
|
|
|
|
|
|
destroy_on_click_out = true;
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
#region data
|
2022-12-19 19:35:30 +07:00
|
|
|
cb_enable = new checkBox(function() {
|
2022-09-21 11:09:40 +07:00
|
|
|
PANEL_PREVIEW.grid_show = !PANEL_PREVIEW.grid_show;
|
2022-11-03 17:44:49 +07:00
|
|
|
});
|
2022-09-21 11:09:40 +07:00
|
|
|
|
2022-12-19 19:35:30 +07:00
|
|
|
cb_snap = new checkBox(function() {
|
|
|
|
PANEL_PREVIEW.grid_snap = !PANEL_PREVIEW.grid_snap;
|
|
|
|
});
|
|
|
|
|
2022-01-13 11:24:03 +07:00
|
|
|
tb_width = new textBox(TEXTBOX_INPUT.number, function(str) {
|
|
|
|
PANEL_PREVIEW.grid_width = max(1, real(str));
|
2022-11-03 17:44:49 +07:00
|
|
|
});
|
2022-01-13 11:24:03 +07:00
|
|
|
|
|
|
|
tb_height = new textBox(TEXTBOX_INPUT.number, function(str) {
|
|
|
|
PANEL_PREVIEW.grid_height = max(1, real(str));
|
2022-11-03 17:44:49 +07:00
|
|
|
});
|
|
|
|
|
|
|
|
sl_opacity = new slider(0, 1, .05, function(str) {
|
|
|
|
PANEL_PREVIEW.grid_opacity = clamp(real(str), 0, 1);
|
|
|
|
});
|
|
|
|
|
2023-02-28 15:43:01 +07:00
|
|
|
cl_color = new buttonColor(function(color) {
|
2022-11-03 17:44:49 +07:00
|
|
|
PANEL_PREVIEW.grid_color = color;
|
2023-02-28 15:43:01 +07:00
|
|
|
}, self);
|
2022-01-13 11:24:03 +07:00
|
|
|
#endregion
|