vmail 0.6.8 → 0.6.9
Sign up to get free protection for your applications and to get access to all the features.
- data/README.markdown +1 -1
- data/lib/vmail.vim +25 -11
- data/lib/vmail/imap_client.rb +1 -1
- data/lib/vmail/version.rb +1 -1
- metadata +2 -2
data/README.markdown
CHANGED
@@ -152,7 +152,7 @@ To mark a message spam, put the cursor on it and type `,!`. This moves the
|
|
152
152
|
message to to the `spam` mailbox.
|
153
153
|
|
154
154
|
You can use range selections in the message list when you star, delete, mark as
|
155
|
-
spam, or archive. Use
|
155
|
+
spam, or archive. Use `v` to start marking a range of lines (the vertical
|
156
156
|
position of the cursor doesn't matter). Then type any of the above commands to
|
157
157
|
perform an action on all the messages you selected.
|
158
158
|
|
data/lib/vmail.vim
CHANGED
@@ -67,7 +67,7 @@ function! s:create_message_window()
|
|
67
67
|
close
|
68
68
|
endfunction
|
69
69
|
|
70
|
-
function! s:show_message()
|
70
|
+
function! s:show_message(stay_in_message_list)
|
71
71
|
let line = getline(line("."))
|
72
72
|
if match(line, '^> Load') != -1
|
73
73
|
setlocal modifiable
|
@@ -99,9 +99,11 @@ function! s:show_message()
|
|
99
99
|
" critical: don't call execute 'normal \<cr>'
|
100
100
|
" call feedkeys("<cr>")
|
101
101
|
1delete
|
102
|
-
normal 1
|
103
|
-
normal jk
|
104
102
|
setlocal nomodifiable
|
103
|
+
normal 1Gjk
|
104
|
+
if a:stay_in_message_list
|
105
|
+
call s:focus_list_window()
|
106
|
+
end
|
105
107
|
redraw
|
106
108
|
endfunction
|
107
109
|
|
@@ -178,6 +180,18 @@ function! s:focus_message_window()
|
|
178
180
|
endif
|
179
181
|
endfunction
|
180
182
|
|
183
|
+
func! s:close_message_window()
|
184
|
+
if winnr('$') > 1
|
185
|
+
close
|
186
|
+
else
|
187
|
+
call s:focus_list_window()
|
188
|
+
wincmd p
|
189
|
+
close
|
190
|
+
normal z.
|
191
|
+
endif
|
192
|
+
endfunc
|
193
|
+
|
194
|
+
|
181
195
|
" gets new messages since last update
|
182
196
|
function! s:update()
|
183
197
|
let command = s:update_command
|
@@ -655,7 +669,6 @@ func! s:show_help()
|
|
655
669
|
"exec "split " . helpfile
|
656
670
|
endfunc
|
657
671
|
|
658
|
-
|
659
672
|
" --------------------------------------------------------------------------------
|
660
673
|
" MAPPINGS
|
661
674
|
|
@@ -672,7 +685,7 @@ func! s:message_window_mappings()
|
|
672
685
|
nmap <silent> <buffer> <leader>k <c-k>
|
673
686
|
noremap <silent> <buffer> <Leader>c :call <SID>compose_message()<CR>
|
674
687
|
noremap <silent> <buffer> <Leader>h :call <SID>open_html_part()<CR><cr>
|
675
|
-
nnoremap <silent> <buffer> q :
|
688
|
+
nnoremap <silent> <buffer> q :call <SID>close_message_window()<cr>
|
676
689
|
|
677
690
|
nnoremap <silent> <buffer> <leader># :close<cr>:call <SID>focus_list_window()<cr>:call <SID>delete_messages("Deleted")<cr>
|
678
691
|
nnoremap <silent> <buffer> <leader>* :call <SID>focus_list_window()<cr>:call <SID>toggle_star()<cr>
|
@@ -692,8 +705,9 @@ func! s:message_window_mappings()
|
|
692
705
|
endfunc
|
693
706
|
|
694
707
|
func! s:message_list_window_mappings()
|
695
|
-
noremap <silent> <buffer> <cr> :call <SID>show_message()<CR>
|
696
|
-
noremap <silent> <buffer> <LeftMouse> :call <SID>show_message()<CR>
|
708
|
+
noremap <silent> <buffer> <cr> :call <SID>show_message(0)<CR>
|
709
|
+
noremap <silent> <buffer> <LeftMouse> :call <SID>show_message(0)<CR>
|
710
|
+
nnoremap <silent> <buffer> l :call <SID>show_message(1)<CR>
|
697
711
|
noremap <silent> <buffer> q :qal!<cr>
|
698
712
|
|
699
713
|
noremap <silent> <buffer> <leader>* :call <SID>toggle_star()<CR>
|
@@ -704,7 +718,7 @@ func! s:message_list_window_mappings()
|
|
704
718
|
noremap <silent> <buffer> <leader>! :call <SID>delete_messages("[Gmail]/Spam")<CR>
|
705
719
|
noremap <silent> <buffer> <leader>e :call <SID>archive_messages()<CR>
|
706
720
|
"open a link browser (os x)
|
707
|
-
"autocmd CursorMoved <buffer> call <SID>show_message()
|
721
|
+
"autocmd CursorMoved <buffer> call <SID>show_message(0)
|
708
722
|
noremap <silent> <buffer> <leader>vp :call <SID>append_messages_to_file()<CR>
|
709
723
|
noremap <silent> <buffer> u :call <SID>update()<CR>
|
710
724
|
noremap <silent> <buffer> <Leader>s :call <SID>search_query()<CR>
|
@@ -712,9 +726,9 @@ func! s:message_list_window_mappings()
|
|
712
726
|
noremap <silent> <buffer> <Leader>b :call <SID>move_to_mailbox(0)<CR>
|
713
727
|
noremap <silent> <buffer> <Leader>B :call <SID>move_to_mailbox(1)<CR>
|
714
728
|
noremap <silent> <buffer> <Leader>c :call <SID>compose_message()<CR>
|
715
|
-
noremap <silent> <buffer> <Leader>r :call <SID>show_message()<cr>:call <SID>compose_reply(0)<CR>
|
716
|
-
noremap <silent> <buffer> <Leader>a :call <SID>show_message()<cr>:call <SID>compose_reply(1)<CR>
|
717
|
-
noremap <silent> <buffer> <Leader>f :call <SID>show_message()<cr>:call <SID>compose_forward()<CR><cr>
|
729
|
+
noremap <silent> <buffer> <Leader>r :call <SID>show_message(0)<cr>:call <SID>compose_reply(0)<CR>
|
730
|
+
noremap <silent> <buffer> <Leader>a :call <SID>show_message(0)<cr>:call <SID>compose_reply(1)<CR>
|
731
|
+
noremap <silent> <buffer> <Leader>f :call <SID>show_message(0)<cr>:call <SID>compose_forward()<CR><cr>
|
718
732
|
noremap <silent> <buffer> <c-j> :call <SID>show_next_message_in_list()<cr>
|
719
733
|
noremap <silent> <buffer> <c-k> :call <SID>show_previous_message_in_list()<cr>
|
720
734
|
nnoremap <silent> <buffer> <Space> :call <SID>maximize_window()<cr>
|
data/lib/vmail/imap_client.rb
CHANGED
data/lib/vmail/version.rb
CHANGED