Author: jflesch
Date: 2006-10-19 19:32:18 +0000 (Thu, 19 Oct 2006)
New Revision: 10675
Modified:
trunk/apps/Thaw/src/thaw/core/MainWindow.java
trunk/apps/Thaw/src/thaw/i18n/thaw.properties
trunk/apps/Thaw/src/thaw/plugins/index/Index.java
trunk/apps/Thaw/src/thaw/plugins/index/IndexCategory.java
trunk/apps/Thaw/src/thaw/plugins/index/IndexTree.java
trunk/apps/Thaw/src/thaw/plugins/index/LinkTable.java
Log:
Add translator names to the 'About' dialog
Modified: trunk/apps/Thaw/src/thaw/core/MainWindow.java
===================================================================
--- trunk/apps/Thaw/src/thaw/core/MainWindow.java 2006-10-19 16:30:37 UTC
(rev 10674)
+++ trunk/apps/Thaw/src/thaw/core/MainWindow.java 2006-10-19 19:32:18 UTC
(rev 10675)
@@ -366,7 +366,10 @@
new JLabel(I18n.getMessage("thaw.about.l3")),
new JLabel(I18n.getMessage("thaw.about.l4")),
new JLabel(""),
- new JLabel(I18n.getMessage("thaw.about.l6"))
+ new JLabel(I18n.getMessage("thaw.about.l6")),
+ new JLabel(""),
+ new JLabel(I18n.getMessage("thaw.about.l7")),
+ new JLabel(I18n.getMessage("thaw.about.l8"))
};
labels[0].setFont(new Font("Dialog", Font.BOLD, 30));
Modified: trunk/apps/Thaw/src/thaw/i18n/thaw.properties
===================================================================
--- trunk/apps/Thaw/src/thaw/i18n/thaw.properties 2006-10-19 16:30:37 UTC
(rev 10674)
+++ trunk/apps/Thaw/src/thaw/i18n/thaw.properties 2006-10-19 19:32:18 UTC
(rev 10675)
@@ -180,8 +180,9 @@
thaw.about.l3=2006(c) Freenet Project Incorporated
thaw.about.l4=under GPLv2
thaw.about.l6=Icon theme "Gorilla" created by Jimmac
(http://jimmac.musichall.cz/icons.php)
+thaw.about.l7=French translation: Sylvain Petreolle
+thaw.about.l8=German translation: Michael Helmling
-
## HsqlDb
thaw.plugin.hsqldb.database=Database
thaw.plugin.hsqldb.console=Sql console
Modified: trunk/apps/Thaw/src/thaw/plugins/index/Index.java
===================================================================
--- trunk/apps/Thaw/src/thaw/plugins/index/Index.java 2006-10-19 16:30:37 UTC
(rev 10674)
+++ trunk/apps/Thaw/src/thaw/plugins/index/Index.java 2006-10-19 19:32:18 UTC
(rev 10675)
@@ -63,17 +63,15 @@
private String author = null;
- private boolean freshIndex = false;
/**
* The bigest constructor of the world ...
- * @param fresh If set to true, won't increment revision for the next
update
*/
public Index(Hsqldb db, FCPQueueManager queueManager,
int id, IndexCategory parent,
String realName, String displayName,
String publicKey, String privateKey,
- int revision, String author, boolean fresh,
+ int revision, String author,
boolean modifiable) {
this.queueManager = queueManager;
@@ -82,7 +80,6 @@
this.db = db;
this.tree = tree;
- this.freshIndex = fresh;
this.id = id;
this.parent = parent;
this.realName = realName;
@@ -249,7 +246,7 @@
revision++;
- clientPut = new FCPClientPut(targetFile, 2,
revision, toString(), privateKey, 4, false, 2);
+ clientPut = new FCPClientPut(targetFile, 2,
revision, toString(), privateKey, 4, false, 0);
transfer = clientPut;
clientPut.addObserver(this);
@@ -267,11 +264,13 @@
String key;
- if (!freshIndex)
+ if (!isEmpty())
key = changeRevision(publicKey, 1);
else
key = publicKey;
+ //key = key.replaceFirst("USK@", "SSK@");
+
Logger.info(this, "Key asked: "+key);
clientGet = new FCPClientGet(key, 4, 2, false, 1,
System.getProperty("java.io.tmpdir"));
@@ -397,7 +396,7 @@
java.io.File file = new
java.io.File(transfer.getPath());
Logger.info(this, "Updating index ...");
-
+
publicKey = transfer.getFileKey();
Logger.info(this, "Most up-to-date key
found: " + publicKey);
@@ -437,6 +436,19 @@
}
+ public boolean isEmpty() {
+ if (fileList == null)
+ loadFiles(null, true);
+ if (linkList == null)
+ loadLinks(null, true);
+
+ if (fileList.size() == 0 && linkList.size() == 0)
+ return true;
+
+ return false;
+ }
+
+
////// FILE LIST ////////
public void loadFiles(String columnToSort, boolean asc) {
Modified: trunk/apps/Thaw/src/thaw/plugins/index/IndexCategory.java
===================================================================
--- trunk/apps/Thaw/src/thaw/plugins/index/IndexCategory.java 2006-10-19
16:30:37 UTC (rev 10674)
+++ trunk/apps/Thaw/src/thaw/plugins/index/IndexCategory.java 2006-10-19
19:32:18 UTC (rev 10675)
@@ -287,7 +287,7 @@
set(children, position, (new Index(db,
queueManager, id, this,
realName,
displayName,
publicKey,
privateKey, revision,
- author,
false,
+ author,
modifiables)).getTreeNode());
}
} catch (java.sql.SQLException e) {
Modified: trunk/apps/Thaw/src/thaw/plugins/index/IndexTree.java
===================================================================
--- trunk/apps/Thaw/src/thaw/plugins/index/IndexTree.java 2006-10-19
16:30:37 UTC (rev 10674)
+++ trunk/apps/Thaw/src/thaw/plugins/index/IndexTree.java 2006-10-19
19:32:18 UTC (rev 10675)
@@ -289,7 +289,7 @@
IndexCategory parent = (IndexCategory)selectedNode;
- Index index = new Index(db, queueManager, -2, parent,
name, name, publicKey, null, 0, null, true, modifiables);
+ Index index = new Index(db, queueManager, -2, parent,
name, name, publicKey, null, 0, null, modifiables);
if(modifiables)
index.generateKeys(queueManager);
Modified: trunk/apps/Thaw/src/thaw/plugins/index/LinkTable.java
===================================================================
--- trunk/apps/Thaw/src/thaw/plugins/index/LinkTable.java 2006-10-19
16:30:37 UTC (rev 10674)
+++ trunk/apps/Thaw/src/thaw/plugins/index/LinkTable.java 2006-10-19
19:32:18 UTC (rev 10675)
@@ -160,7 +160,7 @@
Link link = (Link)links.get(selectedRows[i]);
Index index = new Index(db, queueManager, -2,
null, Index.getNameFromKey(link.getKey()),
Index.getNameFromKey(link.getKey()), link.getKey(), null,
- 0, null, true, false);
+ 0, null, false);
index.create();
indexTree.addToRoot(index);
}