Changeset 4054
- Timestamp:
- 03/19/08 04:38:16 (7 months ago)
- Location:
- Trunk/core
- Files:
-
- 5 modified
-
html/tiddlywiki.template.html (modified) (2 diffs)
-
js/Config.js (modified) (2 diffs)
-
js/Saving.js (modified) (6 diffs)
-
js/Wikifier.js (modified) (1 diff)
-
js/main.js (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
Trunk/core/html/tiddlywiki.template.html
r4017 r4054 2 2 <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> 3 3 <head> 4 <script type="text/javascript">4 <script id="versionArea" type="text/javascript"> 5 5 //<![CDATA[ 6 6 <!--@@version@@--> … … 89 89 <!--@@postbody@@--> 90 90 <!--POST-BODY-END--> 91 <script type="text/javascript">91 <script id="jsArea" type="text/javascript"> 92 92 //<![CDATA[ 93 93 <!--@@prejs@@--> 94 94 <!--@@js@@--> 95 95 <!--@@postjs@@--> 96 //--97 //-- End of scripts98 //--99 96 //]]> 100 97 </script> -
Trunk/core/js/Config.js
r3558 r4054 11 11 cascadeDepth: 5 // Depth of cascade animation 12 12 }; 13 14 // Hashmap of alternative parsers for the wikifier 15 config.parsers = {}; 13 16 14 17 // Adaptors … … 48 51 chkInsertTabs: false, 49 52 chkUsePreForStorage: true, // Whether to use <pre> format for storage 50 chkDisplay StartupTime: false,53 chkDisplayInstrumentation: false, 51 54 txtBackupFolder: "", 52 55 txtMainTab: "tabTimeline", -
Trunk/core/js/Saving.js
r4043 r4054 95 95 return; 96 96 clearMessage(); 97 // Get the URL of the document 97 var t0 = new Date(); 98 //# Get the URL of the document 98 99 var originalPath = document.location.toString(); 99 // Check we were loaded from a file URL100 //# Check we were loaded from a file URL 100 101 if(originalPath.substr(0,5) != "file:") { 101 102 alert(config.messages.notFileUrlError); … … 105 106 } 106 107 var localPath = getLocalPath(originalPath); 107 // Load the original file108 //# Load the original file 108 109 var original = loadFile(localPath); 109 110 if(original == null) { … … 113 114 return; 114 115 } 115 // Locate the storeArea div's116 //# Locate the storeArea div's 116 117 var posDiv = locateStoreArea(original); 117 118 if(!posDiv) { … … 123 124 saveEmpty(localPath,original,posDiv); 124 125 saveMain(localPath,original,posDiv); 126 if(config.options.chkDisplayInstrumentation) 127 displayMessage("saveChanges " + (new Date()-t0) + " ms"); 125 128 } 126 129 … … 135 138 else 136 139 alert(config.messages.backupFailed); 137 }138 }139 140 function saveRss(localPath)141 {142 //# Save Rss143 if(config.options.chkGenerateAnRssFeed) {144 var rssPath = localPath.substr(0,localPath.lastIndexOf(".")) + ".xml";145 var rssSave = saveFile(rssPath,convertUnicodeToUTF8(generateRss()));146 if(rssSave)147 displayMessage(config.messages.rssSaved,"file://" + rssPath);148 else149 alert(config.messages.rssFailed);150 140 } 151 141 } … … 186 176 } else { 187 177 alert(config.messages.mainFailed); 178 } 179 } 180 181 function saveRss(localPath) 182 { 183 //# Save Rss 184 if(config.options.chkGenerateAnRssFeed) { 185 var rssPath = localPath.substr(0,localPath.lastIndexOf(".")) + ".xml"; 186 if(saveFile(rssPath,convertUnicodeToUTF8(generateRss()))) 187 displayMessage(config.messages.rssSaved,"file://" + rssPath); 188 else 189 alert(config.messages.rssFailed); 188 190 } 189 191 } -
Trunk/core/js/Wikifier.js
r3449 r4054 35 35 function wikifyStatic(source,highlightRegExp,tiddler,format) 36 36 { 37 var e = createTiddlyElement(document.body," div");37 var e = createTiddlyElement(document.body,"pre"); 38 38 e.style.display = "none"; 39 39 var html = ""; -
Trunk/core/js/main.js
r3540 r4054 7 7 var story = null; // Main story 8 8 var formatter = null; // Default formatters for the wikifier 9 config.parsers = {}; // Hashmap of alternative parsers for the wikifier10 9 var anim = typeof Animator == "function" ? new Animator() : null; // Animation engine 11 10 var readOnly = false; // Whether we're in readonly mode … … 69 68 backstage.init(); 70 69 t10 = new Date(); 71 if(config.options.chkDisplay StartupTime) {70 if(config.options.chkDisplayInstrumentation) { 72 71 displayMessage("LoadShadows " + (t2-t1) + " ms"); 73 72 displayMessage("LoadFromDiv " + (t3-t2) + " ms");
