MCPcopy Create free account
hub / github.com/AstroImageJ/astroimagej / updateFields

Method updateFields

ij/src/main/java/ij/plugin/Resizer.java:395–405  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

393 }
394
395 void updateFields() {
396 if (sizeToHeight) {
397 newWidth = (int)Math.round(newHeight*(origWidth/origHeight));
398 TextField widthField = (TextField)fields.elementAt(0);
399 widthField.setText(""+newWidth);
400 } else {
401 newHeight = (int)Math.round(newWidth*(origHeight/origWidth));
402 TextField heightField = (TextField)fields.elementAt(1);
403 heightField.setText(""+newHeight);
404 }
405 }
406
407 public void itemStateChanged(ItemEvent e) {
408 Checkbox cb = (Checkbox)checkboxes.elementAt(0);

Callers 2

textValueChangedMethod · 0.95
itemStateChangedMethod · 0.95

Calls 2

roundMethod · 0.45
setTextMethod · 0.45

Tested by

no test coverage detected