Browse Source

Actually attach the completer

Steven Silvester 8 years ago
parent
commit
cc9855d146
2 changed files with 6 additions and 0 deletions
  1. 5 0
      src/console/panel.ts
  2. 1 0
      src/notebook/notebook/panel.ts

+ 5 - 0
src/console/panel.ts

@@ -17,6 +17,10 @@ import {
   Panel
 } from 'phosphor/lib/ui/panel';
 
+import {
+  Widget
+} from 'phosphor/lib/ui/widget';
+
 import {
   IEditorMimeTypeService, CodeEditor
 } from '../codeeditor';
@@ -81,6 +85,7 @@ class ConsolePanel extends Panel {
 
     // Set the completer widget's anchor node to peg its position.
     this._completer.anchor = this.node;
+    Widget.attach(this._completer, document.body);
 
     // Instantiate the completer handler.
     this._completerHandler = factory.createCompleterHandler({

+ 1 - 0
src/notebook/notebook/panel.ts

@@ -129,6 +129,7 @@ class NotebookPanel extends Widget {
 
     // Set the completer widget's anchor node to peg its position.
     this._completer.anchor = this.notebook.node;
+    Widget.attach(this._completer, document.body);
 
     // Instantiate the completer handler.
     this._completerHandler = factory.createCompleterHandler({