mirror of
https://github.com/atom/atom.git
synced 2026-02-16 01:25:13 -05:00
Add support for keyBindingTarget to TooltipManager::add
This commit is contained in:
@@ -15,10 +15,9 @@ class TooltipManager
|
||||
add: (target, options) ->
|
||||
requireBootstrapTooltip()
|
||||
|
||||
{keyBindingCommand} = options
|
||||
{keyBindingCommand, keyBindingTarget} = options
|
||||
|
||||
if keyBindingCommand?
|
||||
keyBindingTarget = target unless typeof target is 'string'
|
||||
bindings = atom.keymaps.findKeyBindings(command: keyBindingCommand, target: keyBindingTarget)
|
||||
if options.title?
|
||||
options.title += " " + getKeystroke(bindings)
|
||||
|
||||
Reference in New Issue
Block a user