]> git.cworth.org Git - sup/blobdiff - lib/sup/modes/thread-index-mode.rb
Merge branch 'preemptive-loading' into next
[sup] / lib / sup / modes / thread-index-mode.rb
index 5038d29f308fb5a609c783add43e401d011b34a9..82f258b689681183614b65d6475829ba10d0563e 100644 (file)
@@ -77,8 +77,7 @@ EOS
     @last_load_more_size = nil
     to_load_more do |size|
       next if @last_load_more_size == 0
-      load_threads :num => 1, :background => false
-      load_threads :num => (size - 1),
+      load_threads :num => size,
                    :when_done => lambda { |num| @last_load_more_size = num }
     end
   end
@@ -630,6 +629,7 @@ EOS
         BufferManager.draw_screen
         last_update = Time.now
       end
+      ::Thread.pass
       break if @interrupt_search
     end
     @ts.threads.each { |th| th.labels.each { |l| LabelManager << l } }