Skip to content
This repository was archived by the owner on Oct 24, 2025. It is now read-only.

Commit 90737de

Browse files
committed
handles must be at best visibility
1 parent 3b51101 commit 90737de

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

src/js/core/GraphicsRenderer.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ function GraphicDisplay(displayName, width, height) {
6161

6262
// Temporary or selected color
6363
this.selectedColor = "#0080ff";
64-
this.selectedRadius = "2";
64+
this.selectedRadius = 2;
6565

6666
this.logicDisplay;
6767

@@ -568,17 +568,20 @@ GraphicDisplay.prototype.drawTemporaryComponent = function (e) {
568568
GraphicDisplay.prototype.drawPoint = function (x, y, color, radius) {
569569
if (this.temporarySelectedComponent != null) {
570570
this.context.lineWidth = 3;
571+
this.context.fillStyle = '#fff';
572+
this.context.strokeStyle = this.selectedColor;
571573
} else {
572574
this.context.lineWidth = 3 * this.zoom;
575+
this.context.fillStyle = color;
576+
this.context.strokeStyle = color;
573577
}
574-
this.context.fillStyle = color;
575-
this.context.strokeStyle = color;
576578
this.context.beginPath();
577579
this.context.arc(
578580
(x + this.cOutX) * this.zoom,
579581
(y + this.cOutY) * this.zoom,
580582
2 * this.zoom, 0, 3.14159 * 2, false);
581583
this.context.closePath();
584+
this.context.fill();
582585
this.context.stroke();
583586
};
584587

0 commit comments

Comments
 (0)