This commit was manufactured by cvs2svn to create branch

'MOZILLA_1_8_BRANCH'.

git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@201449 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
(no author)
2006-07-02 01:56:02 +00:00
parent 53ea24b301
commit 706b40cb44
6 changed files with 1105 additions and 0 deletions

View File

@@ -0,0 +1,294 @@
/* XPM */
static char *pixmap[] = {
/* width height ncols cpp */
"32 32 256 2",
/* Colors */
"00 c #F4CC53",
"01 c #5A7B9C",
"02 c #C99165",
"03 c #87ADD6",
"04 c #90542C",
"05 c #8498B9",
"06 c #FFF9EF",
"07 c #EAEAEA",
"08 c #E88E37",
"09 c #B7C8CF",
"0A c #111111",
"0B c #253546",
"0C c #FFDB6C",
"0D c #87744E",
"0E c #4D5267",
"0F c #6C94BD",
"10 c #435A73",
"11 c #CFD6E4",
"12 c #D5CBBF",
"13 c #52637B",
"14 c #B2734B",
"15 c #4E4A43",
"16 c #272219",
"17 c #36475A",
"18 c #FEEE90",
"19 c #82A3C4",
"1A c #B7B7B7",
"1B c #7A9CC3",
"1C c #7E93A6",
"1D c #53738D",
"1E c #4C4C4C",
"1F c #63738C",
"20 c #9DB4C4",
"21 c #5B6C7C",
"22 c #B2BDCC",
"23 c #6C859D",
"24 c #FFC667",
"25 c #FFFEFD",
"26 c #7295BD",
"27 c #8E9AA5",
"28 c #71889E",
"29 c #FFFDFA",
"2A c #FFFCF6",
"2B c #F3F9F8",
"2C c #353838",
"2D c #536A7B",
"2E c #728EA6",
"2F c #19222A",
"30 c #597A96",
"31 c #5A6B84",
"32 c #D6DEE7",
"33 c #8696A5",
"34 c #577594",
"35 c #354A63",
"36 c #E2BD79",
"37 c #FFC658",
"38 c #C3A172",
"39 c #66697B",
"3A c #7D3B19",
"3B c #897562",
"3C c #B7B1AC",
"3D c #7C848A",
"3E c #62819F",
"3F c #252C35",
"40 c #FFEB8F",
"41 c #B6C7D7",
"42 c #6985A1",
"43 c #4B6B84",
"44 c #7097B7",
"45 c #526987",
"46 c #F8AC3F",
"47 c #535668",
"48 c #637E9A",
"49 c #8F866B",
"4A c #4A637B",
"4B c #101824",
"4C c #97A1AB",
"4D c #526473",
"4E c #46423D",
"4F c #F2B142",
"50 c #BD6329",
"51 c #8E9CA8",
"52 c #8CA5C6",
"53 c #827361",
"54 c #84A5CE",
"55 c #6B94B5",
"56 c #84B5D6",
"57 c #739CC6",
"58 c #73A5CE",
"59 c #EFF7F7",
"5A c #638CB5",
"5B c #707070",
"5C c #6384A5",
"5D c #64819F",
"5E c #749CBC",
"5F c #6384AD",
"60 c #6B8CB5",
"61 c #526B8C",
"62 c #607F9E",
"63 c #786747",
"64 c #8F7B54",
"65 c #B0B0B0",
"66 c #62553C",
"67 c #352F22",
"68 c #FFF5E2",
"69 c #FFF3DD",
"6A c #7BA5CE",
"6B c #F0F7F7",
"6C c #FFF7E8",
"6D c #FFF2DA",
"6E c #4E4330",
"6F c #39526B",
"70 c #7394B5",
"71 c #4A6384",
"72 c #638CAD",
"73 c #7E4321",
"74 c #909DA8",
"75 c #778CA0",
"76 c #CE7329",
"77 c #56575E",
"78 c #94C6D6",
"79 c #485E76",
"7A c #5A7394",
"7B c #8CBDD6",
"7C c #4A4F64",
"7D c #DE8734",
"7E c #F5FAF9",
"7F c #081018",
"80 c #B9B9B6",
"81 c #48463F",
"82 c #A5B5C6",
"83 c #E7EFEF",
"84 c #94B5D6",
"85 c #8CB5D6",
"86 c #88909B",
"87 c #9CB5CE",
"88 c #5A84A5",
"89 c #161514",
"8A c #FFFAF2",
"8B c #FFF28B",
"8C c #7BADD6",
"8D c #4A6373",
"8E c #CBC7C4",
"8F c #B9B5B0",
"90 c #C6C6C6",
"91 c #C86934",
"92 c #FFFBF4",
"93 c #6C849C",
"94 c #8E7F63",
"95 c #7BA5C6",
"96 c #F9DF73",
"97 c #100C08",
"98 c #EAA840",
"99 c #000818",
"9A c #3E3E40",
"9B c #80745C",
"9C c #101818",
"9D c #D6EFFF",
"9E c #959794",
"9F c #493E27",
"A0 c #617D91",
"A1 c #F2AD5D",
"A2 c #FFC25F",
"A3 c #A5C6E7",
"A4 c #A0B4C9",
"A5 c #93ACC7",
"A6 c #F9A850",
"A7 c #BD8A68",
"A8 c #B18962",
"A9 c #B18562",
"AA c #A5A294",
"AB c #AEA99E",
"AC c #67788F",
"AD c #FFC34F",
"AE c #EB9743",
"AF c #B3B5B4",
"B0 c #BFC8CD",
"B1 c #95A3B8",
"B2 c #758BA0",
"B3 c #FFF084",
"B4 c #5A7384",
"B5 c #9EA6AD",
"B6 c #F0F0F7",
"B7 c #EAA83F",
"B8 c #979CA4",
"B9 c #B7B6B1",
"BA c #FFDC77",
"BB c #EEA04E",
"BC c #9097A2",
"BD c #89A0B7",
"BE c #69839C",
"BF c #81A1BB",
"C0 c #A5C6D6",
"C1 c #D88952",
"C2 c #EFF3F2",
"C3 c #E9F0F0",
"C4 c #CF7A42",
"C5 c #A5BDD6",
"C6 c #BDE7E7",
"C7 c #FBB360",
"C8 c #FFDD7A",
"C9 c #424A52",
"CA c #9CC6F7",
"CB c #FFDD82",
"CC c #C0BDB8",
"CD c #6F8096",
"CE c #FFE87F",
"CF c #ADCEE7",
"D0 c #D1D8D8",
"D1 c #F1F8F8",
"D2 c #F8A147",
"D3 c #E2E2E2",
"D4 c #F89E40",
"D5 c #FFDF70",
"D6 c #8EA9BE",
"D7 c #D2C4B5",
"D8 c #D4D8E3",
"D9 c #FFD057",
"DA c #DEE7EF",
"DB c #ADBDCE",
"DC c #718897",
"DD c #9A7A65",
"DE c #9A6845",
"DF c #6D8398",
"E0 c #555247",
"E1 c #BDCEDE",
"E2 c #BFC9D4",
"E3 c #66869D",
"E4 c #6C7981",
"E5 c #5A5E70",
"E6 c #858B8E",
"E7 c #8B97A2",
"E8 c #757F80",
"E9 c #758498",
"EA c #738494",
"EB c #C25D2A",
"EC c #FFDA61",
"ED c #F8DD6B",
"EE c #F7DB65",
"EF c #FEBE4A",
"F0 c #7386A1",
"F1 c #BF5E2C",
"F2 c #A3916D",
"F3 c #A0613A",
"F4 c #738CAD",
"F5 c #AAAFB1",
"F6 c #FBFCFA",
"F7 c #465D6D",
"F8 c #D0C1A6",
"F9 c #6B8CAD",
"FA c #527394",
"FB c #A6CCFF",
"FC c #484C61",
"FD c #000000",
"FE c #FFFFFF",
".. s None c None",
"..C55CFA616161FAFAFAFAFAFAFAFAFAFAFAFAFAFAFAFAFA7A0101017A4A21..",
"CFC6F94A8D8D4D2D313131313131313131313131313131311F930552F44A0BC9",
"03A382FEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEFEEA0B17",
"5E30FE9D7B035857575757575757575757575E5E5E5E5E26555F0143FE84713F",
"55B4FEC0788C570F5555555555555555555555555555605A5C304310FE886F9C",
"702DFE788532DA59873259E1208359DB5F5F5F5F5C5C8801FA7110FE60FA0BFD",
"2613FE7B8C3259598232595909326B6B6262626262341D434A10FE0F5C357F..",
"1B13FE856A195959E32E6BB64242D1C342484848A0344579F7FE0F55104BFD..",
"9513FE566A87594130B1D11128222BE2757575E9DFAC214DFE0F55102FFD....",
"5413FE566A4159BD48222BB051D07EB04C4CB827863DE4FE1B44102FFD0A....",
"5413FE565811591C93D87EFCFC07FCFCCC39393CFCFCFEA5BF132FFD730A....",
"5413FE5658836BF0B2C2FC8E12FCF6124712D7FCF8FEFC20E42C977D730A....",
"5413FE56585A62BE1CB5FDFDFDFDFDFDFDFDFDFDFDFDFD9EE0164F7D730A....",
"5413FE56585A3E2333F5FDFBFBFBFBFBFBFBFBFBFBFBFD946E004F083A0A....",
"5413FE56585A3E2827AFFDFBFBFBFBFBFBFBFBFBFBFBFDF2ED00EF083A0A....",
"5413FE56585A5D28511AFD0E0E0E7C7C7C0E0E0E0E0EFD8B96ECAD083A89....",
"5413FE56585A5D287480FDFEFEFCFEFEFCFEFEE5FEFEFD18CE0C37AE738925..",
"5413FE56585A5D287480FDFEFEFCFEFEFCFEFE7CFEFEFD1840C824BB04162925",
"5413FE56585A5D28748FFDFCFCFCFCFCFCFCFC47772C0A89814936A1F3672A25",
"5413FE56585A5D28BCB9FDFEFEFCFEFEFCFE909A5B1A07071A5B1538146E0629",
"5413FE56585A5DDCE73CFDFEFEFCFEFEFCD31E65FEFEFEFEFEFE6515A8666C2A",
"5413FE56585A3ECD86ABFDFCFCFCFCFCFC775BFEFEFEFEFEFEFEFE5B5363688A",
"5413FE56577230AC3DAAFDFEFEFCFEFEFC1E1AFEFEFDFEFEFEFEFE1A4E0D6906",
"5421FE56575C1D31E8FEFDFEFEFCFEFEFC8907FEFEFEFDFEFEFEFE0789646D06",
"5431FE030F01452DFEA4FDFDFDFDFDFDFD0A07FEFEFEFEFDFEFEFE0789646D06",
"541FFE6A721D79FE19D6E69B0DB38B1840811AFEFEFEFEFDFEFEFE1A4E0D6906",
"542EFE0F014AFE265E21159FEEEDD5BACB495BFEFEFEFEFDFEFEFE5B5363688A",
"7005FE5C43FE0F44793F670000D937A224361565FEFEFEFDFEFE6515A9666C2A",
"7084FEFEFE0F60102F97B7984646D4D2A6C738155B1A07071A5B15A7DE6E0629",
"72CA336060FA6F2FFD7676505050F1EB91C4C1023B4E89894E3B0214DD672A25",
"176135716F0B4BFD0A0A0A0A0A0A898916676E66630D64640D63666E67922925",
"..174B992F7F..................25292A066C68696D6D69686C062A2925..",
};

