Slight changes to make adding books more pleasant
authorFelix Bauckholt <felixbauckholt@gmail.com>
Sat, 19 Mar 2016 23:06:35 +0000 (19:06 -0400)
committerFelix Bauckholt <felixbauckholt@gmail.com>
Sat, 19 Mar 2016 23:06:35 +0000 (19:06 -0400)
library/interface/.browser.py.swp [deleted file]
library/interface/browser.py
library/interface/form.py

diff --git a/library/interface/.browser.py.swp b/library/interface/.browser.py.swp
deleted file mode 100644 (file)
index a9cee10..0000000
Binary files a/library/interface/.browser.py.swp and /dev/null differ
index 93d6577..e31cdd1 100644 (file)
@@ -336,7 +336,7 @@ class bookBrowser(browserWindow):
                   ('Authors',30,None),
                   ('Title',60,None)]
 
-    cs = [(' u', 'update'), (' d', 'delete selected'), (' c', 'categorize'), (' a', 'add selected to category')]
+    cs = [(' u', 'update'), (' d', 'delete selected'), (' c', 'categorize'), (' a', 'add selected to category'), (' r', 'refresh')]
 
 
     # redefinable functions
@@ -434,6 +434,9 @@ class bookBrowser(browserWindow):
         elif ch == 97: #a
             self.addBooksToCategory()
             self.refresh()
+        elif ch == 114: #r
+            self.refreshBooks()
+            self.refresh()
         if ch == 100:
             count=0
             for s in self.selected[0:self.hl-1]:
index 0cad7be..652f377 100644 (file)
@@ -305,13 +305,13 @@ class BookForm(FormWindow):
                 if book != {}:
                     self._set_entries(book)
                 self.refresh()
-                self._mv_focus(+7)
+                self._mv_focus(+12)
             if self.hl==1:          # lookup by lccn
                 book = self.lookup_lccn(self.entries[1].value)
                 if book != {}:
                     self._set_entries(book)
                 self.refresh()
-                self._mv_focus(+6)
+                self._mv_focus(+11)
         else:
             FormWindow.handle_input(self,ch)