Skip to content

Commit

Permalink
Merge pull request #45 from jerone/issues/40-commands
Browse files Browse the repository at this point in the history
🐛 Renamed commands. Fixes #40
  • Loading branch information
jerone committed May 26, 2015
2 parents d0a8cd8 + f379753 commit 8aa8c01
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 12 deletions.
8 changes: 8 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,14 @@ The remaining properties `tooltip`, `iconset` (defaults `Octicons`), `data` and
* [Ionicons](http://ionicons.com/)
* [FontAwesome](http://fortawesome.github.io/Font-Awesome/)

## Supported commands

* `tool-bar:toggle`
* `tool-bar:position-top`
* `tool-bar:position-right`
* `tool-bar:position-bottom`
* `tool-bar:position-left`

## Authors

* [Wojtek Siudzinski](http://suda.pl)
Expand Down
8 changes: 4 additions & 4 deletions lib/tool-bar-view.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -31,16 +31,16 @@ module.exports = class ToolBarView extends View
@subscriptions = new CompositeDisposable
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:toggle', =>
@toggle()
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:position:top', =>
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:position-top', =>
@updatePosition 'Top'
atom.config.set 'tool-bar.position', 'Top'
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:position:right', =>
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:position-right', =>
@updatePosition 'Right'
atom.config.set 'tool-bar.position', 'Right'
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:position:bottom', =>
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:position-bottom', =>
@updatePosition 'Bottom'
atom.config.set 'tool-bar.position', 'Bottom'
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:position:left', =>
@subscriptions.add atom.commands.add 'atom-workspace', 'tool-bar:position-left', =>
@updatePosition 'Left'
atom.config.set 'tool-bar.position', 'Left'

Expand Down
16 changes: 8 additions & 8 deletions menus/tool-bar.cson
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ menu: [
{
label: '&Position',
submenu: [
{ label: 'Top', command: 'tool-bar:position:top', type: 'radio' }
{ label: 'Right', command: 'tool-bar:position:right', type: 'radio' }
{ label: 'Bottom', command: 'tool-bar:position:bottom', type: 'radio' }
{ label: 'Left', command: 'tool-bar:position:left', type: 'radio' }
{ label: 'Top', command: 'tool-bar:position-top', type: 'radio' }
{ label: 'Right', command: 'tool-bar:position-right', type: 'radio' }
{ label: 'Bottom', command: 'tool-bar:position-bottom', type: 'radio' }
{ label: 'Left', command: 'tool-bar:position-left', type: 'radio' }
]
}
]
Expand All @@ -26,10 +26,10 @@ menu: [
{
label: '&Position',
submenu: [
{ label: 'Top', command: 'tool-bar:position:top' }
{ label: 'Right', command: 'tool-bar:position:right' }
{ label: 'Bottom', command: 'tool-bar:position:bottom' }
{ label: 'Left', command: 'tool-bar:position:left' }
{ label: 'Top', command: 'tool-bar:position-top' }
{ label: 'Right', command: 'tool-bar:position-right' }
{ label: 'Bottom', command: 'tool-bar:position-bottom' }
{ label: 'Left', command: 'tool-bar:position-left' }
]
}
]
Expand Down

0 comments on commit 8aa8c01

Please sign in to comment.