View File

@@ -0,0 +1,103 @@
/* XPM */
static char *pixmap[] = {
/* width height ncols cpp */
"16 16 81 2",
/* Colors */
"00 c #FFFFFF",
"01 c #72A0CD",
"02 c #709ECA",
"03 c #6E9BC7",
"04 c #6E9AC5",
"05 c #587B9E",
"06 c #577A9D",
"07 c #6081A2",
"08 c #6D8BA9",
"09 c #415B76",
"0A c #45617D",
"0B c #709DCA",
"0C c #F3F3F4",
"0D c #FEFCFC",
"0E c #FFFEFE",
"0F c #FEFEFE",
"10 c #FCFBFB",
"11 c #FFFFFE",
"12 c #34495F",
"13 c #32465B",
"14 c #6D99C4",
"15 c #8FA1B8",
"16 c #000000",
"17 c #BBBCC5",
"18 c #8F92A1",
"19 c #B1B5BF",
"1A c #D8D7DE",
"1B c #888A99",
"1C c #BFCDDC",
"1D c #5F86AC",
"1E c #344A5F",
"1F c #6992BD",
"20 c #F9FAFA",
"21 c #D4DCE4",
"22 c #5C81A6",
"23 c #DBDBDB",
"24 c #C8F8FF",
"25 c #B8E3FF",
"26 c #B8E2FF",
"27 c #BDEAFF",
"28 c #94B7E5",
"29 c #405A73",
"2A c #DADADA",
"2B c #010101",
"2C c #3B3B3B",
"2D c #383838",
"2E c #171717",
"2F c #800000",
"30 c #404040",
"31 c #5C5C5C",
"32 c #ABABAB",
"33 c #E6E6E6",
"34 c #FEAD01",
"35 c #EBEBEB",
"36 c #A3A3A3",
"37 c #A3783B",
"38 c #EDEDEC",
"39 c #544438",
"3A c #E3E2E1",
"3B c #191919",
"3C c #191717",
"3D c #FBFBFB",
"3E c #DFDFDF",
"3F c #543A38",
"40 c #56789B",
"41 c #929598",
"42 c #7F7F7F",
"43 c #A33E3B",
"44 c #557799",
"45 c #3F5770",
"46 c #7F4140",
"47 c #FE0201",
"48 c #3F5871",
"49 c #2E4255",
"4A c #3E5770",
"4B c #800101",
"4C c #6F3B3B",
"4D c #463838",
"4E c #181717",
"4F c #2E4154",
".. s None c None",
"..010203040506060606060708090A..",
"0B01000C000D0E000F000E1011001213",
"1400151617161819161A161B1C1D001E",
"1F201616161616161616161616212216",
"062316242525252526252728162916..",
"062A1616162B2C2D2E2E2D2C2B162F..",
"062A16000F3031323333323130342F..",
"06351600363132000000000031372F..",
"063816162D3200160000000032392F..",
"063A16003B33000016000000333C2F..",
"063D16003B33000000160000333C2F..",
"063E16162D32000000160000323F2F..",
"06000540413100000042000031432F..",
"09004421453031323333323146472F..",
"4849004A164B4C4D4E4E4D4C4B2F....",
"..4F4F16........................",
};

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

