JAL-2091 disable pagination buttons during initialisation
authortcofoegbu <tcnofoegbu@dundee.ac.uk>
Tue, 3 May 2016 14:18:43 +0000 (15:18 +0100)
committertcofoegbu <tcnofoegbu@dundee.ac.uk>
Tue, 3 May 2016 14:18:43 +0000 (15:18 +0100)
src/jalview/fts/core/GFTSPanel.java

index 1c799aa..bc68667 100644 (file)
@@ -339,7 +339,6 @@ public abstract class GFTSPanel extends JPanel implements GFTSPanelI
         }
       }
     });
-
     btn_next_page.setEnabled(false);
     btn_next_page.setToolTipText(MessageManager
             .getString("label.next_page_tooltop"));
@@ -851,6 +850,10 @@ public abstract class GFTSPanel extends JPanel implements GFTSPanelI
     // System.out.println("page limit : " + pageLimit);
     setPrevPageButtonEnabled(false);
     setNextPageButtonEnabled(false);
+    if (resultSetCount == 0 && pageLimit == 0)
+    {
+      return;
+    }
     if (resultSetCount >= pageLimit)
     {
       setNextPageButtonEnabled(true);