diff --git a/src/MacVim/MMBackend.m b/src/MacVim/MMBackend.m index 5e0bc51d66..499e0b4a48 100644 --- a/src/MacVim/MMBackend.m +++ b/src/MacVim/MMBackend.m @@ -633,6 +633,7 @@ - (void)update while (CFRunLoopRunInMode(kCFRunLoopDefaultMode, 0, true) == kCFRunLoopRunHandledSource) ; // do nothing + [self processInputQueue]; } - (void)flushQueue:(BOOL)force @@ -729,8 +730,7 @@ - (BOOL)waitForInput:(int)milliseconds // The above calls may have placed messages on the input queue so process // it now. This call may enter a blocking loop. - if ([inputQueue count] > 0) - [self processInputQueue]; + [self processInputQueue]; return inputReceived; } diff --git a/src/MacVim/gui_macvim.m b/src/MacVim/gui_macvim.m index a165723dd4..a93566e837 100644 --- a/src/MacVim/gui_macvim.m +++ b/src/MacVim/gui_macvim.m @@ -347,12 +347,19 @@ CFAbsoluteTime nowTime = CFAbsoluteTimeGetCurrent(); if (nowTime - lastTime > 1.0 / 30) { - [[MMBackend sharedInstance] update]; + gui_macvim_update(); lastTime = nowTime; } } + void +gui_macvim_update(void) +{ + [[MMBackend sharedInstance] update]; +} + + /* Flush any output to the screen */ void gui_mch_flush(void) diff --git a/src/proto/gui_macvim.pro b/src/proto/gui_macvim.pro index e6365688f1..38eafadb4e 100644 --- a/src/proto/gui_macvim.pro +++ b/src/proto/gui_macvim.pro @@ -17,6 +17,8 @@ gui_mch_open(void); void gui_mch_update(void); void +gui_macvim_update(void); + void gui_mch_flush(void); void gui_macvim_flush(void); diff --git a/src/testdir/runtest.vim b/src/testdir/runtest.vim index af8174e436..1ca17cb3df 100644 --- a/src/testdir/runtest.vim +++ b/src/testdir/runtest.vim @@ -432,7 +432,7 @@ for g:testfunc in sort(s:tests) " tests pending for now before a more proper fix is implemented. call extend(s:messages, [ \ 'Flaky test failed too often, giving up', - \ 'MacVim marked ' . s:test . ' as pending', + \ 'MacVim marked ' . g:testfunc . ' as pending', \ ]) let v:errors = [] endif diff --git a/src/testdir/test_netbeans.vim b/src/testdir/test_netbeans.vim index a0606fcf06..e9f6dcce4b 100644 --- a/src/testdir/test_netbeans.vim +++ b/src/testdir/test_netbeans.vim @@ -609,7 +609,7 @@ func Nb_basic(port) " detach call appendbufline(cmdbufnr, '$', 'detach_Test') - call WaitFor('len(readfile("Xnetbeans")) >= (g:last + 6)') + call WaitFor('len(readfile("Xnetbeans")) >= (g:last + 8)') let l = readfile('Xnetbeans') call assert_equal('0:disconnect=91', l[-1]) diff --git a/src/ui.c b/src/ui.c index 9675e68474..8ed03e9b66 100644 --- a/src/ui.c +++ b/src/ui.c @@ -707,7 +707,14 @@ ui_breakcheck_force(int force) #ifdef FEAT_GUI if (gui.in_use) + { +# ifdef FEAT_GUI_MACVIM + if (force) + gui_macvim_update(); + else +# endif gui_mch_update(); + } else #endif mch_breakcheck(force);