diff options
author | Damian Minkov <damencho@jitsi.org> | 2014-12-09 17:43:14 +0200 |
---|---|---|
committer | Damian Minkov <damencho@jitsi.org> | 2014-12-09 17:43:14 +0200 |
commit | 0a9a8ba6a260d9e013d39e25f732a4f7777f77aa (patch) | |
tree | 465908d641f5ac9c144699363eba992252cbd023 /src/net/java | |
parent | 3349f8a0d44d989736780dc72a8a7e362b9c7956 (diff) | |
download | jitsi-0a9a8ba6a260d9e013d39e25f732a4f7777f77aa.zip jitsi-0a9a8ba6a260d9e013d39e25f732a4f7777f77aa.tar.gz jitsi-0a9a8ba6a260d9e013d39e25f732a4f7777f77aa.tar.bz2 |
Adds an option to disable advanced configuration for accounts which do not need it.
Diffstat (limited to 'src/net/java')
4 files changed, 35 insertions, 0 deletions
diff --git a/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java b/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java index 5cc84a9..36860c9 100644 --- a/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java +++ b/src/net/java/sip/communicator/impl/gui/main/account/NewAccountDialog.java @@ -363,6 +363,11 @@ public class NewAccountDialog if (!isEmptyAccountRegistrationWizard) getRootPane().setDefaultButton(addAccountButton); + if(!wizard.isAdvancedConfigurationEnabled()) + advancedButton.setVisible(false); + else if(!advancedButton.isVisible()) + advancedButton.setVisible(true); + accountPanel.revalidate(); accountPanel.repaint(); diff --git a/src/net/java/sip/communicator/plugin/facebookaccregwizz/FacebookAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/facebookaccregwizz/FacebookAccountRegistrationWizard.java index 6716214..26c57b4 100644 --- a/src/net/java/sip/communicator/plugin/facebookaccregwizz/FacebookAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/facebookaccregwizz/FacebookAccountRegistrationWizard.java @@ -276,4 +276,14 @@ public class FacebookAccountRegistrationWizard {
return null;
}
+
+ /**
+ * Whether the advanced configuration is enabled. Gives an option
+ * to disable/hide advanced config button.
+ * @return whether the advanced configuration is enabled.
+ */
+ public boolean isAdvancedConfigurationEnabled()
+ {
+ return false;
+ }
}
diff --git a/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccountRegistrationWizard.java b/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccountRegistrationWizard.java index 50b1cc8..81350a3 100644 --- a/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/plugin/yahooaccregwizz/YahooAccountRegistrationWizard.java @@ -354,4 +354,14 @@ public class YahooAccountRegistrationWizard return firstWizardPage.getSimpleForm(); } + + /** + * Whether the advanced configuration is enabled. Gives an option + * to disable/hide advanced config button. + * @return whether the advanced configuration is enabled. + */ + public boolean isAdvancedConfigurationEnabled() + { + 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 a000848..740f5b9 100644 --- a/src/net/java/sip/communicator/service/gui/AccountRegistrationWizard.java +++ b/src/net/java/sip/communicator/service/gui/AccountRegistrationWizard.java @@ -247,6 +247,16 @@ public abstract class AccountRegistrationWizard } /** + * Whether the advanced configuration is enabled. Gives an option + * to disable/hide advanced config button. + * @return whether the advanced configuration is enabled. + */ + public boolean isAdvancedConfigurationEnabled() + { + return true; + } + + /** * Returns the wizard container, where all pages are added. * * @return the wizard container, where all pages are added |