diff options
author | Yana Stamcheva <yana@jitsi.org> | 2008-05-28 11:19:54 +0000 |
---|---|---|
committer | Yana Stamcheva <yana@jitsi.org> | 2008-05-28 11:19:54 +0000 |
commit | 2c111b0a89cacc1940816c6f3fa0d804a339a1f4 (patch) | |
tree | e6729e5dde700a15df1877a2ef02fd45eaf32e23 /src/net | |
parent | b7fa06b02e2af0648bc3b6bd7c3b64a1fa630e0a (diff) | |
download | jitsi-2c111b0a89cacc1940816c6f3fa0d804a339a1f4.zip jitsi-2c111b0a89cacc1940816c6f3fa0d804a339a1f4.tar.gz jitsi-2c111b0a89cacc1940816c6f3fa0d804a339a1f4.tar.bz2 |
Sign up link added to simple account registration page.
Diffstat (limited to 'src/net')
24 files changed, 371 insertions, 12 deletions
diff --git a/src/net/java/sip/communicator/plugin/aimaccregwizz/AimAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/aimaccregwizz/AimAccountRegistrationWizard.java index 72e4456..14cd1e4 100644 --- a/src/net/java/sip/communicator/plugin/aimaccregwizz/AimAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/aimaccregwizz/AimAccountRegistrationWizard.java @@ -341,4 +341,25 @@ public class AimAccountRegistrationWizard { return true; } + + public void webSignup() + { + AimAccRegWizzActivator + .getBrowserLauncher() + .openURL( + "https://reg.my.screenname.aol.com/_cqr/registration/" + + "initRegistration.psp?sitedomain=www.aim.com&createSn=1"); + } + + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return true; + } } diff --git a/src/net/java/sip/communicator/plugin/aimaccregwizz/FirstWizardPage.java b/src/net/java/sip/communicator/plugin/aimaccregwizz/FirstWizardPage.java index 4d629c3..151beda 100644 --- a/src/net/java/sip/communicator/plugin/aimaccregwizz/FirstWizardPage.java +++ b/src/net/java/sip/communicator/plugin/aimaccregwizz/FirstWizardPage.java @@ -421,10 +421,7 @@ public class FirstWizardPage public void actionPerformed(ActionEvent e) { - AimAccRegWizzActivator - .getBrowserLauncher() - .openURL( - "http://my.screenname.aol.com/_cqr/login/login.psp?seamless=n&createSn=1"); + wizard.webSignup(); } /** diff --git a/src/net/java/sip/communicator/plugin/dictaccregwizz/DictAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/dictaccregwizz/DictAccountRegistrationWizard.java index b2d2d5b..5eebae6 100644 --- a/src/net/java/sip/communicator/plugin/dictaccregwizz/DictAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/dictaccregwizz/DictAccountRegistrationWizard.java @@ -406,4 +406,24 @@ public class DictAccountRegistrationWizard { return false; } + + /** + * Nothing to do here in the case of dictionary. + */ + public void webSignup() + { + throw new UnsupportedOperationException( + "The web sign up is not supproted by the dictionary wizard."); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return false; + } } diff --git a/src/net/java/sip/communicator/plugin/gibberishaccregwizz/GibberishAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/gibberishaccregwizz/GibberishAccountRegistrationWizard.java index 6cfe057..be8d146 100644 --- a/src/net/java/sip/communicator/plugin/gibberishaccregwizz/GibberishAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/gibberishaccregwizz/GibberishAccountRegistrationWizard.java @@ -315,4 +315,24 @@ public class GibberishAccountRegistrationWizard { return false; } + + /** + * Nothing to do here in the case of Gibberish. + */ + public void webSignup() + { + throw new UnsupportedOperationException( + "The web sign up is not supproted by the gibberish wizard."); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return false; + } } diff --git a/src/net/java/sip/communicator/plugin/icqaccregwizz/FirstWizardPage.java b/src/net/java/sip/communicator/plugin/icqaccregwizz/FirstWizardPage.java index a33b229..dc5a364 100644 --- a/src/net/java/sip/communicator/plugin/icqaccregwizz/FirstWizardPage.java +++ b/src/net/java/sip/communicator/plugin/icqaccregwizz/FirstWizardPage.java @@ -429,8 +429,7 @@ public class FirstWizardPage */ public void actionPerformed(ActionEvent e) { - IcqAccRegWizzActivator.getBrowserLauncher().openURL( - "https://www.icq.com/register/"); + wizard.webSignup(); } /** diff --git a/src/net/java/sip/communicator/plugin/icqaccregwizz/IcqAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/icqaccregwizz/IcqAccountRegistrationWizard.java index 25b6d01..b7d1d35 100644 --- a/src/net/java/sip/communicator/plugin/icqaccregwizz/IcqAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/icqaccregwizz/IcqAccountRegistrationWizard.java @@ -345,4 +345,24 @@ public class IcqAccountRegistrationWizard { return true; } + + /** + * Opens the browser on the account registration page. + */ + public void webSignup() + { + IcqAccRegWizzActivator.getBrowserLauncher().openURL( + "https://www.icq.com/register/"); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return true; + } } diff --git a/src/net/java/sip/communicator/plugin/ircaccregwizz/IrcAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/ircaccregwizz/IrcAccountRegistrationWizard.java index dc0433c..3da56f8 100644 --- a/src/net/java/sip/communicator/plugin/ircaccregwizz/IrcAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/ircaccregwizz/IrcAccountRegistrationWizard.java @@ -348,4 +348,24 @@ public class IrcAccountRegistrationWizard { return false; } + + /** + * Nothing to do here in the case of IRC. + */ + public void webSignup() + { + throw new UnsupportedOperationException( + "The web sign up is not supproted by the IRC wizard."); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return false; + } } diff --git a/src/net/java/sip/communicator/plugin/jabberaccregwizz/JabberAccRegWizzActivator.java b/src/net/java/sip/communicator/plugin/jabberaccregwizz/JabberAccRegWizzActivator.java index 168ac23..f62c934 100644 --- a/src/net/java/sip/communicator/plugin/jabberaccregwizz/JabberAccRegWizzActivator.java +++ b/src/net/java/sip/communicator/plugin/jabberaccregwizz/JabberAccRegWizzActivator.java @@ -9,6 +9,8 @@ package net.java.sip.communicator.plugin.jabberaccregwizz; import java.util.*; import org.osgi.framework.*; + +import net.java.sip.communicator.service.browserlauncher.*; import net.java.sip.communicator.service.configuration.*; import net.java.sip.communicator.service.gui.*; import net.java.sip.communicator.service.protocol.*; @@ -28,6 +30,8 @@ public class JabberAccRegWizzActivator private static Logger logger = Logger.getLogger( JabberAccRegWizzActivator.class.getName()); + private static BrowserLauncherService browserLauncherService; + private static ConfigurationService configService; private static WizardContainer wizardContainer; @@ -109,4 +113,22 @@ public class JabberAccRegWizzActivator { return uiService; } + + /** + * Returns the <tt>BrowserLauncherService</tt> obtained from the bundle + * context. + * @return the <tt>BrowserLauncherService</tt> obtained from the bundle + * context + */ + public static BrowserLauncherService getBrowserLauncher() { + if (browserLauncherService == null) { + ServiceReference serviceReference = bundleContext + .getServiceReference(BrowserLauncherService.class.getName()); + + browserLauncherService = (BrowserLauncherService) bundleContext + .getService(serviceReference); + } + + return browserLauncherService; + } } diff --git a/src/net/java/sip/communicator/plugin/jabberaccregwizz/JabberAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/jabberaccregwizz/JabberAccountRegistrationWizard.java index 78bc1ac..b3da6df 100644 --- a/src/net/java/sip/communicator/plugin/jabberaccregwizz/JabberAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/jabberaccregwizz/JabberAccountRegistrationWizard.java @@ -376,4 +376,21 @@ public class JabberAccountRegistrationWizard return null; } + + public void webSignup() + { + JabberAccRegWizzActivator.getBrowserLauncher() + .openURL("http://mail.google.com/mail/signup"); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return true; + } } diff --git a/src/net/java/sip/communicator/plugin/jabberaccregwizz/jabberaccregwizz.manifest.mf b/src/net/java/sip/communicator/plugin/jabberaccregwizz/jabberaccregwizz.manifest.mf index 05cc1a4..3e4ba6e 100755 --- a/src/net/java/sip/communicator/plugin/jabberaccregwizz/jabberaccregwizz.manifest.mf +++ b/src/net/java/sip/communicator/plugin/jabberaccregwizz/jabberaccregwizz.manifest.mf @@ -15,6 +15,7 @@ Import-Package: org.osgi.framework, net.java.sip.communicator.service.gui, net.java.sip.communicator.service.gui.event, net.java.sip.communicator.service.fileaccess, + net.java.sip.communicator.service.browserlauncher, javax.naming, javax.naming.directory, javax.xml.parsers, diff --git a/src/net/java/sip/communicator/plugin/msnaccregwizz/MsnAccRegWizzActivator.java b/src/net/java/sip/communicator/plugin/msnaccregwizz/MsnAccRegWizzActivator.java index 2bb773a..c910b4d 100644 --- a/src/net/java/sip/communicator/plugin/msnaccregwizz/MsnAccRegWizzActivator.java +++ b/src/net/java/sip/communicator/plugin/msnaccregwizz/MsnAccRegWizzActivator.java @@ -9,6 +9,8 @@ package net.java.sip.communicator.plugin.msnaccregwizz; import java.util.*; import org.osgi.framework.*; + +import net.java.sip.communicator.service.browserlauncher.*; import net.java.sip.communicator.service.configuration.*; import net.java.sip.communicator.service.gui.*; import net.java.sip.communicator.service.protocol.*; @@ -28,6 +30,8 @@ public class MsnAccRegWizzActivator implements BundleActivator { private static ConfigurationService configService; + private static BrowserLauncherService browserLauncherService; + private static WizardContainer wizardContainer; private static MsnAccountRegistrationWizard msnWizard; @@ -102,4 +106,22 @@ public class MsnAccRegWizzActivator implements BundleActivator { { return uiService; } + + /** + * Returns the <tt>BrowserLauncherService</tt> obtained from the bundle + * context. + * @return the <tt>BrowserLauncherService</tt> obtained from the bundle + * context + */ + public static BrowserLauncherService getBrowserLauncher() { + if (browserLauncherService == null) { + ServiceReference serviceReference = bundleContext + .getServiceReference(BrowserLauncherService.class.getName()); + + browserLauncherService = (BrowserLauncherService) bundleContext + .getService(serviceReference); + } + + return browserLauncherService; + } } diff --git a/src/net/java/sip/communicator/plugin/msnaccregwizz/MsnAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/msnaccregwizz/MsnAccountRegistrationWizard.java index d6a58f2..5141301 100644 --- a/src/net/java/sip/communicator/plugin/msnaccregwizz/MsnAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/msnaccregwizz/MsnAccountRegistrationWizard.java @@ -320,4 +320,24 @@ public class MsnAccountRegistrationWizard { return true; } + + /** + * Opens the browser on the registration page for MSN. + */ + public void webSignup() + { + MsnAccRegWizzActivator.getBrowserLauncher() + .openURL("https://accountservices.passport.net/reg.srf"); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return true; + } } diff --git a/src/net/java/sip/communicator/plugin/msnaccregwizz/msnaccregwizz.manifest.mf b/src/net/java/sip/communicator/plugin/msnaccregwizz/msnaccregwizz.manifest.mf index ed30ead..38774b6 100755 --- a/src/net/java/sip/communicator/plugin/msnaccregwizz/msnaccregwizz.manifest.mf +++ b/src/net/java/sip/communicator/plugin/msnaccregwizz/msnaccregwizz.manifest.mf @@ -14,6 +14,7 @@ Import-Package: org.osgi.framework, net.java.sip.communicator.service.contactlist.event, net.java.sip.communicator.service.gui, net.java.sip.communicator.service.gui.event, + net.java.sip.communicator.service.browserlauncher, javax.swing, javax.swing.event, javax.swing.table, diff --git a/src/net/java/sip/communicator/plugin/rssaccregwizz/RssAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/rssaccregwizz/RssAccountRegistrationWizard.java index de92f82..ffa491f 100644 --- a/src/net/java/sip/communicator/plugin/rssaccregwizz/RssAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/rssaccregwizz/RssAccountRegistrationWizard.java @@ -279,4 +279,24 @@ public class RssAccountRegistrationWizard { return false; } + + /** + * Nothing to do for RSS here. + */ + public void webSignup() + { + throw new UnsupportedOperationException( + "The web sign up is not supported by the RSS wizard."); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return false; + } } diff --git a/src/net/java/sip/communicator/plugin/simpleaccreg/InitialAccountRegistrationFrame.java b/src/net/java/sip/communicator/plugin/simpleaccreg/InitialAccountRegistrationFrame.java index 7f6aafa..a79f52d 100644 --- a/src/net/java/sip/communicator/plugin/simpleaccreg/InitialAccountRegistrationFrame.java +++ b/src/net/java/sip/communicator/plugin/simpleaccreg/InitialAccountRegistrationFrame.java @@ -142,21 +142,26 @@ public class InitialAccountRegistrationFrame private JPanel inputRegisterPanel = new JPanel(new BorderLayout()); - private JTextArea descriptionArea = new JTextArea(); + private JTextArea descriptionArea = new JTextArea(); + + private JLabel signupLabel + = new JLabel("<html><a href=''>" + + Resources.getString("signup") + + "</a></html>", JLabel.RIGHT); private AccountRegistrationWizard wizard; public AccountRegistrationPanel( - AccountRegistrationWizard wizard, + AccountRegistrationWizard accountWizard, boolean isPreferredWizard) { super(new BorderLayout(5, 5)); - this.wizard = wizard; + this.wizard = accountWizard; this.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10)); - this.setPreferredSize(new Dimension(230, 140)); + this.setPreferredSize(new Dimension(230, 150)); this.setOpaque(false); @@ -172,6 +177,9 @@ public class InitialAccountRegistrationFrame this.inputRegisterPanel.add(inputPanel, BorderLayout.NORTH); + if (wizard.isWebSignupSupported()) + this.inputRegisterPanel.add(signupLabel, BorderLayout.SOUTH); + this.inputPanel.add(labelsPanel, BorderLayout.WEST); this.inputPanel.add(fieldsPanel, BorderLayout.CENTER); @@ -179,6 +187,24 @@ public class InitialAccountRegistrationFrame this.iconDescriptionPanel.add( protocolLabel, BorderLayout.NORTH); + this.signupLabel.setFont(signupLabel.getFont().deriveFont(10f)); + this.signupLabel.addMouseListener(new MouseAdapter() + { + public void mousePressed(MouseEvent arg0) + { + try + { + wizard.webSignup(); + } + catch (UnsupportedOperationException e) + { + // This should not happen, because we check if the + // operation is supported, before adding the sign up. + logger.error("The web sign up is not supported.", e); + } + } + }); + this.protocolLabel.setFont( protocolLabel.getFont().deriveFont(Font.BOLD, 14f)); this.usernameExampleLabel.setForeground(Color.DARK_GRAY); diff --git a/src/net/java/sip/communicator/plugin/sipaccregwizz/SIPAccRegWizzActivator.java b/src/net/java/sip/communicator/plugin/sipaccregwizz/SIPAccRegWizzActivator.java index abc3e07..bbd1e65 100644 --- a/src/net/java/sip/communicator/plugin/sipaccregwizz/SIPAccRegWizzActivator.java +++ b/src/net/java/sip/communicator/plugin/sipaccregwizz/SIPAccRegWizzActivator.java @@ -8,6 +8,8 @@ package net.java.sip.communicator.plugin.sipaccregwizz; import java.util.*; import org.osgi.framework.*; + +import net.java.sip.communicator.service.browserlauncher.*; import net.java.sip.communicator.service.configuration.*; import net.java.sip.communicator.service.gui.*; import net.java.sip.communicator.service.protocol.*; @@ -31,6 +33,8 @@ public class SIPAccRegWizzActivator private static WizardContainer wizardContainer; + private static BrowserLauncherService browserLauncherService; + private static SIPAccountRegistrationWizard sipWizard; private static UIService uiService; @@ -109,4 +113,22 @@ public class SIPAccRegWizzActivator { return uiService; } + + /** + * Returns the <tt>BrowserLauncherService</tt> obtained from the bundle + * context. + * @return the <tt>BrowserLauncherService</tt> obtained from the bundle + * context + */ + public static BrowserLauncherService getBrowserLauncher() { + if (browserLauncherService == null) { + ServiceReference serviceReference = bundleContext + .getServiceReference(BrowserLauncherService.class.getName()); + + browserLauncherService = (BrowserLauncherService) bundleContext + .getService(serviceReference); + } + + return browserLauncherService; + } } diff --git a/src/net/java/sip/communicator/plugin/sipaccregwizz/SIPAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/sipaccregwizz/SIPAccountRegistrationWizard.java index 80c8dbc..1ab9f05 100644 --- a/src/net/java/sip/communicator/plugin/sipaccregwizz/SIPAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/sipaccregwizz/SIPAccountRegistrationWizard.java @@ -418,4 +418,21 @@ public class SIPAccountRegistrationWizard return null; } + + public void webSignup() + { + SIPAccRegWizzActivator.getBrowserLauncher() + .openURL("http://serweb.iptel.org/user/reg/index.php"); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return true; + } } diff --git a/src/net/java/sip/communicator/plugin/sipaccregwizz/sipaccregwizz.manifest.mf b/src/net/java/sip/communicator/plugin/sipaccregwizz/sipaccregwizz.manifest.mf index bc8a179..4ba1f49 100755 --- a/src/net/java/sip/communicator/plugin/sipaccregwizz/sipaccregwizz.manifest.mf +++ b/src/net/java/sip/communicator/plugin/sipaccregwizz/sipaccregwizz.manifest.mf @@ -14,6 +14,7 @@ Import-Package: org.osgi.framework, net.java.sip.communicator.service.contactlist.event, net.java.sip.communicator.service.gui, net.java.sip.communicator.service.gui.event, + net.java.sip.communicator.service.browserlauncher, javax.swing, javax.swing.event, javax.swing.table, diff --git a/src/net/java/sip/communicator/plugin/sshaccregwizz/SSHAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/sshaccregwizz/SSHAccountRegistrationWizard.java index c04a3ce..beb937b 100644 --- a/src/net/java/sip/communicator/plugin/sshaccregwizz/SSHAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/sshaccregwizz/SSHAccountRegistrationWizard.java @@ -288,4 +288,24 @@ public class SSHAccountRegistrationWizard { return false; } + + /** + * Nothing to do here in the case of SSH. + */ + public void webSignup() + { + throw new UnsupportedOperationException( + "The web sign up is not supported by the SSH wizard."); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return false; + } } diff --git a/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccRegWizzActivator.java b/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccRegWizzActivator.java index bc5db85..ef2a226 100644 --- a/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccRegWizzActivator.java +++ b/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccRegWizzActivator.java @@ -8,6 +8,7 @@ package net.java.sip.communicator.plugin.yahooaccregwizz; import java.util.*; +import net.java.sip.communicator.service.browserlauncher.*; import net.java.sip.communicator.service.configuration.*; import net.java.sip.communicator.service.gui.*; import net.java.sip.communicator.service.protocol.*; @@ -29,6 +30,8 @@ public class YahooAccRegWizzActivator implements BundleActivator { private static ConfigurationService configService; + private static BrowserLauncherService browserLauncherService; + private static WizardContainer wizardContainer; private static YahooAccountRegistrationWizard yahooWizard; @@ -102,4 +105,22 @@ public class YahooAccRegWizzActivator implements BundleActivator { { return uiService; } + + /** + * Returns the <tt>BrowserLauncherService</tt> obtained from the bundle + * context. + * @return the <tt>BrowserLauncherService</tt> obtained from the bundle + * context + */ + public static BrowserLauncherService getBrowserLauncher() { + if (browserLauncherService == null) { + ServiceReference serviceReference = bundleContext + .getServiceReference(BrowserLauncherService.class.getName()); + + browserLauncherService = (BrowserLauncherService) bundleContext + .getService(serviceReference); + } + + return browserLauncherService; + } } diff --git a/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccountRegistrationWizard.java index 5f6e915..3fd82eb 100644 --- a/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccountRegistrationWizard.java @@ -319,4 +319,21 @@ public class YahooAccountRegistrationWizard { return true; } + + public void webSignup() + { + YahooAccRegWizzActivator.getBrowserLauncher() + .openURL("https://edit.yahoo.com/registration"); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return true; + } } diff --git a/src/net/java/sip/communicator/plugin/yahooaccregwizz/yahooaccregwizz.manifest.mf b/src/net/java/sip/communicator/plugin/yahooaccregwizz/yahooaccregwizz.manifest.mf index 787f3e2..8377e3e 100644 --- a/src/net/java/sip/communicator/plugin/yahooaccregwizz/yahooaccregwizz.manifest.mf +++ b/src/net/java/sip/communicator/plugin/yahooaccregwizz/yahooaccregwizz.manifest.mf @@ -14,6 +14,7 @@ Import-Package: org.osgi.framework, net.java.sip.communicator.service.contactlist.event, net.java.sip.communicator.service.gui, net.java.sip.communicator.service.gui.event, + net.java.sip.communicator.service.browserlauncher, javax.swing, javax.swing.event, javax.swing.table, diff --git a/src/net/java/sip/communicator/plugin/zeroconfaccregwizz/ZeroconfAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/zeroconfaccregwizz/ZeroconfAccountRegistrationWizard.java index 6da3c02..b7cd6be 100644 --- a/src/net/java/sip/communicator/plugin/zeroconfaccregwizz/ZeroconfAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/zeroconfaccregwizz/ZeroconfAccountRegistrationWizard.java @@ -344,4 +344,24 @@ public class ZeroconfAccountRegistrationWizard { return false; } + + /** + * Nothing to do here in the case of Bonjour. + */ + public void webSignup() + { + throw new UnsupportedOperationException( + "The web sign up is not supported by the Zeroconf wizard."); + } + + /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported() + { + return false; + } } diff --git a/src/net/java/sip/communicator/service/gui/AccountRegistrationWizard.java b/src/net/java/sip/communicator/service/gui/AccountRegistrationWizard.java index 2e9d536..72b6fb5 100644 --- a/src/net/java/sip/communicator/service/gui/AccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/service/gui/AccountRegistrationWizard.java @@ -30,8 +30,6 @@ import net.java.sip.communicator.service.protocol.*; */ public interface AccountRegistrationWizard { - public static final String PREFERRED_WIZARD = "PreferredWizard"; - /** * Returns the protocol icon that will be shown on the left of the protocol * name in the list, where user will choose the protocol to register to. @@ -135,6 +133,22 @@ public interface AccountRegistrationWizard String password); /** + * Returns <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise. + * @return <code>true</code> if the web sign up is supported by the current + * implementation, <code>false</code> - otherwise + */ + public boolean isWebSignupSupported(); + + /** + * Defines the operation that will be executed when user clicks on the + * "Sign up" link. + * @throws UnsupportedOperationException if the web sign up operation is + * not supported by the current implementation. + */ + public void webSignup() throws UnsupportedOperationException; + + /** * Returns the preferred dimensions of this wizard. * * @return the preferred dimensions of this wizard. |