[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qsos-commits] qsos/apps/xuleditor/chrome/content about.xul au...
From: |
Raphaël Semeteys |
Subject: |
[Qsos-commits] qsos/apps/xuleditor/chrome/content about.xul au... |
Date: |
Thu, 22 Jun 2006 23:20:56 +0000 |
CVSROOT: /sources/qsos
Module name: qsos
Changes by: Raphaël Semeteys <rsemeteys> 06/06/22 23:20:56
Modified files:
apps/xuleditor/chrome/content: about.xul authors.xul confirm.xul
editor.js editor.xul
qsos-overlay.xul
Log message:
Localization
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/qsos/apps/xuleditor/chrome/content/about.xul?cvsroot=qsos&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/qsos/apps/xuleditor/chrome/content/authors.xul?cvsroot=qsos&r1=1.1&r2=1.2
http://cvs.savannah.gnu.org/viewcvs/qsos/apps/xuleditor/chrome/content/confirm.xul?cvsroot=qsos&r1=1.2&r2=1.3
http://cvs.savannah.gnu.org/viewcvs/qsos/apps/xuleditor/chrome/content/editor.js?cvsroot=qsos&r1=1.8&r2=1.9
http://cvs.savannah.gnu.org/viewcvs/qsos/apps/xuleditor/chrome/content/editor.xul?cvsroot=qsos&r1=1.8&r2=1.9
http://cvs.savannah.gnu.org/viewcvs/qsos/apps/xuleditor/chrome/content/qsos-overlay.xul?cvsroot=qsos&r1=1.1&r2=1.2
Patches:
Index: about.xul
===================================================================
RCS file: /sources/qsos/qsos/apps/xuleditor/chrome/content/about.xul,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- about.xul 29 May 2006 22:29:47 -0000 1.3
+++ about.xul 22 Jun 2006 23:20:55 -0000 1.4
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
-<!DOCTYPE window>
+<!DOCTYPE window SYSTEM "chrome://qsos-xuled/locale/about.dtd">
-<dialog id="about" title="About"
+<dialog id="about" title="&about.label;"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
buttons="accept">
@@ -12,14 +12,14 @@
</hbox>
<vbox>
<label value=""/>
- <label value="QSOS XUL Editor v0.2"/>
- <label value="Software under the terms of the GNU Public
License"/>
+ <label value="&label1.value;"/>
+ <label value="&label2.value;"/>
<label value=""/>
- <label value="Authors:"/>
- <label value=" . address@hidden"/>
+ <label value="&label3.value;"/>
+ <label value="&label4.value;"/>
<label value=""/>
- <label value="Source code available on
http://savannah.nongnu.org/projects/qsos"/>
- <label value="Information on QSOS method available on
http://www.qsos.org"/>
+ <label value="&label5.value;"/>
+ <label value="&label6.value;"/>
</vbox>
</vbox>
Index: authors.xul
===================================================================
RCS file: /sources/qsos/qsos/apps/xuleditor/chrome/content/authors.xul,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -b -r1.1 -r1.2
--- authors.xul 18 Apr 2006 07:52:02 -0000 1.1
+++ authors.xul 22 Jun 2006 23:20:55 -0000 1.2
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
-<!DOCTYPE window>
+<!DOCTYPE window SYSTEM "chrome://qsos-xuled/locale/authors.dtd">
-<dialog id="authors" title="Authors"
+<dialog id="authors" title="&authors.title;"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
buttons="accept"
ondialogaccept="return doOK();"
@@ -11,13 +11,13 @@
<script type="application/x-javascript" src="authors.js"></script>
<vbox>
- <hbox><label control="f-a-name" value="Name"/><textbox
id="f-a-name"/></hbox>
- <hbox><label control="f-a-email" value="Email"/><textbox
id="f-a-email"/></hbox>
+ <hbox><label control="f-a-name" value="&f-a-name.value;"/><textbox
id="f-a-name"/></hbox>
+ <hbox><label control="f-a-email" value="&f-a-email.value;"/><textbox
id="f-a-email"/></hbox>
<hbox>
- <button label="Add" oncommand="addAuthor();"/>
- <button label="Delete" oncommand="deleteAuthor();"/>
+ <button label="&button1.label;" oncommand="addAuthor();"/>
+ <button label="&button2.label;" oncommand="deleteAuthor();"/>
</hbox>
- <label control="f_a-list" value="Authors: "/>
+ <label control="f-a-list" value="&f-a-list;"/>
<listbox id="f-a-list" rows="3"
onselect="changeAuthor(this.selectedItem);"></listbox>
</vbox>
Index: confirm.xul
===================================================================
RCS file: /sources/qsos/qsos/apps/xuleditor/chrome/content/confirm.xul,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- confirm.xul 14 Apr 2006 16:18:38 -0000 1.2
+++ confirm.xul 22 Jun 2006 23:20:55 -0000 1.3
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
-<!DOCTYPE window>
+<!DOCTYPE window SYSTEM "chrome://qsos-xuled/locale/confirm.dtd">
-<dialog id="confirm" title="Confirm"
+<dialog id="confirm" title="&confirm.title;"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
buttons="accept,cancel"
ondialogaccept="return doOK();"
Index: editor.js
===================================================================
RCS file: /sources/qsos/qsos/apps/xuleditor/chrome/content/editor.js,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -b -r1.8 -r1.9
--- editor.js 27 May 2006 13:47:55 -0000 1.8
+++ editor.js 22 Jun 2006 23:20:55 -0000 1.9
@@ -31,9 +31,12 @@
var docChanged;
//id (actually "name" in the QSOS XML file) of the currently selected criteria
in the tree
var id;
+//Localized strings bundle
+var strbundle;
//Window initialization after loading
function init() {
+ strbundle = document.getElementById("properties");
docChanged = "false";
freezeGeneric("true");
freezeScore("true");
@@ -61,8 +64,8 @@
var nsIFilePicker = Components.interfaces.nsIFilePicker;
var fp = Components.classes["@mozilla.org/filepicker;1"]
.createInstance(nsIFilePicker);
- fp.init(window, "Select a file", nsIFilePicker.modeOpen);
- fp.appendFilter("QSOS file","*.qsos");
+ fp.init(window, strbundle.getString("selectFile"), nsIFilePicker.modeOpen);
+ fp.appendFilter(strbundle.getString("QSOSFile"),"*.qsos");
var res = fp.show();
if (res == nsIFilePicker.returnOK) {
@@ -70,7 +73,7 @@
myDoc.load();
//Window's title
- document.getElementById("QSOS").setAttribute("title", "QSOS
evaluation: "+myDoc.getappname());
+ document.getElementById("QSOS").setAttribute("title",
strbundle.getString("QSOSEvaluation")+" "+myDoc.getappname());
//Tree population
var tree = document.getElementById("mytree");
@@ -114,7 +117,7 @@
function checkopenFile() {
if (myDoc) {
if (docChanged == "true") {
- confirmDialog("Document has been modified but not
saved, close it anyway?", closeFile);
+ confirmDialog(strbundle.getString("closeAnyway"),
closeFile);
}
else {
closeFile();
@@ -187,8 +190,8 @@
var nsIFilePicker = Components.interfaces.nsIFilePicker;
var fp = Components.classes["@mozilla.org/filepicker;1"]
.createInstance(nsIFilePicker);
- fp.init(window, "Save the file as", nsIFilePicker.modeSave);
- fp.appendFilter("QSOS file","*.qsos");
+ fp.init(window, strbundle.getString("saveFileAs"),
nsIFilePicker.modeSave);
+ fp.appendFilter(strbundle.getString("QSOSFile"),"*.qsos");
var res = fp.show();
if (res == nsIFilePicker.returnOK) {
myDoc.setfilename(fp.file.path);
@@ -202,7 +205,7 @@
//////////////////////////
//Closes the QSOS XML file and resets window
function closeFile() {
- document.getElementById("QSOS").setAttribute("title", "QSOS XUL
Editor");
+ document.getElementById("QSOS").setAttribute("title",
strbundle.getString("QSOSEditor"));
document.getElementById("f-software").value = "";
document.getElementById("f-release").value = "";
document.getElementById("f-sotwarefamily").value = "";
@@ -210,12 +213,12 @@
document.getElementById("f-url").value = "";
document.getElementById("f-demourl").value = "";
- document.getElementById("t-software").setAttribute("label", "Software");
- document.getElementById("t-c-title").setAttribute("label", "Criterion");
+ document.getElementById("t-software").setAttribute("label",
strbundle.getString("softwareLabel"));
+ document.getElementById("t-c-title").setAttribute("label",
strbundle.getString("criterionLabel"));
- document.getElementById("f-c-desc0").setAttribute("label", "Score 0");
- document.getElementById("f-c-desc1").setAttribute("label", "Score 1");
- document.getElementById("f-c-desc2").setAttribute("label", "Score 2");
+ document.getElementById("f-c-desc0").setAttribute("label",
strbundle.getString("score0Label"));
+ document.getElementById("f-c-desc1").setAttribute("label",
strbundle.getString("score1Label"));
+ document.getElementById("f-c-desc2").setAttribute("label",
strbundle.getString("score2Label"));
document.getElementById("f-c-score").selectedIndex = -1;
document.getElementById("f-c-comments").value = "";
@@ -233,7 +236,7 @@
//Checks Document's state before closing it
function checkcloseFile() {
if (docChanged == "true") {
- confirmDialog("Document has been modified, save it before?",
saveFile);
+ confirmDialog(strbundle.getString("saveBefore"), saveFile);
}
closeFile();
}
@@ -249,7 +252,7 @@
//Checks Document's state before exiting
function checkexit() {
if (docChanged == "true") {
- confirmDialog("Document has been modified but not saved, exit
anyway?", exit);
+ confirmDialog(strbundle.getString("exitAnyway"), exit);
return;
}
else {
Index: editor.xul
===================================================================
RCS file: /sources/qsos/qsos/apps/xuleditor/chrome/content/editor.xul,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -b -r1.8 -r1.9
--- editor.xul 29 May 2006 17:13:38 -0000 1.8
+++ editor.xul 22 Jun 2006 23:20:55 -0000 1.9
@@ -1,42 +1,44 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet href="chrome://global/skin/" type="text/css"?>
<?xml-stylesheet href="chrome://qsos-xuled/skin/classic.css" type="text/css"?>
-<!DOCTYPE window>
+<!DOCTYPE window SYSTEM "chrome://qsos-xuled/locale/editor.dtd">
-<window id="QSOS" title="QSOS XUL Editor" width="800px" height="600px"
+<window id="QSOS" title="&QSOS.label;" width="800px" height="600px"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
onload="init();">
<script type="application/x-javascript" src="Document.js"></script>
<script type="application/x-javascript" src="editor.js"></script>
+<stringbundle id="properties"
src="chrome://qsos-xuled/locale/editor.properties"/>
+
<vbox flex = "1">
<toolbox>
<menubar id="mymenubar">
- <menu id="file-menu" label="File"
onclick="document.getElementById('file-menu').focus();">
+ <menu id="file-menu" label="&file-menu.label;"
onclick="document.getElementById('file-menu').focus();">
<menupopup id="file-popup">
- <menuitem id="file-open" label="Open" onclick="checkopenFile();"/>
- <menuitem id="file-save" label="Save" onclick="saveFile();"/>
- <menuitem id="file-saveas" label="Save As" onclick="saveFileAs();"/>
- <menuitem id="file-close" label="Close"
onclick="checkcloseFile();"/>
+ <menuitem id="file-open" label="&file-open.label;"
onclick="checkopenFile();"/>
+ <menuitem id="file-save" label="&file-save.label;"
onclick="saveFile();"/>
+ <menuitem id="file-saveas" label="&file-saveas.label;"
onclick="saveFileAs();"/>
+ <menuitem id="file-close" label="&file-close.label;"
onclick="checkcloseFile();"/>
<menuseparator/>
- <menuitem id="file-exit" label="Exit" onclick="checkexit();"/>
+ <menuitem id="file-exit" label="&file-exit.label;"
onclick="checkexit();"/>
</menupopup>
</menu>
- <menu id="edit-menu" label="Edit"
onclick="document.getElementById('edit-menu').focus();">
+ <menu id="edit-menu" label="&edit-menu.label;"
onclick="document.getElementById('edit-menu').focus();">
<menupopup id="edit-popup">
- <menuitem id="edit-authors" label="Authors"
onclick="authorsDialog();"/>
+ <menuitem id="edit-authors"
label="&edit-authors.label;" onclick="authorsDialog();"/>
</menupopup>
</menu>
- <menu id="tree-menu" label="Tree"
onclick="document.getElementById('tree-menu').focus();">
+ <menu id="tree-menu" label="&tree-menu.label;"
onclick="document.getElementById('tree-menu').focus();">
<menupopup id="tree-popup">
- <menuitem id="tree-expand" label="Expand all"
onclick="expandTree('true');"/>
- <menuitem id="tree-collapse" label="Collapse all"
onclick="expandTree('false');"/>
+ <menuitem id="tree-expand" label="&tree-expand.label;"
onclick="expandTree('true');"/>
+ <menuitem id="tree-collapse"
label="&tree-collapse.label;" onclick="expandTree('false');"/>
</menupopup>
</menu>
- <menu id="help-menu" label="Help"
onclick="document.getElementById('help-menu').focus();">
+ <menu id="help-menu" label="&help-menu.label;"
onclick="document.getElementById('help-menu').focus();">
<menupopup id="help-popup">
- <menuitem id="help-about" label="About" onclick="aboutDialog();"/>
+ <menuitem id="help-about" label="&help-about.label;"
onclick="aboutDialog();"/>
</menupopup>
</menu>
</menubar>
@@ -46,49 +48,49 @@
<vbox>
<tree id="mytree" width="300px" onselect="treeselect(this);"
flex="1">
<treecols>
- <treecol id="name" label="Criteria" primary="true" flex="1"/>
+ <treecol id="name" label="&name.label;" primary="true"
flex="1"/>
</treecols>
</tree>
</vbox>
<tabbox flex = "1">
<tabs>
- <tab id = "t-software" label = "Software"/>
- <tab id = "t-c-title" label = "Criterion"/>
- <tab id = "t-chart" label = "Chart"/>
+ <tab id = "t-software" label = "&t-software.label;"/>
+ <tab id = "t-c-title" label = "&t-c-title.label;"/>
+ <tab id = "t-chart" label = "&t-chart.label;"/>
</tabs>
<tabpanels>
<tabpanel>
<vbox flex = "1">
- <label control="f-software"
value="Name: "/><textbox id="f-software"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeAppName(this);"/>
- <label control="f-release"
value="Release: "/><textbox id="f-release"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeRelease(this);"/>
- <label control="f-sotwarefamily"
value="Software family: "/><textbox id="f-sotwarefamily"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeSoftwareFamily(this);"/>
- <label control="f-license"
value="License: "/>
+ <label control="f-software"
value="&f-software.value;"/><textbox id="f-software"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeAppName(this);"/>
+ <label control="f-release"
value="&f-release.value;"/><textbox id="f-release"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeRelease(this);"/>
+ <label control="f-sotwarefamily"
value="&f-sotwarefamily.value;"/><textbox id="f-sotwarefamily"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeSoftwareFamily(this);"/>
+ <label control="f-license"
value="&f-license.value;"/>
<menulist id="f-license"
oncommand="changeLicense(this, this.selectedIndex);">
<menupopup
id="f-license-popup"></menupopup>
</menulist>
- <label control="f-desc"
value="Description: "/><textbox id="f-desc" multiline="true"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeDesc(this);"/>
- <label control="f-url" value="Website:
"/><textbox id="f-url" oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeUrl(this);"/>
- <label control="f-demourl" value="Demo
site: "/><textbox id="f-demourl" oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeDemoUrl(this);"/>
+ <label control="f-desc"
value="&f-desc.value;"/><textbox id="f-desc" multiline="true"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeDesc(this);"/>
+ <label control="f-url"
value="&f-url.value;"/><textbox id="f-url"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeUrl(this);"/>
+ <label control="f-demourl"
value="&f-demourl.value;"/><textbox id="f-demourl"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeDemoUrl(this);"/>
</vbox>
</tabpanel>
<tabpanel>
<vbox flex = "1">
<deck id="f-c-deck" selectedIndex="1">
<groupbox>
- <caption><label
value="Description"/></caption>
+ <caption><label
value="&label1.value;"/></caption>
<label id="f-c-desc"/>
</groupbox>
<groupbox>
- <caption><label
value="Score"/></caption>
+ <caption><label
value="&label2.value;"/></caption>
<radiogroup
id="f-c-score">
- <radio
id="f-c-desc0" label="Score 0" oncommand="changeScore(0);"/>
- <radio
id="f-c-desc1" label="Score 1" oncommand="changeScore(1);"/>
- <radio
id="f-c-desc2" label="Score 2" oncommand="changeScore(2);"/>
+ <radio
id="f-c-desc0" label="&f-c-desc0.label;" oncommand="changeScore(0);"/>
+ <radio
id="f-c-desc1" label="&f-c-desc1.label;" oncommand="changeScore(1);"/>
+ <radio
id="f-c-desc2" label="&f-c-desc2.label;" oncommand="changeScore(2);"/>
</radiogroup>
</groupbox>
</deck>
- <label control="f-c-comments"
value="Comments: "/><textbox id="f-c-comments" multiline="true"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeComments(this);"/>
+ <label control="f-c-comments"
value="&f-c-comments.value;"/><textbox id="f-c-comments" multiline="true"
oninput="this.setAttribute('class','inside');"
onchange="this.setAttribute('class','outside'); changeComments(this);"/>
</vbox>
</tabpanel>
<tabpanel>
Index: qsos-overlay.xul
===================================================================
RCS file: /sources/qsos/qsos/apps/xuleditor/chrome/content/qsos-overlay.xul,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -b -r1.1 -r1.2
--- qsos-overlay.xul 22 Jun 2006 17:15:03 -0000 1.1
+++ qsos-overlay.xul 22 Jun 2006 23:20:55 -0000 1.2
@@ -1,8 +1,9 @@
<?xml version="1.0"?>
+<!DOCTYPE overlay SYSTEM "chrome://qsos-xuled/locale/qsos-overlay.dtd">
<overlay id="qsos-overlay"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
<menupopup id="menu_ToolsPopup">
<menuitem id="qsos-xuled"
- label="QSOS Editor"
oncommand="window.openDialog('chrome://qsos-xuled/content/editor.xul','QSOS
Editor', '_blank', 'chrome,dialog=no');"/>
+ label="&qsos-xuled.label;"
oncommand="window.openDialog('chrome://qsos-xuled/content/editor.xul','&qsos-xuled.label;',
'_blank', 'chrome,dialog=no');"/>
</menupopup>
</overlay>
\ No newline at end of file
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Qsos-commits] qsos/apps/xuleditor/chrome/content about.xul au...,
Raphaël Semeteys <=