View File

@@ -0,0 +1,140 @@
var gAutoSaveInterval;
var gLastSelectedLang;
var gDictCount = 0;
function Startup() {
if ("@mozilla.org/spellchecker;1" in Components.classes)
InitLanguageMenu();
else
document.getElementById("spellingGroup").hidden = true;
gAutoSaveInterval = document.getElementById("autoSaveInterval");
EnableTextbox(document.getElementById("autoSave"), gAutoSaveInterval, true);
}
function EnableTextbox(aCheckbox, aTextbox, aStartingUp) {
aTextbox.disabled = (!aCheckbox.checked ||
parent.hPrefWindow.getPrefIsLocked(aTextbox.getAttribute("prefstring")));
if (!aTextbox.disabled && !aStartingUp)
aTextbox.focus();
}
function PopulateFonts() {
var fontsList = document.getElementById("fontSelect");
try {
var enumerator = Components.classes["@mozilla.org/gfx/fontenumerator;1"]
.getService(Components.interfaces.nsIFontEnumerator);
var localFontCount = { value: 0 }
var localFonts = enumerator.EnumerateAllFonts(localFontCount);
for (var i = 0; i < localFonts.length; ++i) {
if (localFonts[i] != "") {
fontsList.appendItem(localFonts[i], localFonts[i]);
}
}
} catch (ex) { }
}
function InitLanguageMenu() {
var spellChecker = Components.classes["@mozilla.org/spellchecker/myspell;1"]
.getService(Components.interfaces.mozISpellCheckingEngine);
var o1 = {};
var o2 = {};
// Get the list of dictionaries from the spellchecker.
spellChecker.getDictionaryList(o1, o2);
var dictList = o1.value;
var count = o2.value;
// If dictionary count hasn't changed then no need to update the menu.
if (gDictCount == count)
return;
// Store current dictionary count.
gDictCount = count;
// Load the string bundles that will help us map
// RFC 1766 strings to UI strings.
// Load the language string bundle.
var languageBundle = document.getElementById("languageBundle");
var regionBundle = null;
// If we have a language string bundle, load the region string bundle.
if (languageBundle)
regionBundle = document.getElementById("regionBundle");
var menuStr2;
var isoStrArray;
var langId;
var langLabel;
var i;
for (i = 0; i < count; i++) {
try {
langId = dictList[i];
isoStrArray = dictList[i].split("-");
if (languageBundle && isoStrArray[0])
langLabel = languageBundle.getString(isoStrArray[0].toLowerCase());
if (regionBundle && langLabel && isoStrArray.length > 1 && isoStrArray[1]) {
menuStr2 = regionBundle.getString(isoStrArray[1].toLowerCase());
if (menuStr2)
langLabel += "/" + menuStr2;
}
if (!langLabel)
langLabel = langId;
} catch (ex) {
// getString throws an exception when a key is not found in the
// bundle. In that case, just use the original dictList string.
langLabel = langId;
}
dictList[i] = [langLabel, langId];
}
// sort by locale-aware collation
dictList.sort(
function compareFn(a, b) {
return a[0].localeCompare(b[0]);
}
);
var languageMenuList = document.getElementById("languageMenuList");
// Remove any languages from the list.
var languageMenuPopup = languageMenuList.firstChild;
while (languageMenuPopup.firstChild.localName != "menuseparator")
languageMenuPopup.removeChild(languageMenuPopup.firstChild);
var curLang = languageMenuList.value;
var defaultItem = null;
for (i = 0; i < count; i++) {
var item = languageMenuList.insertItemAt(i, dictList[i][0], dictList[i][1]);
if (curLang && dictList[i][1] == curLang)
defaultItem = item;
}
// Now make sure the correct item in the menu list is selected.
if (defaultItem) {
languageMenuList.selectedItem = defaultItem;
gLastSelectedLang = defaultItem;
}
}
function SelectLanguage(aTarget) {
try {
if (aTarget.value != "more-cmd")
gLastSelectedLang = aTarget;
else {
window.openDialog(getBrowserURL(), "_blank", "chrome,all,dialog=no",
xlateURL('urn:clienturl:composer:spellcheckers'));
if (gLastSelectedLang)
document.getElementById("languageMenuList").selectedItem = gLastSelectedLang;
}
} catch (ex) {
dump(ex);
}
}

