Skip to content

Commit f2460a4

Browse files
committed
Disbale pad drawing make private
1 parent 72b726f commit f2460a4

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

modules/gpad/TPadPainter.mjs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,7 @@ class TPadPainter extends ObjectPainter {
209209
#pad_width; // pad width
210210
#pad_height; // pad height
211211
#doing_draw; // drawing handles
212+
#pad_draw_disabled; // disable drawing of the pad
212213
#last_grayscale; // grayscale change flag
213214
#custom_palette; // custom palette
214215
#custom_colors; // custom colors
@@ -271,7 +272,7 @@ class TPadPainter extends ObjectPainter {
271272
}
272273

273274
if (pad?.$disable_drawing)
274-
this.pad_draw_disabled = true;
275+
this.#pad_draw_disabled = true;
275276
}
276277

277278
/** @summary returns pad painter
@@ -983,7 +984,7 @@ class TPadPainter extends ObjectPainter {
983984
width = svg_can.property('draw_width'),
984985
height = svg_can.property('draw_height'),
985986
pad_enlarged = svg_can.property('pad_enlarged'),
986-
pad_visible = !this.pad_draw_disabled && (!pad_enlarged || (pad_enlarged === this.#pad)),
987+
pad_visible = !this.#pad_draw_disabled && (!pad_enlarged || (pad_enlarged === this.#pad)),
987988
is_batch = this.isBatchMode();
988989
let w = Math.round(this.#pad.fAbsWNDC * width),
989990
h = Math.round(this.#pad.fAbsHNDC * height),
@@ -1153,8 +1154,8 @@ class TPadPainter extends ObjectPainter {
11531154
/** @summary Disable pad drawing
11541155
* @desc Complete SVG element will be hidden */
11551156
disablePadDrawing() {
1156-
if (!this.pad_draw_disabled && !this.isTopPad()) {
1157-
this.pad_draw_disabled = true;
1157+
if (!this.#pad_draw_disabled && !this.isTopPad()) {
1158+
this.#pad_draw_disabled = true;
11581159
this.createPadSvg(true);
11591160
}
11601161
}

0 commit comments

Comments
 (0)