defaultPages/StyleSheet/CieloNegro.xml
defaultPages/StyleSheet/Default.xml
schemas/rakka-page-1.0.rng
-
-Source-Repository head
- Type: git
- Location: git://git.cielonegro.org/Rakka
-
Extra-Source-Files:
Rakka.buildinfo.in
configure
tests/RakkaUnitTest.hs
tests/WikiParserTest.hs
+Source-Repository head
+ Type: git
+ Location: git://git.cielonegro.org/Rakka.git
+
Flag build-test-suite
Description: Build the test suite.
Default: False
= $.INPUT({type: "button", value: "Select file..."});
$(btnSelectFile).click(function () {
- var path = Rakka.selectFile("Select a binary file to upload", "open");
- if (path != null) {
- uploadFileBin = Rakka.loadLocalBinaryFile(path);
- fldUploadFile.value = Rakka.hexDump(uploadFileBin, 128);
- makeDirty();
- }
- });
+ var file = Rakka.selectFile("Select a binary file to upload", "open");
+ if (file != null) {
+ uploadFileBin = Rakka.loadLocalBinaryFile(file);
+ fldUploadFile.value = Rakka.hexDump(uploadFileBin, 128);
+ makeDirty();
+ }
+ });
var fldRedirect
= $.INPUT({type: "text", value: (defaultType == "redirect" ? source : "")});
return $.browser.mozilla;
};
- var loadBin_mozilla = function (path) {
+ var loadBin_mozilla = function (localFile) {
+ /* localFile: nsILocalFile */
+
try {
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
}
"signed.applets.codebase_principal_support is set to true.");
}
- var localFile
- = Components.classes["@mozilla.org/file/local;1"].createInstance(Components.interfaces.nsILocalFile);
- localFile.initWithPath(path);
-
var stream
- = Components.classes["@mozilla.org/network/file-input-stream;1"].createInstance(Components.interfaces.nsIFileInputStream);
+ = Components.classes["@mozilla.org/network/file-input-stream;1"].createInstance(
+ Components.interfaces.nsIFileInputStream);
stream.init(localFile, 0x01, 00004, null);
var bstream
bstream.QueryInterface(Components.interfaces.nsIInputStream);
var binary
- = Components.classes["@mozilla.org/binaryinputstream;1"].createInstance(Components.interfaces.nsIBinaryInputStream);
+ = Components.classes["@mozilla.org/binaryinputstream;1"].createInstance(
+ Components.interfaces.nsIBinaryInputStream);
binary.setInputStream(stream);
return binary.readBytes(binary.available());
var ret = picker.show();
if (ret == nsIFilePicker.returnOK || ret == nsIFilePicker.returnReplace) {
- return picker.file.path;
+ return picker.file;
}
else {
return null;
}
};
- Rakka.loadLocalBinaryFile = function (path) {
+ Rakka.loadLocalBinaryFile = function (file) {
if ($.browser.mozilla) {
- return loadBin_mozilla(path);
+ return loadBin_mozilla(file);
}
else {
throw new Error("It's not possible to load local files using JavaScript with your browser. Consider using Firefox.");