Permalink
Browse files

expose full completion data to extraKeys in show hints.

  • Loading branch information...
1 parent 53df110 commit 17734419506fcac52a5f380f54287c590d32e8cc @Carreau Carreau committed with marijnh Feb 2, 2014
Showing with 7 additions and 2 deletions.
  1. +2 −1 addon/hint/show-hint.js
  2. +5 −1 doc/manual.html
@@ -225,7 +225,8 @@
menuSize: function() { return widget.screenAmount(); },
length: completions.length,
close: function() { completion.close(); },
- pick: function() { widget.pick(); }
+ pick: function() { widget.pick(); },
+ data: data
}));
if (options.closeOnUnfocus !== false) {
View
@@ -2110,7 +2110,11 @@ <h3 id="api_static">Static properties</h3>
has <code>moveFocus(n)</code>, <code>setFocus(n)</code>, <code>pick()</code>,
and <code>close()</code> methods (see the source for details),
that can be used to change the focused element, pick the
- current element or close the menu.</dd>
+ current element or close the menu. Additionnaly <code>menuSize()</code>
+ can give you access to the size of the current dropdown menu,
+ <code>length</code> give you the number of availlable completions, and
+ <code>data</code> give you full access to the completion returned by the
+ hinting function.</dd>
<dt><code><strong>extraKeys</strong>: keymap</code></dt>
<dd>Like <code>customKeys</code> above, but the bindings will
be added to the set of default bindings, instead of replacing

0 comments on commit 1773441

Please sign in to comment.