gui: change name, author
[fanfix.git] / src / be / nikiroo / fanfix / reader / ui / GuiReader.java
index 02f153cdf82d47dc8f2486f7e3a72cff94a75903..7dc373c7c54aad8037d4ebcf92a42cd30db31a2e 100644 (file)
@@ -292,4 +292,38 @@ class GuiReader extends BasicReader {
                        Instance.getTraceHandler().error(e);
                }
        }
+
+       /**
+        * Change the title of the given {@link Story}.
+        * 
+        * @param luid
+        *            the luid of the {@link Story} to change
+        * @param newTitle
+        *            the new title
+        */
+       void changeTitle(String luid, String newTitle) {
+               try {
+                       cacheLib.changeTitle(luid, newTitle, null);
+               } catch (IOException e) {
+                       Instance.getTraceHandler().error(e);
+               }
+       }
+
+       /**
+        * Change the author of the given {@link Story}.
+        * <p>
+        * The author can be a new one, it needs not exist before hand.
+        * 
+        * @param luid
+        *            the luid of the {@link Story} to change
+        * @param newAuthor
+        *            the new author
+        */
+       void changeAuthor(String luid, String newAuthor) {
+               try {
+                       cacheLib.changeAuthor(luid, newAuthor, null);
+               } catch (IOException e) {
+                       Instance.getTraceHandler().error(e);
+               }
+       }
 }