1
0
mirror of https://github.com/SpaceVim/SpaceVim.git synced 2025-01-23 23:10:04 +08:00

Update java key bindings

This commit is contained in:
wsdjeg 2017-12-19 20:31:44 +08:00
parent 4c53a52611
commit 6a7c13dc2b
2 changed files with 37 additions and 21 deletions

View File

@ -96,31 +96,32 @@ function! s:language_specified_mappings() abort
\ 'Smart import class under cursor', 0) \ 'Smart import class under cursor', 0)
" Generate key bindings " Generate key bindings
call SpaceVim#mapping#space#langSPC('nmap', ['l','A'], let g:_spacevim_mappings_space.l.g = {'name' : '+Generate'}
call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 'A'],
\ '<Plug>(JavaComplete-Generate-Accessors)', \ '<Plug>(JavaComplete-Generate-Accessors)',
\ 'generate setter accessor', 0) \ 'generate setter accessor', 0)
call SpaceVim#mapping#space#langSPC('nmap', ['l','s'], call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 's'],
\ '<Plug>(JavaComplete-Generate-AccessorSetter)', \ '<Plug>(JavaComplete-Generate-AccessorSetter)',
\ 'generate setter accessor', 0) \ 'generate setter accessor', 0)
call SpaceVim#mapping#space#langSPC('nmap', ['l','g'], call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 'g'],
\ '<Plug>(JavaComplete-Generate-AccessorGetter)', \ '<Plug>(JavaComplete-Generate-AccessorGetter)',
\ 'generate getter accessor', 0) \ 'generate getter accessor', 0)
call SpaceVim#mapping#space#langSPC('nmap', ['l','a'], call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 'a'],
\ '<Plug>(JavaComplete-Generate-AccessorSetterGetter)', \ '<Plug>(JavaComplete-Generate-AccessorSetterGetter)',
\ 'generate setter and getter accessor', 0) \ 'generate setter and getter accessor', 0)
call SpaceVim#mapping#space#langSPC('nmap', ['l','M'], call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 'M'],
\ '<Plug>(JavaComplete-Generate-AbstractMethods)', \ '<Plug>(JavaComplete-Generate-AbstractMethods)',
\ 'Generate abstract methods', 0) \ 'Generate abstract methods', 0)
call SpaceVim#mapping#space#langSPC('nmap', ['l','c'], call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 'c'],
\ '<Plug>(JavaComplete-Generate-Constructor)', \ '<Plug>(JavaComplete-Generate-Constructor)',
\ 'Generate constructor', 0) \ 'Generate constructor', 0)
call SpaceVim#mapping#space#langSPC('nmap', ['l','C'], call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 'C'],
\ '<Plug>(JavaComplete-Generate-DefaultConstructor)', \ '<Plug>(JavaComplete-Generate-DefaultConstructor)',
\ 'Generate default constructor', 0) \ 'Generate default constructor', 0)
call SpaceVim#mapping#space#langSPC('nmap', ['l','eq'], call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 'e'],
\ '<Plug>(JavaComplete-Generate-EqualsAndHashCode)', \ '<Plug>(JavaComplete-Generate-EqualsAndHashCode)',
\ 'Generate equals functions', 0) \ 'Generate equals functions', 0)
call SpaceVim#mapping#space#langSPC('nmap', ['l','ts'], call SpaceVim#mapping#space#langSPC('nmap', ['l', 'g', 't'],
\ '<Plug>(JavaComplete-Generate-ToString)', \ '<Plug>(JavaComplete-Generate-ToString)',
\ 'Generate toString function', 0) \ 'Generate toString function', 0)

View File

@ -37,18 +37,19 @@ CONTENTS *SpaceVim-contents*
14. lang#java.................................|SpaceVim-layer-lang-java| 14. lang#java.................................|SpaceVim-layer-lang-java|
15. lang#julia...............................|SpaceVim-layer-lang-julia| 15. lang#julia...............................|SpaceVim-layer-lang-julia|
16. lang#kotlin.............................|SpaceVim-layer-lang-kotlin| 16. lang#kotlin.............................|SpaceVim-layer-lang-kotlin|
17. lang#ocaml...............................|SpaceVim-layer-lang-ocaml| 17. lang#lua...................................|SpaceVim-layer-lang-lua|
18. lang#php...................................|SpaceVim-layer-lang-php| 18. lang#ocaml...............................|SpaceVim-layer-lang-ocaml|
19. lang#pony.................................|SpaceVim-layer-lang-pony| 19. lang#php...................................|SpaceVim-layer-lang-php|
20. lang#puppet.............................|SpaceVim-layer-lang-puppet| 20. lang#pony.................................|SpaceVim-layer-lang-pony|
21. lang#python.............................|SpaceVim-layer-lang-python| 21. lang#puppet.............................|SpaceVim-layer-lang-puppet|
22. lang#rust.................................|SpaceVim-layer-lang-rust| 22. lang#python.............................|SpaceVim-layer-lang-python|
23. lang#scala...............................|SpaceVim-layer-lang-scala| 23. lang#rust.................................|SpaceVim-layer-lang-rust|
24. lang#tmux.................................|SpaceVim-layer-lang-tmux| 24. lang#scala...............................|SpaceVim-layer-lang-scala|
25. lang#xml...................................|SpaceVim-layer-lang-xml| 25. lang#tmux.................................|SpaceVim-layer-lang-tmux|
26. operator...................................|SpaceVim-layer-operator| 26. lang#xml...................................|SpaceVim-layer-lang-xml|
27. shell.........................................|SpaceVim-layer-shell| 27. operator...................................|SpaceVim-layer-operator|
28. tmux...........................................|SpaceVim-layer-tmux| 28. shell.........................................|SpaceVim-layer-shell|
29. tmux...........................................|SpaceVim-layer-tmux|
6. API........................................................|SpaceVim-api| 6. API........................................................|SpaceVim-api|
1. cmdlinemenu................................|SpaceVim-api-cmdlinemenu| 1. cmdlinemenu................................|SpaceVim-api-cmdlinemenu|
2. data#list....................................|SpaceVim-api-data-list| 2. data#list....................................|SpaceVim-api-data-list|
@ -898,6 +899,20 @@ LANG#KOTLIN *SpaceVim-layer-lang-kotlin*
This layer is for kotlin development. This layer is for kotlin development.
==============================================================================
LANG#LUA *SpaceVim-layer-lang-lua*
This layer includes utilities and language-specific mappings for lua
development.
MAPPINGS
>
Mode Key Function
---------------------------------------------
normal SPC l r lua run
<
============================================================================== ==============================================================================
LANG#OCAML *SpaceVim-layer-lang-ocaml* LANG#OCAML *SpaceVim-layer-lang-ocaml*