Skip to content

Commit

Permalink
Support decimals for zoom factor (workaround until we actually get a
Browse files Browse the repository at this point in the history
"fit" option and a drag+zoom optin.
  • Loading branch information
ecki committed Oct 3, 2012
1 parent 5f05343 commit 0c0ed23
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/com/tagtraum/perf/gcviewer/action/Zoom.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ public void actionPerformed(final ActionEvent e) {
try {
String item = (String)o[0];
if (item.endsWith("%")) item = item.substring(0, item.length()-1);
final int zoomFactor = NumberParser.parseInt(item.trim());
final double zoomFactor = Double.parseDouble(item.trim());
if (zoomFactor > 0) gcViewer.getSelectedGCDocument().getModelChart().setScaleFactor(zoomFactor/1000.0);
}
catch (NumberFormatException nfe) {
Expand Down

0 comments on commit 0c0ed23

Please sign in to comment.