OSDN Git Service

Change generation of files/paths in logs dir to use FileManager
authorNick Clarke <memorius@gmail.com>
Mon, 19 Jul 2010 15:22:40 +0000 (03:22 +1200)
committerRandy Baumgarte <randy@fbn.cx>
Fri, 23 Jul 2010 09:31:06 +0000 (05:31 -0400)
src/cx/fbn/nevernote/utilities/ApplicationLogger.java
src/cx/fbn/nevernote/utilities/OutStream.java

index 5a4a158..e6ef930 100644 (file)
@@ -42,7 +42,7 @@ public class ApplicationLogger {
     public ApplicationLogger(String name){
 //        logText = new ArrayList<String>();
         try {
-                       fileStream = new FileOutputStream(Global.currentDir+"logs/"+name);
+                       fileStream = new FileOutputStream(Global.getFileManager().getLogsDirFile(name));
                } catch (FileNotFoundException e) {
                        // TODO Auto-generated catch block
                        e.printStackTrace();
index 81dbd64..36cdd9b 100644 (file)
@@ -42,7 +42,7 @@ public class OutStream extends FilterOutputStream {
                super(out);\r
                buffer = new ArrayList<String>();\r
                \r
-               file = new File(Global.getDirectoryPath()+"logs"+File.separatorChar +name);\r
+               file = Global.getFileManager().getLogsDirFile(name);\r
                try {\r
                        fos = new FileOutputStream(file);\r
                        dos = new DataOutputStream(fos);\r