##// END OF EJS Templates
Fixed typos in throttling code.
Jonathan Frederic -
Show More
@@ -72,14 +72,13 b' define(["components/underscore/underscore-min",'
72 // Send buffer if this message caused another message to be
72 // Send buffer if this message caused another message to be
73 // throttled.
73 // throttled.
74 if (this.msg_buffer != null &&
74 if (this.msg_buffer != null &&
75 this.msg_throttle == this.pending_msgs &&
75 this.msg_throttle == this.pending_msgs) {
76 this.msg_buffer.length > 0) {
76
77
77 var output_area = this._get_output_area(msg.parent_header.msg_id);
78 var output_area = this._get_msg_output_area(msg);
78 var callbacks = this._make_callbacks(output_area);
79 var callbacks = this._make_callbacks(output_area);
79 var data = {sync_method: 'update', sync_data: this.msg_buffer};
80 var data = {sync_method: 'update', sync_data: this.msg_buffer};
80 this.comm.send(data, callbacks);
81 comm.send(data, callbacks);
81 this.msg_buffer = null;
82 this.msg_buffer = null;
83 } else {
82 } else {
84
83
85 // Only decrease the pending message count if the buffer
84 // Only decrease the pending message count if the buffer
@@ -293,7 +292,7 b' define(["components/underscore/underscore-min",'
293 // Get the output area corresponding to the msg_id.
292 // Get the output area corresponding to the msg_id.
294 // output_area is an instance of Ipython.OutputArea
293 // output_area is an instance of Ipython.OutputArea
295 _get_output_area: function (msg_id) {
294 _get_output_area: function (msg_id) {
296
295
297 // First, guess cell.execute triggered
296 // First, guess cell.execute triggered
298 var cells = IPython.notebook.get_cells();
297 var cells = IPython.notebook.get_cells();
299 for (var cell_index in cells) {
298 for (var cell_index in cells) {
General Comments 0
You need to be logged in to leave comments. Login now