Skip to content

Commit e715219

Browse files
Merge pull request #120 from martinRenou/fix_rubberband_firefox
Fix rubberband on Firefox
2 parents 8c052b8 + bbd66f4 commit e715219

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

js/src/mpl_widget.js

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -226,10 +226,8 @@ var MPLCanvasView = widgets.DOMWidgetView.extend({
226226
this.canvas.setAttribute('height', height * this.ratio);
227227
this.canvas.style.width = width + 'px';
228228

229-
this.rubberband_canvas.setAttribute('width', width * this.ratio);
230-
this.rubberband_canvas.setAttribute('height', height * this.ratio);
231-
this.rubberband_canvas.style.height = height + 'px';
232-
this.rubberband_canvas.style.height = height + 'px';
229+
this.rubberband_canvas.setAttribute('width', width);
230+
this.rubberband_canvas.setAttribute('height', height);
233231
},
234232

235233
send_message: function(type, message = {}) {

0 commit comments

Comments
 (0)