Socket
Socket
Sign inDemoInstall

node-occ-csg-editor

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-occ-csg-editor - npm Package Compare versions

Comparing version 0.1.7 to 0.1.9

17

lib/geometry_editor.js

@@ -78,2 +78,3 @@ const assert = require("assert");

super(name);
this.isVisible = false;
}

@@ -120,2 +121,3 @@

clone.point2 = this.point2.clone();
clone.isVisible = this.isVisible;
return clone;

@@ -147,2 +149,3 @@ }

clone.radius = this.radius.clone();
clone.isVisible = this.isVisible;
return clone;

@@ -178,2 +181,3 @@ }

clone.radius2 = this.radius2.clone();
clone.isVisible = this.isVisible;
return clone;

@@ -202,2 +206,3 @@ }

clone.radius = this.radius.clone();
clone.isVisible = this.isVisible;
return clone;

@@ -233,2 +238,3 @@ }

clone.smallRadius = this.smallRadius.clone();
clone.isVisible = this.isVisible;
return clone;

@@ -279,2 +285,3 @@ }

clone.rightArg.set(this.rightArg.get());
clone.isVisible = this.isVisible;
return clone;

@@ -298,2 +305,3 @@ }

clone.rightArg.set(this.rightArg.get());
clone.isVisible = this.isVisible;
return clone;

@@ -317,2 +325,3 @@ }

clone.rightArg.set(this.rightArg.get());
clone.isVisible = this.isVisible;
return clone;

@@ -360,2 +369,3 @@ }

clone.angle = this.angle.clone();
clone.isVisible = this.isVisible;
return clone;

@@ -382,2 +392,3 @@ }

clone.vector = this.vector.clone();
clone.isVisible = this.isVisible;
return clone;

@@ -513,2 +524,8 @@ }

clone() {
const clone = this.extractSubset(this.items);
//xx clone._parameters = JSON.parse(JSON.stringify(this._parameters));
clone._parameters = this._parameters.map(a=>Object.assign({},a));
return clone;
}
}

@@ -515,0 +532,0 @@

11

lib/widget_collection.js

@@ -45,6 +45,9 @@

static getNextId() {
return IdGenerator._id_generator++;
function S4() {
return (((1+Math.random())*0x10000)|0).toString(16).substring(1);
}
const guid = (S4() + S4() + "-" + S4() + "-4" + S4().substr(0,3) + "-" + S4() + "-" + S4() + S4() + S4()).toLowerCase();
return guid;
};
}
IdGenerator._id_generator = 1;

@@ -90,3 +93,3 @@ class WidgetCollection extends WidgetCollectionBase {

assert(widget instanceof this.getWidgetBaseClass());
assert(widget._id > 0, " widget must be handled by editor | Are you passing a cloned entity ? you shouldn't");
assert(typeof widget._id === "string", " widget must be handled by editor | Are you passing a cloned entity ? you shouldn't");

@@ -225,3 +228,3 @@ if (this.items.length === 0) {

function is_visited(item) {
return item && visitedMap[item._id];
return visitedMap[item._id];
}

@@ -228,0 +231,0 @@ function mark_as_visited(item) {

{
"name": "node-occ-csg-editor",
"version": "0.1.7",
"version": "0.1.9",
"description": "node-occ csg editor module",

@@ -24,2 +24,3 @@ "main": "lib/geometry_editor.js",

"devDependencies": {
"mocha": "^3.5.0",
"should": "^13.0.1"

@@ -26,0 +27,0 @@ },

@@ -643,2 +643,11 @@ const should = require("should");

it("should clone a geoemtry editor",function() {
const g = buildDemoParameterizedObjectWithBox();
const cloned = g.clone();
g.convertToScript().should.eql(cloned.convertToScript());
})
});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc