OSDN Git Service

Fix translations directory to match source and fix note title sql problem.
authorRandy Baumgarte <randy@fbn.cx>
Sun, 3 Oct 2010 15:36:23 +0000 (11:36 -0400)
committerRandy Baumgarte <randy@fbn.cx>
Sun, 3 Oct 2010 15:37:48 +0000 (11:37 -0400)
src/cx/fbn/nevernote/config/FileManager.java
src/cx/fbn/nevernote/sql/NoteTable.java

index cff1b21..73c1054 100644 (file)
@@ -77,7 +77,7 @@ public class FileManager {
         xmlDir = new File(programDir, "xml");
         checkExistingReadableDir(xmlDir);
 
-        translateDir = new File(programDir, "translate");
+        translateDir = new File(programDir, "translations");
         checkExistingReadableDir(translateDir);
         translateDirPath= slashTerminatePath(translateDir.getPath());
 
index 4f89d08..0269fdb 100644 (file)
@@ -1022,7 +1022,9 @@ public class NoteTable {
                List<Pair<String,Integer>> returnValue = new ArrayList<Pair<String,Integer>>();\r
         NSqlQuery query = new NSqlQuery(db.getConnection());\r
                \r
-               if (!query.exec("Select titleColor from Note where titleColor != -1 and guid=:guid"))\r
+        query.prepare("Select titleColor from Note where titleColor != -1 and guid=:guid");\r
+        query.bindValue(":guid", guid);\r
+               if (!query.exec())\r
                        logger.log(logger.EXTREME, "Note SQL retrieve has failed on getNoteTitleColor(guid).");\r
 \r
                Integer color = -1;\r