dont abort when (un)ticking labels with no entries shown
authorgc <gc>
Tue, 16 Oct 2007 19:55:07 +0000 (19:55 +0000)
committergc <gc>
Tue, 16 Oct 2007 19:55:07 +0000 (19:55 +0000)
bin/booh-classifier

index cfa5fbfa1c563c947f2e47ceb94a3cdeeb629fc1..6df92d83195e91c7e189ea504ce471fd3b0a7198 100644 (file)
@@ -412,6 +412,8 @@ class Entry
     end
 end
 
+$allentries = []
+
 class MainView < Gtk::DrawingArea
 
     @@borders_thickness = 5
@@ -1263,6 +1265,9 @@ def update_all_visibilities
         update_visibility(entry)
     }
     shown = $mainview.get_shown_entry
+    if shown.nil?
+        return
+    end
     while shown.button && ! shown.button.visible? && shown != $allentries.last
         shown = $allentries[$allentries.index(shown) + 1]
     end