mirror of
https://github.com/jupyter/notebook.git
synced 2025-02-23 12:49:41 +08:00
comment more
This commit is contained in:
parent
0fa8b2236a
commit
839b8489c8
@ -264,6 +264,8 @@ var IPython = (function (IPython) {
|
||||
};
|
||||
|
||||
// As you type completer
|
||||
// this should be called by the completer, that in return will
|
||||
// be reclled by finish_completing
|
||||
CodeCell.prototype.requestCompletion= function(callback)
|
||||
{
|
||||
this._compcallback = callback;
|
||||
@ -274,9 +276,14 @@ var IPython = (function (IPython) {
|
||||
var line = this.code_mirror.getLine(cur.line);
|
||||
this.is_completing = true;
|
||||
this.completion_cursor = cur;
|
||||
// one could fork here and directly call finish completing
|
||||
// if kernel is busy
|
||||
IPython.notebook.complete_cell(this, line, cur.ch);
|
||||
}
|
||||
|
||||
// called when completion came back from the kernel. this will inspect the
|
||||
// curent cell for (more) completion merge the resuults with the ones
|
||||
// comming from the kernel and forward it to the completer
|
||||
CodeCell.prototype.finish_completing = function (matched_text, matches) {
|
||||
// let's build a function that wrap all that stuff into what is needed for the
|
||||
// new completer:
|
||||
|
Loading…
Reference in New Issue
Block a user