summaryrefslogtreecommitdiff
path: root/js/Electrical
diff options
context:
space:
mode:
Diffstat (limited to 'js/Electrical')
-rw-r--r--js/Electrical/ConstantVoltage.js5
-rw-r--r--js/Electrical/Inductor.js5
-rw-r--r--js/Electrical/Resistor.js5
3 files changed, 12 insertions, 3 deletions
diff --git a/js/Electrical/ConstantVoltage.js b/js/Electrical/ConstantVoltage.js
index 866d0c0e..a0b070cf 100644
--- a/js/Electrical/ConstantVoltage.js
+++ b/js/Electrical/ConstantVoltage.js
@@ -26,7 +26,10 @@ function ConstantVoltage() {
return this.x;
}
ConstantVoltage.prototype.get = function ConstantVoltage() {
- alert("parameters cannot be modified");
+ var options = {
+ V:["V (volt)",this.V],
+ }
+ return options;
}
ConstantVoltage.prototype.set = function ConstantVoltage() {
this.exprs = this.graphics.exprs;
diff --git a/js/Electrical/Inductor.js b/js/Electrical/Inductor.js
index 321f3f18..0e497d10 100644
--- a/js/Electrical/Inductor.js
+++ b/js/Electrical/Inductor.js
@@ -26,7 +26,10 @@ function Inductor() {
return this.x;
}
Inductor.prototype.get = function Inductor() {
- alert("parameters cannot be modified");
+ var options = {
+ L:["L (H)",this.L],
+ }
+ return options;
}
Inductor.prototype.set = function Inductor() {
this.exprs = this.graphics.exprs;
diff --git a/js/Electrical/Resistor.js b/js/Electrical/Resistor.js
index 5c2494b5..fc7188de 100644
--- a/js/Electrical/Resistor.js
+++ b/js/Electrical/Resistor.js
@@ -26,7 +26,10 @@ function Resistor() {
return this.x;
}
Resistor.prototype.get = function Resistor() {
- alert("parameters cannot be modified");
+ var options = {
+ R:["R (ohm)",this.R],
+ }
+ return options;
}
Resistor.prototype.set = function Resistor() {
this.exprs = this.graphics.exprs;