Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorspingel2010-04-20 17:09:50 -0400
committerspingel2010-04-20 17:09:50 -0400
commit66528ef6b248b5730359d08374d5972f356c077b (patch)
tree1a4d82d5f937b4da3fa7a856accf9469243c80c6 /bundles/org.eclipse.equinox.p2.ui.discovery
parentf5bc86cd7644f6d2ab033443204a236a02eca722 (diff)
downloadrt.equinox.p2-66528ef6b248b5730359d08374d5972f356c077b.tar.gz
rt.equinox.p2-66528ef6b248b5730359d08374d5972f356c077b.tar.xz
rt.equinox.p2-66528ef6b248b5730359d08374d5972f356c077b.zip
bug 309614 - [discovery] 'No Connectors Found' message should be optional, configurable
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.ui.discovery')
-rw-r--r--bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/CatalogViewer.java22
-rw-r--r--bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/messages.properties16
2 files changed, 21 insertions, 17 deletions
diff --git a/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/CatalogViewer.java b/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/CatalogViewer.java
index 245f6e405..21b0c22a1 100644
--- a/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/CatalogViewer.java
+++ b/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/CatalogViewer.java
@@ -235,20 +235,24 @@ public class CatalogViewer extends FilteredViewer {
}
protected void catalogUpdated(boolean wasCancelled, boolean wasError) {
- if (catalog != null && !wasCancelled) {
- int categoryWithConnectorCount = 0;
- for (CatalogCategory category : catalog.getCategories()) {
- categoryWithConnectorCount += category.getItems().size();
- }
- if (categoryWithConnectorCount == 0 && !wasError) {
- // nothing was discovered: notify the user
- MessageDialog.openWarning(getShell(), Messages.ConnectorDiscoveryWizardMainPage_noConnectorsFound, Messages.ConnectorDiscoveryWizardMainPage_noConnectorsFound_description);
- }
+ if (catalog != null && !wasCancelled && !wasError) {
+ doCheckCatalog();
}
viewer.setInput(catalog);
selectionProvider.setSelection(StructuredSelection.EMPTY);
}
+ protected void doCheckCatalog() {
+ int categoryWithConnectorCount = 0;
+ for (CatalogCategory category : catalog.getCategories()) {
+ categoryWithConnectorCount += category.getItems().size();
+ }
+ if (categoryWithConnectorCount == 0) {
+ // nothing was discovered: notify the user
+ MessageDialog.openWarning(getShell(), Messages.ConnectorDiscoveryWizardMainPage_noConnectorsFound, Messages.ConnectorDiscoveryWizardMainPage_noConnectorsFound_description);
+ }
+ }
+
private IStatus computeStatus(InvocationTargetException e, String message) {
Throwable cause = e.getCause();
if (cause.getMessage() != null) {
diff --git a/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/messages.properties b/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/messages.properties
index e530b29fb..bdcde965d 100644
--- a/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/messages.properties
+++ b/bundles/org.eclipse.equinox.p2.ui.discovery/src/org/eclipse/equinox/internal/p2/ui/discovery/wizards/messages.properties
@@ -8,14 +8,14 @@
# Contributors:
# Tasktop Technologies - initial API and implementation
###############################################################################
-ConnectorDescriptorToolTip_detailsLink=<a>Learn More</a>
+ConnectorDescriptorToolTip_detailsLink=<a>Learn more</a>
ConnectorDescriptorToolTip_detailsLink_tooltip=Open {0} in an external browser
ConnectorDiscoveryWizard_installProblems=Problems occurred while performing installation: {0}
-ConnectorDiscoveryWizardMainPage_connectorDiscovery=Mylyn Connector Discovery
+ConnectorDiscoveryWizardMainPage_connectorDiscovery=Install Extensions
ConnectorDiscoveryWizardMainPage_filterLabel=Find:
ConnectorDiscoveryWizardMainPage_message_with_cause={0}: {1}
-ConnectorDiscoveryWizardMainPage_noConnectorsFound=No Connectors Found
-ConnectorDiscoveryWizardMainPage_noConnectorsFound_description=Connector discovery completed without finding any connectors. Please check your Internet connection and try again.
+ConnectorDiscoveryWizardMainPage_noConnectorsFound=No Extensions Found
+ConnectorDiscoveryWizardMainPage_noConnectorsFound_description=Discovery completed without finding any extensions. Please check your network connection and try again.
ConnectorDiscoveryWizardMainPage_pageDescription=\
Select extensions to install. Press Finish to proceed with installation.\n\
Press the information button to see a detailed overview and a link to more information.
@@ -23,17 +23,17 @@ ConnectorDiscoveryWizardMainPage_provider_and_license=by {0}, {1}
ConnectorDiscoveryWizardMainPage_tooltip_showOverview=Show Overview
ConnectorDiscoveryWizardMainPage_unexpectedException=Unexpected exception
ConnectorDiscoveryWizardMainPage_warningMessageConnectorUnavailable=Sorry, {0} is unavailable. Please try again later.
-ConnectorDiscoveryWizardMainPage_warningTitleConnectorUnavailable=Connector Unavailable
+ConnectorDiscoveryWizardMainPage_warningTitleConnectorUnavailable=Extension Unavailable
DiscoveryItem_Connector_already_installed_Error_Message={0} is already installed.
-DiscoveryItem_Connector_already_installed_Error_Title=Install Connector
+DiscoveryItem_Connector_already_installed_Error_Title=Install Extension
DiscoveryItem_Extension_installed={0} (installed)
DiscoveryViewer_Certification_Label0=by {0}, {1}, <a>Certified</a>
DiscoveryViewer_Show_Installed=Show Installed
DiscoveryWizard_Install_Window_Title=Install
InstallConnectorsJob_commaSeparator=,
-InstallConnectorsJob_connectorsNotAvailable=The following connectors are not available: {0}
+InstallConnectorsJob_connectorsNotAvailable=The following extensions are not available: {0}
InstallConnectorsJob_questionProceed=Proceed With Installation?
-InstallConnectorsJob_questionProceed_long=The following connectors are not available: {0}\nProceed with the installation anyways?
+InstallConnectorsJob_questionProceed_long=The following extensions are not available: {0}\nProceed with the installation anyways?
InstallConnectorsJob_task_configuring=Configuring installation selection
InstallConnectorsJob_unexpectedError_url=Unexpected error handling repository URL
PrepareInstallProfileJob_notFoundDescriptorDetail={0} (id={1}, site={2})

Back to the top