Skip to content

Commit a2d0d18

Browse files
committed
Consolidate save handling
1 parent 89c88e7 commit a2d0d18

File tree

1 file changed

+1
-3
lines changed
  • lib/matplotlib/backends/web_backend

1 file changed

+1
-3
lines changed

lib/matplotlib/backends/web_backend/mpl.js

+1-3
Original file line numberDiff line numberDiff line change
@@ -480,9 +480,7 @@ mpl.figure.prototype.key_event = function(event, name) {
480480

481481
mpl.figure.prototype.toolbar_button_onclick = function(name) {
482482
if (name == 'download') {
483-
var format_dropdown = this.format_dropdown;
484-
var format = format_dropdown.options[format_dropdown.selectedIndex].value;
485-
this.ondownload(this, format);
483+
this.handle_save(this, null);
486484
} else {
487485
this.send_message("toolbar_button", {name: name});
488486
}

0 commit comments

Comments
 (0)