• R/O
  • SSH
  • HTTPS

tortoisesvn: Commit


Commit MetaInfo

Révision27268 (tree)
l'heure2016-04-11 17:13:04
Auteurxhmikosr

Message de Log

contrib/*.js: minor tweaks and consistency changes.

Change Summary

Modification

--- trunk/contrib/ScreenReaderScripts/ReCompileJAWSScriptsWC.js (revision 27267)
+++ trunk/contrib/ScreenReaderScripts/ReCompileJAWSScriptsWC.js (revision 27268)
@@ -41,6 +41,6 @@
4141 SAPI5Object.Speak(WorkingFolder + ArgumentsObject.Item(4), 0);
4242 PathParts = WScript.ScriptFullName.split("\\");
4343 Version = PathParts[PathParts.length - 4];
44-PathToSCompile = "\"" + ShellObject.RegRead ("HKLM\\SOFTWARE\\Freedom Scientific\\JAWS\\" + Version + "\\Target") + "scompile.exe\"";
44+PathToSCompile = "\"" + ShellObject.RegRead("HKLM\\SOFTWARE\\Freedom Scientific\\JAWS\\" + Version + "\\Target") + "scompile.exe\"";
4545 ShellObject.Run(PathToSCompile + ScriptName, 0, true);
4646 SAPI5Object.Speak(Finished, 0);
--- trunk/contrib/diff-scripts/diff-doc.js (revision 27267)
+++ trunk/contrib/diff-scripts/diff-doc.js (revision 27268)
@@ -2,7 +2,7 @@
22 //
33 // TortoiseSVN Diff script for Word Doc files
44 //
5-// Copyright (C) 2004-2008, 2011-2015 the TortoiseSVN team
5+// Copyright (C) 2004-2008, 2011-2016 the TortoiseSVN team
66 // This file is distributed under the same license as TortoiseSVN
77 //
88 // Last commit by:
@@ -52,13 +52,13 @@
5252
5353 if (!objScript.FileExists(sBaseDoc))
5454 {
55- WScript.Echo("File " + sBaseDoc + " does not exist. Cannot compare the documents.");
55+ WScript.Echo("File " + sBaseDoc + " does not exist. Cannot compare the documents.");
5656 WScript.Quit(1);
5757 }
5858
5959 if (!objScript.FileExists(sNewDoc))
6060 {
61- WScript.Echo("File " + sNewDoc + " does not exist. Cannot compare the documents.");
61+ WScript.Echo("File " + sNewDoc + " does not exist. Cannot compare the documents.");
6262 WScript.Quit(1);
6363 }
6464
@@ -77,7 +77,7 @@
7777 }
7878 catch (e)
7979 {
80- // before giving up, try with OpenOffice
80+ // Before giving up, try with OpenOffice
8181 var OO;
8282 try
8383 {
@@ -88,17 +88,17 @@
8888 WScript.Echo("You must have Microsoft Word or OpenOffice installed to perform this operation.");
8989 WScript.Quit(1);
9090 }
91- // yes, OO is installed - do the diff with that one instead
91+ // Yes, OO is installed - do the diff with that one instead
9292 var objFile = objScript.GetFile(sNewDoc);
9393 if ((objFile.Attributes & 1) === 1)
9494 {
95- // reset the readonly attribute
95+ // Reset the readonly attribute
9696 objFile.Attributes &= ~1;
9797 }
98- //Create the DesktopSet
98+ // Create the DesktopSet
9999 var objDesktop = OO.createInstance("com.sun.star.frame.Desktop");
100100 var objUriTranslator = OO.createInstance("com.sun.star.uri.ExternalUriReferenceTranslator");
101- //Adjust the paths for OO
101+ // Adjust the paths for OO
102102 sBaseDoc = sBaseDoc.replace(/\\/g, "/");
103103 sBaseDoc = sBaseDoc.replace(/:/g, "|");
104104 sBaseDoc = sBaseDoc.replace(/ /g, "%20");
@@ -112,7 +112,7 @@
112112 sNewDoc = "file:///" + sNewDoc;
113113 sNewDoc = objUriTranslator.translateToInternal(sNewDoc);
114114
115- //Open the %base document
115+ // Open the %base document
116116 var oPropertyValue = [];
117117 oPropertyValue[0] = OO.Bridge_GetStruct("com.sun.star.beans.PropertyValue");
118118 oPropertyValue[0].Name = "ShowTrackedChanges";
@@ -119,12 +119,12 @@
119119 oPropertyValue[0].Value = true;
120120 objDesktop.loadComponentFromURL(sNewDoc, "_blank", 0, oPropertyValue);
121121
122- //Set the frame
122+ // Set the frame
123123 var Frame = objDesktop.getCurrentFrame();
124124
125125 var dispatcher = OO.CreateInstance("com.sun.star.frame.DispatchHelper");
126126
127- //Execute the comparison
127+ // Execute the comparison
128128 dispatcher.executeDispatch(Frame, ".uno:ShowTrackedChanges", "", 0, oPropertyValue);
129129 oPropertyValue[0].Name = "URL";
130130 oPropertyValue[0].Value = sBaseDoc;
@@ -151,7 +151,7 @@
151151 {
152152 try
153153 {
154- // open empty document to prevent bug where first Open() call fails
154+ // Open empty document to prevent bug where first Open() call fails
155155 word.Documents.Add();
156156 destination = word.Documents.Open(sNewDoc, true, parseInt(word.Version, 10) < vOffice2013);
157157 }
--- trunk/contrib/diff-scripts/diff-ppt.js (revision 27267)
+++ trunk/contrib/diff-scripts/diff-ppt.js (revision 27268)
@@ -59,13 +59,13 @@
5959
6060 if (!objScript.FileExists(sBasePpt))
6161 {
62- WScript.Echo("File " + sBasePpt + " does not exist. Cannot compare the presentations.");
62+ WScript.Echo("File " + sBasePpt + " does not exist. Cannot compare the presentations.");
6363 WScript.Quit(1);
6464 }
6565
6666 if (!objScript.FileExists(sNewPpt))
6767 {
68- WScript.Echo("File " + sNewPpt + " does not exist. Cannot compare the presentations.");
68+ WScript.Echo("File " + sNewPpt + " does not exist. Cannot compare the presentations.");
6969 WScript.Quit(1);
7070 }
7171
--- trunk/contrib/diff-scripts/diff-xls.js (revision 27267)
+++ trunk/contrib/diff-scripts/diff-xls.js (revision 27268)
@@ -2,7 +2,7 @@
22 //
33 // TortoiseSVN Diff script for Excel files
44 //
5-// Copyright (C) 2004-2008, 2012-2015 the TortoiseSVN team
5+// Copyright (C) 2004-2008, 2012-2016 the TortoiseSVN team
66 // This file is distributed under the same license as TortoiseSVN
77 //
88 // Last commit by:
@@ -161,7 +161,7 @@
161161 objDummyWorksheet.Visible = true;
162162 if (fExcelVersion >= vOffice2003)
163163 {
164- objDummyWorksheet.Tab.ColorIndex = 16; // 16:Dark gray RGB(128,128,128)
164+ objDummyWorksheet.Tab.ColorIndex = 16; // 16: Dark gray RGB(128,128,128)
165165 }
166166 }
167167
@@ -230,8 +230,8 @@
230230
231231 // Unhide the Worksheet if it is hidden.
232232 // This also sets color to the tab, if Office2003 or later.
233-// - 46(Orange) : Hidden Worksheet
234-// - xlNone(default) : Not hidden Worksheet
233+// - 46 (Orange) : Hidden Worksheet
234+// - xlNone (default) : Not hidden Worksheet
235235 function UnhideWorksheet(objWorksheet)
236236 {
237237 if (objWorksheet.Visible)
@@ -298,16 +298,18 @@
298298 // To avoid make huge message dialog, this limits message count to show.
299299 function ShowWarning()
300300 {
301- if (aWarningMessages.length === 0)
301+ var aWarningMessagesLength = aWarningMessages.length;
302+ if (aWarningMessagesLength === 0)
302303 {
303304 return;
304305 }
306+
305307 var sMessage = "The following warnings occurred while processing.\n";
306- for (var j = 0; j < aWarningMessages.length; j++)
308+ for (var j = 0; j < aWarningMessagesLength; j++)
307309 {
308310 if (j >= 10)
309311 {
310- sMessage += "... And more " + (aWarningMessages.length - j) + " messages";
312+ sMessage += "... And more " + (aWarningMessagesLength - j) + " messages";
311313 break;
312314 }
313315 sMessage += "[" + (j + 1) + "] " + aWarningMessages[j] + "\n";
--- trunk/contrib/diff-scripts/merge-doc.js (revision 27267)
+++ trunk/contrib/diff-scripts/merge-doc.js (revision 27268)
@@ -2,7 +2,7 @@
22 //
33 // TortoiseSVN Merge script for Word Doc files
44 //
5-// Copyright (C) 2004-2008, 2011-2015 the TortoiseSVN team
5+// Copyright (C) 2004-2008, 2011-2016 the TortoiseSVN team
66 // This file is distributed under the same license as TortoiseSVN
77 //
88 // Last commit by:
@@ -53,13 +53,13 @@
5353
5454 if (!objScript.FileExists(sTheirDoc))
5555 {
56- WScript.Echo("File " + sTheirDoc + " does not exist. Cannot compare the documents.", vbExclamation, "File not found");
56+ WScript.Echo("File " + sTheirDoc + " does not exist. Cannot compare the documents.", vbExclamation, "File not found");
5757 WScript.Quit(1);
5858 }
5959
6060 if (!objScript.FileExists(sMergedDoc))
6161 {
62- WScript.Echo("File " + sMergedDoc + " does not exist. Cannot compare the documents.", vbExclamation, "File not found");
62+ WScript.Echo("File " + sMergedDoc + " does not exist. Cannot compare the documents.", vbExclamation, "File not found");
6363 WScript.Quit(1);
6464 }
6565
@@ -95,8 +95,9 @@
9595 }
9696 else
9797 {
98- //2010 - handle slightly differently as the basic merge isn't that good
99- //note this is designed specifically for svn 3 way merges, during the commit conflict resolution process
98+ // 2010 - handle slightly differently as the basic merge isn't that good.
99+ // Note this is designed specifically for SVN 3 way merges,
100+ // during the commit conflict resolution process
100101 baseDoc = word.Documents.Open(sBaseDoc);
101102 myDoc = word.Documents.Open(sMyDoc);
102103
Afficher sur ancien navigateur de dépôt.