Skip to content

Commit

Permalink
show current source power (sharpie7#958)
Browse files Browse the repository at this point in the history
  • Loading branch information
pfalstad committed Oct 24, 2024
1 parent c9e60bb commit f89b1ac
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/com/lushprojects/circuitjs1/client/CurrentElm.java
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,8 @@ public void setEditValue(int n, EditInfo ei) {
}
void getInfo(String arr[]) {
arr[0] = "current source";
getBasicInfo(arr);
int i = getBasicInfo(arr);
arr[i++] = "P = " + getUnitText(getPower(), "W");
}
double getVoltageDiff() {
return volts[1] - volts[0];
Expand Down

0 comments on commit f89b1ac

Please sign in to comment.