View File

@@ -0,0 +1,568 @@
################################################################################
# Modified versions of macros provided by NSIS
; Modified version of Locate from the NSIS File Functions Header v3.2
; This version has the calls to SetDetailsPrint and DetailsPrint commented out.
; See <NSIS App Dir>/include/FileFunc.nsh for more information
!macro LocateNoDetails
!ifndef ${_FILEFUNC_UN}LocateNoDetails
!verbose push
!verbose ${_FILEFUNC_VERBOSE}
!define ${_FILEFUNC_UN}LocateNoDetails `!insertmacro ${_FILEFUNC_UN}LocateNoDetailsCall`
Function ${_FILEFUNC_UN}LocateNoDetails
Exch $2
Exch
Exch $1
Exch
Exch 2
Exch $0
Exch 2
Push $3
Push $4
Push $5
Push $6
Push $7
Push $8
Push $9
Push $R6
Push $R7
Push $R8
Push $R9
ClearErrors
StrCpy $3 ''
StrCpy $4 ''
StrCpy $5 ''
StrCpy $6 ''
StrCpy $7 ''
StrCpy $8 0
StrCpy $R7 ''
StrCpy $R9 $0 1 -1
StrCmp $R9 '\' 0 +3
StrCpy $0 $0 -1
goto -3
IfFileExists '$0\*.*' 0 error
option:
StrCpy $R9 $1 1
StrCpy $1 $1 '' 1
StrCmp $R9 ' ' -2
StrCmp $R9 '' sizeset
StrCmp $R9 '/' 0 -4
StrCpy $9 -1
IntOp $9 $9 + 1
StrCpy $R9 $1 1 $9
StrCmp $R9 '' +2
StrCmp $R9 '/' 0 -3
StrCpy $R8 $1 $9
StrCpy $R8 $R8 '' 2
StrCpy $R9 $R8 '' -1
StrCmp $R9 ' ' 0 +3
StrCpy $R8 $R8 -1
goto -3
StrCpy $R9 $1 2
StrCpy $1 $1 '' $9
StrCmp $R9 'L=' 0 mask
StrCpy $3 $R8
StrCmp $3 '' +6
StrCmp $3 'FD' +5
StrCmp $3 'F' +4
StrCmp $3 'D' +3
StrCmp $3 'DE' +2
StrCmp $3 'FDE' 0 error
goto option
mask:
StrCmp $R9 'M=' 0 size
StrCpy $4 $R8
goto option
size:
StrCmp $R9 'S=' 0 gotosubdir
StrCpy $6 $R8
goto option
gotosubdir:
StrCmp $R9 'G=' 0 banner
StrCpy $7 $R8
StrCmp $7 '' +3
StrCmp $7 '1' +2
StrCmp $7 '0' 0 error
goto option
banner:
StrCmp $R9 'B=' 0 error
StrCpy $R7 $R8
StrCmp $R7 '' +3
StrCmp $R7 '1' +2
StrCmp $R7 '0' 0 error
goto option
sizeset:
StrCmp $6 '' default
StrCpy $9 0
StrCpy $R9 $6 1 $9
StrCmp $R9 '' +4
StrCmp $R9 ':' +3
IntOp $9 $9 + 1
goto -4
StrCpy $5 $6 $9
IntOp $9 $9 + 1
StrCpy $1 $6 1 -1
StrCpy $6 $6 -1 $9
StrCmp $5 '' +2
IntOp $5 $5 + 0
StrCmp $6 '' +2
IntOp $6 $6 + 0
StrCmp $1 'B' 0 +3
StrCpy $1 1
goto default
StrCmp $1 'K' 0 +3
StrCpy $1 1024
goto default
StrCmp $1 'M' 0 +3
StrCpy $1 1048576
goto default
StrCmp $1 'G' 0 error
StrCpy $1 1073741824
default:
StrCmp $3 '' 0 +2
StrCpy $3 'FD'
StrCmp $4 '' 0 +2
StrCpy $4 '*.*'
StrCmp $7 '' 0 +2
StrCpy $7 '1'
StrCmp $R7 '' 0 +2
StrCpy $R7 '0'
StrCpy $7 'G$7B$R7'
StrCpy $8 1
Push $0
; SetDetailsPrint textonly
nextdir:
IntOp $8 $8 - 1
Pop $R8
StrCpy $9 $7 2 2
StrCmp $9 'B0' +3
GetLabelAddress $9 findfirst
goto call
; DetailPrint 'Search in: $R8'
findfirst:
FindFirst $0 $R7 '$R8\$4'
IfErrors subdir
StrCmp $R7 '.' 0 +5
FindNext $0 $R7
StrCmp $R7 '..' 0 +3
FindNext $0 $R7
IfErrors subdir
dir:
IfFileExists '$R8\$R7\*.*' 0 file
StrCpy $R6 ''
StrCmp $3 'DE' +4
StrCmp $3 'FDE' +3
StrCmp $3 'FD' precall
StrCmp $3 'F' findnext precall
FindFirst $9 $R9 '$R8\$R7\*.*'
StrCmp $R9 '.' 0 +4
FindNext $9 $R9
StrCmp $R9 '..' 0 +2
FindNext $9 $R9
FindClose $9
IfErrors precall findnext
file:
StrCmp $3 'FDE' +3
StrCmp $3 'FD' +2
StrCmp $3 'F' 0 findnext
StrCpy $R6 0
StrCmp $5$6 '' precall
FileOpen $9 '$R8\$R7' r
IfErrors +3
FileSeek $9 0 END $R6
FileClose $9
System::Int64Op $R6 / $1
Pop $R6
StrCmp $5 '' +2
IntCmp $R6 $5 0 findnext
StrCmp $6 '' +2
IntCmp $R6 $6 0 0 findnext
precall:
StrCpy $9 0
StrCpy $R9 '$R8\$R7'
call:
Push $0
Push $1
Push $2
Push $3
Push $4
Push $5
Push $6
Push $7
Push $8
Push $9
Push $R7
Push $R8
StrCmp $9 0 +4
StrCpy $R6 ''
StrCpy $R7 ''
StrCpy $R9 ''
Call $2
Pop $R9
Pop $R8
Pop $R7
Pop $9
Pop $8
Pop $7
Pop $6
Pop $5
Pop $4
Pop $3
Pop $2
Pop $1
Pop $0
IfErrors error
StrCmp $R9 'StopLocate' clearstack
goto $9
findnext:
FindNext $0 $R7
IfErrors 0 dir
FindClose $0
subdir:
StrCpy $9 $7 2
StrCmp $9 'G0' end
FindFirst $0 $R7 '$R8\*.*'
StrCmp $R7 '.' 0 +5
FindNext $0 $R7
StrCmp $R7 '..' 0 +3
FindNext $0 $R7
IfErrors +7
IfFileExists '$R8\$R7\*.*' 0 +3
Push '$R8\$R7'
IntOp $8 $8 + 1
FindNext $0 $R7
IfErrors 0 -4
FindClose $0
StrCmp $8 0 end nextdir
error:
SetErrors
clearstack:
StrCmp $8 0 end
IntOp $8 $8 - 1
Pop $R8
goto clearstack
end:
; SetDetailsPrint both
Pop $R9
Pop $R8
Pop $R7
Pop $R6
Pop $9
Pop $8
Pop $7
Pop $6
Pop $5
Pop $4
Pop $3
Pop $2
Pop $1
Pop $0
FunctionEnd
!verbose pop
!endif
!macroend
!macro LocateNoDetailsCall _PATH _OPTIONS _FUNC
!verbose push
!verbose ${_FILEFUNC_VERBOSE}
Push $0
Push `${_PATH}`
Push `${_OPTIONS}`
GetFunctionAddress $0 `${_FUNC}`
Push `$0`
Call LocateNoDetails
Pop $0
!verbose pop
!macroend
!macro un.LocateNoDetailsCall _PATH _OPTIONS _FUNC
!verbose push
!verbose ${_FILEFUNC_VERBOSE}
Push $0
Push `${_PATH}`
Push `${_OPTIONS}`
GetFunctionAddress $0 `${_FUNC}`
Push `$0`
Call un.LocateNoDetails
Pop $0
!verbose pop
!macroend
!macro un.LocateNoDetails
!ifndef un.LocateNoDetails
!verbose push
!verbose ${_FILEFUNC_VERBOSE}
!undef _FILEFUNC_UN
!define _FILEFUNC_UN `un.`
!insertmacro LocateNoDetails
!undef _FILEFUNC_UN
!define _FILEFUNC_UN
!verbose pop
!endif
!macroend
; Modified version of TextCompare from the NSIS Text Functions Header v2.4
; This version has the calls to SetDetailsPrint and DetailsPrint commented out.
; See <NSIS App Dir>/include/TextFunc.nsh for more information
!macro TextCompareNoDetails
!ifndef ${_TEXTFUNC_UN}TextCompareNoDetails${_TEXTFUNC_S}
!verbose push
!verbose ${_TEXTFUNC_VERBOSE}
!define ${_TEXTFUNC_UN}TextCompareNoDetails${_TEXTFUNC_S} `!insertmacro ${_TEXTFUNC_UN}TextCompareNoDetails${_TEXTFUNC_S}Call`
Function ${_TEXTFUNC_UN}TextCompareNoDetails${_TEXTFUNC_S}
Exch $3
Exch
Exch $2
Exch
Exch 2
Exch $1
Exch 2
Exch 3
Exch $0
Exch 3
Push $4
Push $5
Push $6
Push $7
Push $8
Push $9
ClearErrors
IfFileExists $0 0 error
IfFileExists $1 0 error
StrCmp $2 'FastDiff' +5
StrCmp $2 'FastEqual' +4
StrCmp $2 'SlowDiff' +3
StrCmp $2 'SlowEqual' +2
goto error
FileOpen $4 $0 r
IfErrors error
FileOpen $5 $1 r
IfErrors error
; SetDetailsPrint textonly
StrCpy $6 0
StrCpy $8 0
nextline:
StrCmp${_TEXTFUNC_S} $4 '' fast
IntOp $8 $8 + 1
FileRead $4 $9
IfErrors 0 +4
FileClose $4
StrCpy $4 ''
StrCmp${_TEXTFUNC_S} $5 '' end
StrCmp $2 'FastDiff' fast
StrCmp $2 'FastEqual' fast slow
fast:
StrCmp${_TEXTFUNC_S} $5 '' call
IntOp $6 $6 + 1
FileRead $5 $7
IfErrors 0 +5
FileClose $5
StrCpy $5 ''
StrCmp${_TEXTFUNC_S} $4 '' end
StrCmp $2 'FastDiff' call close
StrCmp $2 'FastDiff' 0 +2
StrCmp${_TEXTFUNC_S} $7 $9 nextline call
StrCmp${_TEXTFUNC_S} $7 $9 call nextline
slow:
StrCmp${_TEXTFUNC_S} $4 '' close
StrCpy $6 ''
; DetailPrint '$8. $9'
FileSeek $5 0
slownext:
FileRead $5 $7
IfErrors 0 +2
StrCmp $2 'SlowDiff' call nextline
StrCmp $2 'SlowDiff' 0 +2
StrCmp${_TEXTFUNC_S} $7 $9 nextline slownext
IntOp $6 $6 + 1
StrCmp${_TEXTFUNC_S} $7 $9 0 slownext
call:
Push $2
Push $3
Push $4
Push $5
Push $6
Push $7
Push $8
Push $9
Call $3
Pop $0
Pop $9
Pop $8
Pop $7
Pop $6
Pop $5
Pop $4
Pop $3
Pop $2
StrCmp $0 'StopTextCompare' 0 nextline
close:
FileClose $4
FileClose $5
goto end
error:
SetErrors
end:
; SetDetailsPrint both
Pop $9
Pop $8
Pop $7
Pop $6
Pop $5
Pop $4
Pop $3
Pop $2
Pop $1
Pop $0
FunctionEnd
!verbose pop
!endif
!macroend
!macro TextCompareNoDetailsS
!ifndef TextCompareNoDetailsS
!verbose push
!verbose ${_TEXTFUNC_VERBOSE}
!undef _TEXTFUNC_S
!define _TEXTFUNC_S `S`
!insertmacro TextCompareNoDetails
!undef _TEXTFUNC_S
!define _TEXTFUNC_S
!verbose pop
!endif
!macroend
!macro TextCompareNoDetailsCall _FILE1 _FILE2 _OPTION _FUNC
!verbose push
!verbose ${_TEXTFUNC_VERBOSE}
Push $0
Push `${_FILE1}`
Push `${_FILE2}`
Push `${_OPTION}`
GetFunctionAddress $0 `${_FUNC}`
Push `$0`
Call TextCompareNoDetails
Pop $0
!verbose pop
!macroend
!macro TextCompareNoDetailsSCall _FILE1 _FILE2 _OPTION _FUNC
!verbose push
!verbose ${_TEXTFUNC_VERBOSE}
Push $0
Push `${_FILE1}`
Push `${_FILE2}`
Push `${_OPTION}`
GetFunctionAddress $0 `${_FUNC}`
Push `$0`
Call TextCompareNoDetailsS
Pop $0
!verbose pop
!macroend
!macro un.TextCompareNoDetailsCall _FILE1 _FILE2 _OPTION _FUNC
!verbose push
!verbose ${_TEXTFUNC_VERBOSE}
Push $0
Push `${_FILE1}`
Push `${_FILE2}`
Push `${_OPTION}`
GetFunctionAddress $0 `${_FUNC}`
Push `$0`
Call un.TextCompareNoDetails
Pop $0
!verbose pop
!macroend
!macro un.TextCompareNoDetailsSCall _FILE1 _FILE2 _OPTION _FUNC
!verbose push
!verbose ${_TEXTFUNC_VERBOSE}
Push $0
Push `${_FILE1}`
Push `${_FILE2}`
Push `${_OPTION}`
GetFunctionAddress $0 `${_FUNC}`
Push `$0`
Call un.TextCompareNoDetailsS
Pop $0
!verbose pop
!macroend
!macro un.TextCompareNoDetails
!ifndef un.TextCompareNoDetails
!verbose push
!verbose ${_TEXTFUNC_VERBOSE}
!undef _TEXTFUNC_UN
!define _TEXTFUNC_UN `un.`
!insertmacro TextCompareNoDetails
!undef _TEXTFUNC_UN
!define _TEXTFUNC_UN
!verbose pop
!endif
!macroend
!macro un.TextCompareNoDetailsS
!ifndef un.TextCompareNoDetailsS
!verbose push
!verbose ${_TEXTFUNC_VERBOSE}
!undef _TEXTFUNC_UN
!define _TEXTFUNC_UN `un.`
!undef _TEXTFUNC_S
!define _TEXTFUNC_S `S`
!insertmacro TextCompareNoDetails
!undef _TEXTFUNC_UN
!define _TEXTFUNC_UN
!undef _TEXTFUNC_S
!define _TEXTFUNC_S
!verbose pop
!endif
!macroend