Fixed URL.
authorJimmy Christensen <dusted@dusted.dk>
Tue, 17 Mar 2015 23:16:30 +0000 (01:16 +0200)
committerJimmy Christensen <dusted@dusted.dk>
Tue, 17 Mar 2015 23:16:30 +0000 (01:16 +0200)
Bump to v 1.2.1, fixes OSX hang-on-connect issue.

src/fkgui/MainWin.java
src/fkgui/UpdateChecker.java
src/fkgui/messages.properties
src/fkgui/messages_da.properties

index 6cb5280..5f3d3ab 100644 (file)
@@ -1,7 +1,9 @@
 package fkgui;
 
 
+import java.io.IOException;
 import java.net.URI;
+import java.net.URISyntaxException;
 import java.util.Map;
 import java.util.Vector;
 import  java.util.prefs.*;
@@ -9,6 +11,7 @@ import java.awt.*;
 import java.awt.event.ActionEvent;
 import java.awt.event.ActionListener;
 
+import javax.swing.SwingUtilities;
 import javax.swing.UIManager;
 
 import org.eclipse.jface.viewers.DoubleClickEvent;
@@ -184,9 +187,11 @@ public class MainWin implements ConsoleMsg, UpdateCheckResultListener {
                        shell.layout();
                }
 
+               clearSystray();
+               
                while (!shell.isDisposed()) {
                        if (!display.readAndDispatch()) {
-                               display.sleep();                                
+                               display.sleep();
                        }
                }
        }
@@ -234,7 +239,7 @@ public class MainWin implements ConsoleMsg, UpdateCheckResultListener {
                        UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
                } catch (Exception e1) {
                        e1.printStackTrace();
-               } 
+               }
 
                popup = new PopupMenu();
                trayIcon = new TrayIcon( iconSystrayOffline ); //$NON-NLS-1$
@@ -273,9 +278,6 @@ public class MainWin implements ConsoleMsg, UpdateCheckResultListener {
                        }
                });
 
-               clearSystray();
-
-
                trayIcon.setPopupMenu(popup);
 
                try {
@@ -610,8 +612,23 @@ public class MainWin implements ConsoleMsg, UpdateCheckResultListener {
                        int numAccounts=FkManager.getInstance().getList().size();
                        if( numAccounts>0 && prefs.getBoolean( PREF_SHOW_ACCOUNTS_READY_NOTICE, true) )
                        {
-                               trayIcon.displayMessage("FinalKey", numAccounts +" "+ (( numAccounts >1)?Messages.MainWin_1:Messages.MainWin_2), //$NON-NLS-1$ //$NON-NLS-2$
-                                               TrayIcon.MessageType.INFO);
+
+                               class TrayIconMessageTask implements Runnable
+                               {
+                                       private String msg;
+                                       public TrayIconMessageTask(String _msg)
+                                       {
+                                               msg = _msg;
+                                       }
+                                       public void run()
+                                       {
+                                               trayIcon.displayMessage("FinalKey", msg, //$NON-NLS-1$ //$NON-NLS-2$
+                                                               TrayIcon.MessageType.INFO);
+                                       }
+                               }
+
+                               new Thread( new TrayIconMessageTask(numAccounts +" "+ (( numAccounts >1)?Messages.MainWin_1:Messages.MainWin_2)) ).start();
+
                        }
 
                //      log(Messages.MainWin_40);
@@ -1091,7 +1108,7 @@ public class MainWin implements ConsoleMsg, UpdateCheckResultListener {
                                if(Desktop.isDesktopSupported())
                                {
                                        try {
-                                               URI uri = new URI("http://finalkey.net/gui/"); //$NON-NLS-1$
+                                               URI uri = new URI("http://finalkey.net/"); //$NON-NLS-1$
                                                log(Messages.MainWin_16+uri.toString());
                                                //FIXME: For whichever reason, this causes busy-cursor on the application, even though ui works fine.
                                                Desktop.getDesktop().browse(uri);
index 3077c06..11c1d09 100644 (file)
@@ -16,7 +16,7 @@ public class UpdateChecker implements Runnable {
        //Change locale with -Duser.country=DK -Duser.language=da parms for the java command.
 
        static final String CHECK_URL="http://finalkey.net/gui/update.php";
-       static final String CUR_VER="0.1.2";
+       static final String CUR_VER="0.1.2.1";
        static final String PLATFORM=System.getProperty("os.name")+"_"+System.getProperty("os.arch");
        static final String LANG = Locale.getDefault().getLanguage();
 
index 86f9b45..245f654 100644 (file)
@@ -31,7 +31,7 @@ MainWin_47=New Account
 MainWin_5=Open Account
 MainWin_52=FinalKey GUI Version 
 MainWin_53=\ available.
-MainWin_54=There's a new version of FinalKey GUI available.\nGo to http\://finalkey.net/gui/ to download it.\n\nNews\:\n
+MainWin_54=There's a new version of FinalKey GUI available.\nGo to http\://finalkey.net/ to download it.\n\nNews\:\n
 MainWin_6=Hide after connection
 MainWin_7=Show FinalKey
 MainWin_8=Hide FinalKey
index d94c30b..1ad77cf 100644 (file)
@@ -31,7 +31,7 @@ MainWin_47=Ny Konto
 MainWin_5=Åbn Konto
 MainWin_52=FinalKey GUI Version 
 MainWin_53=\ er tilgængelig.
-MainWin_54=En ny version af FinalKey GUI kan hentes.\nGå til http\://finalkey.net/gui/ to download it.\n\nNyt\:\n
+MainWin_54=En ny version af FinalKey GUI kan hentes.\nGå til http\://finalkey.net/ to download it.\n\nNyt\:\n
 MainWin_6=Skjul efter forbindelse
 MainWin_7=Vis FinalKey
 MainWin_8=Skjul FinalKey