JBoss Tools SVN: r39287 - trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext.
by jbosstools-commits@lists.jboss.org
Author: jgargula
Date: 2012-03-05 11:15:22 -0500 (Mon, 05 Mar 2012)
New Revision: 39287
Modified:
trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotExt.java
Log:
Fixed waiting for shell if it is disposed.
Modified: trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotExt.java
===================================================================
--- trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotExt.java 2012-03-05 14:14:14 UTC (rev 39286)
+++ trunk/tests/plugins/org.jboss.tools.ui.bot.ext/src/org/jboss/tools/ui/bot/ext/SWTBotExt.java 2012-03-05 16:15:22 UTC (rev 39287)
@@ -244,8 +244,13 @@
for (int i = 0; i <= ATTEMPTS_TIMEOUT; i++) {
for (SWTBotShell shell : shells()) {
- if (shellTitle.equals(shell.getText())) {
- return shell;
+ try {
+ if (shellTitle.equals(shell.getText())) {
+ return shell;
+ }
+ } catch (WidgetNotFoundException wnfe) {
+ log.info("Waiting for shell: " + wnfe.getMessage());
+ // do nothing more but continue in loop
}
}
if (i < ATTEMPTS_TIMEOUT) {
12 years, 10 months
JBoss Tools SVN: r39286 - branches/jbosstools-3.3.0.Beta1/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui.
by jbosstools-commits@lists.jboss.org
Author: snjeza
Date: 2012-03-05 09:14:14 -0500 (Mon, 05 Mar 2012)
New Revision: 39286
Modified:
branches/jbosstools-3.3.0.Beta1/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java
Log:
JBDS-2048 Runtime detection: Location not added to the paths list
Modified: branches/jbosstools-3.3.0.Beta1/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java
===================================================================
--- branches/jbosstools-3.3.0.Beta1/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java 2012-03-05 14:12:23 UTC (rev 39285)
+++ branches/jbosstools-3.3.0.Beta1/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java 2012-03-05 14:14:14 UTC (rev 39286)
@@ -34,10 +34,8 @@
import org.jboss.tools.runtime.core.JBossRuntimeLocator;
import org.jboss.tools.runtime.core.RuntimeCoreActivator;
import org.jboss.tools.runtime.core.model.IRuntimeDetector;
-import org.jboss.tools.runtime.core.model.RuntimePath;
import org.jboss.tools.runtime.core.model.RuntimeDefinition;
-import org.jboss.tools.runtime.ui.RuntimeUIActivator;
-import org.osgi.framework.Bundle;
+import org.jboss.tools.runtime.core.model.RuntimePath;
public class JBossRuntimeStartup {
@@ -48,38 +46,40 @@
private static final String LOCATIONS_FILE_CONFIGURATION = "../../studio/" + LOCATIONS_FILE_NAME; //$NON-NLS-1$
public static void initializeRuntimes(IProgressMonitor monitor) {
- if (isJBDS()) {
- final Set<RuntimePath> runtimePaths = new HashSet<RuntimePath>();
- parseRuntimeLocationsFile(runtimePaths);
- try {
- String configuration = getConfiguration();
- File directory = new File(configuration, JBOSS_EAP_HOME);
- if (directory.isDirectory()) {
- RuntimePath runtimePath = new RuntimePath(directory.getAbsolutePath());
- runtimePaths.add(runtimePath);
- }
- } catch (IOException e) {
- RuntimeUIActivator.log(e);
- }
-
- JBossRuntimeLocator locator = new JBossRuntimeLocator();
- for (RuntimePath runtimePath : runtimePaths) {
+ JBossRuntimeLocator locator = new JBossRuntimeLocator();
+ try {
+ String configuration = getConfiguration();
+ File directory = new File(configuration, JBOSS_EAP_HOME);
+ if (directory.isDirectory()) {
+ RuntimePath runtimePath = new RuntimePath(
+ directory.getAbsolutePath());
List<RuntimeDefinition> serverDefinitions = locator
.searchForRuntimes(runtimePath.getPath(), monitor);
runtimePath.getServerDefinitions().clear();
for (RuntimeDefinition serverDefinition : serverDefinitions) {
serverDefinition.setRuntimePath(runtimePath);
}
- runtimePath.getServerDefinitions().addAll(serverDefinitions);
initializeRuntimes(serverDefinitions);
}
- if (runtimePaths.size() > 0) {
- RuntimeUIActivator.getDefault().getRuntimePaths().addAll(runtimePaths);
- RuntimeUIActivator.getDefault().saveRuntimePaths();
- }
-
-
+ } catch (IOException e) {
+ RuntimeUIActivator.log(e);
}
+ final Set<RuntimePath> runtimePaths = new HashSet<RuntimePath>();
+ parseRuntimeLocationsFile(runtimePaths);
+ for (RuntimePath runtimePath : runtimePaths) {
+ List<RuntimeDefinition> serverDefinitions = locator
+ .searchForRuntimes(runtimePath.getPath(), monitor);
+ runtimePath.getServerDefinitions().clear();
+ for (RuntimeDefinition serverDefinition : serverDefinitions) {
+ serverDefinition.setRuntimePath(runtimePath);
+ }
+ runtimePath.getServerDefinitions().addAll(serverDefinitions);
+ }
+ if (runtimePaths.size() > 0) {
+ RuntimeUIActivator.getDefault().getRuntimePaths()
+ .addAll(runtimePaths);
+ RuntimeUIActivator.getDefault().saveRuntimePaths();
+ }
}
public static void initializeRuntimes(List<RuntimeDefinition> serverDefinitions) {
@@ -91,13 +91,6 @@
}
refreshCommonNavigator();
}
-
-
- private static boolean isJBDS() {
- Bundle jbdsProduct = Platform.getBundle("com.jboss.jbds.product");
- //return jbdsProduct != null;
- return true;
- }
private static void refreshCommonNavigator() {
// https://jira.jboss.org/jira/browse/JBDS-1091
12 years, 10 months
JBoss Tools SVN: r39285 - trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui.
by jbosstools-commits@lists.jboss.org
Author: snjeza
Date: 2012-03-05 09:12:23 -0500 (Mon, 05 Mar 2012)
New Revision: 39285
Modified:
trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java
Log:
JBDS-2048 Runtime detection: Location not added to the paths list
Modified: trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java
===================================================================
--- trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java 2012-03-05 14:08:18 UTC (rev 39284)
+++ trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java 2012-03-05 14:12:23 UTC (rev 39285)
@@ -34,10 +34,8 @@
import org.jboss.tools.runtime.core.JBossRuntimeLocator;
import org.jboss.tools.runtime.core.RuntimeCoreActivator;
import org.jboss.tools.runtime.core.model.IRuntimeDetector;
-import org.jboss.tools.runtime.core.model.RuntimePath;
import org.jboss.tools.runtime.core.model.RuntimeDefinition;
-import org.jboss.tools.runtime.ui.RuntimeUIActivator;
-import org.osgi.framework.Bundle;
+import org.jboss.tools.runtime.core.model.RuntimePath;
public class JBossRuntimeStartup {
@@ -48,40 +46,40 @@
private static final String LOCATIONS_FILE_CONFIGURATION = "../../studio/" + LOCATIONS_FILE_NAME; //$NON-NLS-1$
public static void initializeRuntimes(IProgressMonitor monitor) {
- if (isJBDS()) {
- JBossRuntimeLocator locator = new JBossRuntimeLocator();
- try {
- String configuration = getConfiguration();
- File directory = new File(configuration, JBOSS_EAP_HOME);
- if (directory.isDirectory()) {
- RuntimePath runtimePath = new RuntimePath(directory.getAbsolutePath());
- List<RuntimeDefinition> serverDefinitions = locator
- .searchForRuntimes(runtimePath.getPath(), monitor);
- runtimePath.getServerDefinitions().clear();
- for (RuntimeDefinition serverDefinition : serverDefinitions) {
- serverDefinition.setRuntimePath(runtimePath);
- }
- initializeRuntimes(serverDefinitions);
- }
- } catch (IOException e) {
- RuntimeUIActivator.log(e);
- }
- final Set<RuntimePath> runtimePaths = new HashSet<RuntimePath>();
- parseRuntimeLocationsFile(runtimePaths);
- for (RuntimePath runtimePath : runtimePaths) {
+ JBossRuntimeLocator locator = new JBossRuntimeLocator();
+ try {
+ String configuration = getConfiguration();
+ File directory = new File(configuration, JBOSS_EAP_HOME);
+ if (directory.isDirectory()) {
+ RuntimePath runtimePath = new RuntimePath(
+ directory.getAbsolutePath());
List<RuntimeDefinition> serverDefinitions = locator
.searchForRuntimes(runtimePath.getPath(), monitor);
runtimePath.getServerDefinitions().clear();
for (RuntimeDefinition serverDefinition : serverDefinitions) {
serverDefinition.setRuntimePath(runtimePath);
}
- runtimePath.getServerDefinitions().addAll(serverDefinitions);
+ initializeRuntimes(serverDefinitions);
}
- if (runtimePaths.size() > 0) {
- RuntimeUIActivator.getDefault().getRuntimePaths().addAll(runtimePaths);
- RuntimeUIActivator.getDefault().saveRuntimePaths();
- }
+ } catch (IOException e) {
+ RuntimeUIActivator.log(e);
}
+ final Set<RuntimePath> runtimePaths = new HashSet<RuntimePath>();
+ parseRuntimeLocationsFile(runtimePaths);
+ for (RuntimePath runtimePath : runtimePaths) {
+ List<RuntimeDefinition> serverDefinitions = locator
+ .searchForRuntimes(runtimePath.getPath(), monitor);
+ runtimePath.getServerDefinitions().clear();
+ for (RuntimeDefinition serverDefinition : serverDefinitions) {
+ serverDefinition.setRuntimePath(runtimePath);
+ }
+ runtimePath.getServerDefinitions().addAll(serverDefinitions);
+ }
+ if (runtimePaths.size() > 0) {
+ RuntimeUIActivator.getDefault().getRuntimePaths()
+ .addAll(runtimePaths);
+ RuntimeUIActivator.getDefault().saveRuntimePaths();
+ }
}
public static void initializeRuntimes(List<RuntimeDefinition> serverDefinitions) {
@@ -93,13 +91,6 @@
}
refreshCommonNavigator();
}
-
-
- private static boolean isJBDS() {
- Bundle jbdsProduct = Platform.getBundle("com.jboss.jbds.product");
- //return jbdsProduct != null;
- return true;
- }
private static void refreshCommonNavigator() {
// https://jira.jboss.org/jira/browse/JBDS-1091
12 years, 10 months
JBoss Tools SVN: r39284 - branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2012-03-05 09:08:18 -0500 (Mon, 05 Mar 2012)
New Revision: 39284
Modified:
branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/GitCloningSettingsWizardPage.java
branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/GitCloningSettingsWizardPageModel.java
Log:
[JBIDE-11132] simplified flow, now always setting remote names to "openshift" (for existing projects") and "origin" (for new projects)
Modified: branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/GitCloningSettingsWizardPage.java
===================================================================
--- branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/GitCloningSettingsWizardPage.java 2012-03-05 13:33:01 UTC (rev 39283)
+++ branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/GitCloningSettingsWizardPage.java 2012-03-05 14:08:18 UTC (rev 39284)
@@ -134,7 +134,6 @@
useDefaultRemoteNameButton = new Button(cloneGroup, SWT.CHECK);
useDefaultRemoteNameButton.setText("Use default remote name");
GridDataFactory.fillDefaults().align(SWT.LEFT, SWT.CENTER).span(3, 1).applyTo(useDefaultRemoteNameButton);
- useDefaultRemoteNameButton.addSelectionListener(onDefaultRemoteName());
this.remoteNameLabel = new Label(cloneGroup, SWT.NONE);
remoteNameLabel.setText("Remote name:");
@@ -205,16 +204,6 @@
};
}
- private SelectionListener onDefaultRemoteName() {
- return new SelectionAdapter() {
-
- @Override
- public void widgetSelected(SelectionEvent e) {
- pageModel.resetRemoteName();
- }
- };
- }
-
private SelectionAdapter onSshPrefs() {
return new SelectionAdapter() {
@@ -226,10 +215,6 @@
}
protected void onPageActivated(DataBindingContext dbc) {
- // allow to enable a proj only for as7 openshift applications
- // pageModel.resetRepositoryPath();
- pageModel.resetRemoteName();
- // pageModel.refreshApplicationName();
enableWidgets(pageModel.isNewProject());
}
Modified: branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/GitCloningSettingsWizardPageModel.java
===================================================================
--- branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/GitCloningSettingsWizardPageModel.java 2012-03-05 13:33:01 UTC (rev 39283)
+++ branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/GitCloningSettingsWizardPageModel.java 2012-03-05 14:08:18 UTC (rev 39284)
@@ -88,28 +88,11 @@
wizardModel.setRepositoryPath(repositoryPath));
}
- // public void resetRepositoryPath() {
- // if (wizardModel.isNewProject()
- // || getRepositoryPath() == null) {
- // setRepositoryPath(getDefaultRepositoryPath());
- // }
- // }
-
- public void resetRemoteName() {
+ private void resetRemoteName() {
if (!wizardModel.isNewProject()) {
- // if existing project and remote name is still 'origin'
- // -> switch to 'openshift' (leave as is if existing project and
- // remote name != 'origin')
- if (NEW_PROJECT_REMOTE_NAME_DEFAULT.equals(getRemoteName())) {
setRemoteName(EXISTING_PROJECT_REMOTE_NAME_DEFAULT);
- }
} else {
- // if new project and remote name is not 'origin'
- // -> restore 'origin'
- if (!NEW_PROJECT_REMOTE_NAME_DEFAULT.equals(getRemoteName())) {
- setUseDefaultRemoteName(true);
setRemoteName(NEW_PROJECT_REMOTE_NAME_DEFAULT);
- }
}
}
@@ -148,8 +131,6 @@
firePropertyChange(PROPERTY_USE_DEFAULT_REMOTE_NAME, useDefaultRemoteName,
this.useDefaultRemoteName = useDefaultRemoteName);
if (useDefaultRemoteName) {
- // setRemoteName(isNewProject() ? NEW_PROJECT_REMOTE_NAME_DEFAULT :
- // EXISTING_PROJECT_REMOTE_NAME_DEFAULT);
resetRemoteName();
}
}
12 years, 10 months
JBoss Tools SVN: r39283 - branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2012-03-05 08:33:01 -0500 (Mon, 05 Mar 2012)
New Revision: 39283
Modified:
branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/OpenShiftExpressApplicationWizardModel.java
Log:
[JBIDE-10511] removed check for existing server adapter (was: checking for existing server adapter, creating a new server adapter if none was found. Comparison is erroneous & blocks advanced use cases, have to always create new server adapter)
Modified: branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/OpenShiftExpressApplicationWizardModel.java
===================================================================
--- branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/OpenShiftExpressApplicationWizardModel.java 2012-03-05 13:15:08 UTC (rev 39282)
+++ branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/OpenShiftExpressApplicationWizardModel.java 2012-03-05 13:33:01 UTC (rev 39283)
@@ -16,7 +16,6 @@
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.osgi.util.NLS;
import org.eclipse.wst.server.core.IRuntime;
-import org.eclipse.wst.server.core.IServer;
import org.eclipse.wst.server.core.IServerType;
import org.eclipse.wst.server.core.ServerCore;
import org.jboss.tools.common.ui.databinding.ObservableUIPojo;
@@ -83,28 +82,9 @@
, getRemoteName()
, getRepositoryFile())
.execute(monitor);
- String appName = getApplication().getName();
- String host = getApplication().getApplicationUrl();
- IServer found = findServer(appName, host);
- if( found == null )
- createServerAdapter(monitor, importedProjects);
- else {
- new ServerAdapterFactory().addModules(found, importedProjects, monitor);
- }
+ createServerAdapter(monitor, importedProjects);
}
- private IServer findServer(String appName, String host) {
- IServer[] all = ServerCore.getServers();
- for( int i = 0; i < all.length; i++ ) {
- String host1 = all[i].getHost();
- String app1 = ExpressServerUtils.getExpressApplicationName(all[i]);
- if( (host.endsWith("/" + host1 + "/") || (host.endsWith("/" + host1)))
- && appName.equals(app1))
- return all[i];
- }
- return null;
- }
-
/**
* Enables the user chosen, unshared project to be used on the chosen
* OpenShift application. Clones the application git repository, copies the
12 years, 10 months
JBoss Tools SVN: r39282 - branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2012-03-05 08:15:08 -0500 (Mon, 05 Mar 2012)
New Revision: 39282
Modified:
branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/AbstractImportApplicationOperation.java
branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureGitSharedProject.java
branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureUnsharedProject.java
Log:
[JBIDE-11152] now adding openshift profile to pom for unshared projects (was: only happened for git-shared projects)
Modified: branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/AbstractImportApplicationOperation.java
===================================================================
--- branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/AbstractImportApplicationOperation.java 2012-03-05 13:04:57 UTC (rev 39281)
+++ branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/AbstractImportApplicationOperation.java 2012-03-05 13:15:08 UTC (rev 39282)
@@ -33,6 +33,7 @@
import org.jboss.tools.openshift.egit.core.EGitUtils;
import org.jboss.tools.openshift.egit.core.GitIgnore;
import org.jboss.tools.openshift.egit.ui.util.EGitUIUtils;
+import org.jboss.tools.openshift.express.internal.ui.OpenShiftUIActivator;
import com.openshift.express.client.IApplication;
import com.openshift.express.client.OpenShiftException;
@@ -222,5 +223,17 @@
.add(".factorypath");
return gitIgnore.write(monitor);
}
+
+ protected IResource setupOpenShiftMavenProfile(IProject project, IProgressMonitor monitor) throws CoreException {
+ if(!OpenShiftMavenProfile.isMavenProject(project)) {
+ return null;
+ }
+ OpenShiftMavenProfile profile = new OpenShiftMavenProfile(project, OpenShiftUIActivator.PLUGIN_ID);
+ if (profile.existsInPom()) {
+ return null;
+ }
+ profile.addToPom(project.getName());
+ return profile.savePom(monitor);
+ }
}
Modified: branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureGitSharedProject.java
===================================================================
--- branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureGitSharedProject.java 2012-03-05 13:04:57 UTC (rev 39281)
+++ branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureGitSharedProject.java 2012-03-05 13:15:08 UTC (rev 39282)
@@ -31,7 +31,6 @@
import org.jboss.ide.eclipse.as.core.util.FileUtil;
import org.jboss.ide.eclipse.as.core.util.RegExUtils;
import org.jboss.tools.openshift.egit.core.EGitUtils;
-import org.jboss.tools.openshift.express.internal.ui.OpenShiftUIActivator;
import org.jboss.tools.openshift.express.internal.ui.OpenShiftUIException;
import org.jboss.tools.openshift.express.internal.ui.UnCommittedChangesException;
import org.jboss.tools.openshift.express.internal.ui.utils.FileUtils;
@@ -132,17 +131,6 @@
EGitUtils.addRemoteTo(getRemoteName(), getApplication().getGitUri(), repository);
}
- private IResource setupOpenShiftMavenProfile(IProject project, IProgressMonitor monitor) throws CoreException {
- Assert.isLegal(OpenShiftMavenProfile.isMavenProject(project));
-
- OpenShiftMavenProfile profile = new OpenShiftMavenProfile(project, OpenShiftUIActivator.PLUGIN_ID);
- if (profile.existsInPom()) {
- return null;
- }
- profile.addToPom(project.getName());
- return profile.savePom(monitor);
- }
-
/**
* Copies the openshift configuration from the given application to the
* given project. Clones the application to a tmp-folder, copies
Modified: branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureUnsharedProject.java
===================================================================
--- branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureUnsharedProject.java 2012-03-05 13:04:57 UTC (rev 39281)
+++ branches/jbosstools-3.3.0.Beta1/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureUnsharedProject.java 2012-03-05 13:15:08 UTC (rev 39282)
@@ -95,6 +95,7 @@
copyOpenshiftConfigurations(getApplication(), getRemoteName(), project, monitor);
createGitIgnore(project, monitor);
+ setupOpenShiftMavenProfile(project, monitor);
shareProject(project, monitor);
addRemoteRepo(getRemoteName(), getApplication().getGitUri(), EGitUtils.getRepository(project));
12 years, 10 months
JBoss Tools SVN: r39281 - trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport.
by jbosstools-commits@lists.jboss.org
Author: adietish
Date: 2012-03-05 08:04:57 -0500 (Mon, 05 Mar 2012)
New Revision: 39281
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/AbstractImportApplicationOperation.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureGitSharedProject.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureUnsharedProject.java
Log:
[JBIDE-11152] now adding openshift profile to pom for unshared projects (was: only happened for git-shared projects)
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/AbstractImportApplicationOperation.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/AbstractImportApplicationOperation.java 2012-03-05 12:46:59 UTC (rev 39280)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/AbstractImportApplicationOperation.java 2012-03-05 13:04:57 UTC (rev 39281)
@@ -33,6 +33,7 @@
import org.jboss.tools.openshift.egit.core.EGitUtils;
import org.jboss.tools.openshift.egit.core.GitIgnore;
import org.jboss.tools.openshift.egit.ui.util.EGitUIUtils;
+import org.jboss.tools.openshift.express.internal.ui.OpenShiftUIActivator;
import com.openshift.express.client.IApplication;
import com.openshift.express.client.OpenShiftException;
@@ -223,4 +224,16 @@
return gitIgnore.write(monitor);
}
+ protected IResource setupOpenShiftMavenProfile(IProject project, IProgressMonitor monitor) throws CoreException {
+ if(!OpenShiftMavenProfile.isMavenProject(project)) {
+ return null;
+ }
+
+ OpenShiftMavenProfile profile = new OpenShiftMavenProfile(project, OpenShiftUIActivator.PLUGIN_ID);
+ if (profile.existsInPom()) {
+ return null;
+ }
+ profile.addToPom(project.getName());
+ return profile.savePom(monitor);
+ }
}
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureGitSharedProject.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureGitSharedProject.java 2012-03-05 12:46:59 UTC (rev 39280)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureGitSharedProject.java 2012-03-05 13:04:57 UTC (rev 39281)
@@ -31,7 +31,6 @@
import org.jboss.ide.eclipse.as.core.util.FileUtil;
import org.jboss.ide.eclipse.as.core.util.RegExUtils;
import org.jboss.tools.openshift.egit.core.EGitUtils;
-import org.jboss.tools.openshift.express.internal.ui.OpenShiftUIActivator;
import org.jboss.tools.openshift.express.internal.ui.OpenShiftUIException;
import org.jboss.tools.openshift.express.internal.ui.UnCommittedChangesException;
import org.jboss.tools.openshift.express.internal.ui.utils.FileUtils;
@@ -132,17 +131,6 @@
EGitUtils.addRemoteTo(getRemoteName(), getApplication().getGitUri(), repository);
}
- private IResource setupOpenShiftMavenProfile(IProject project, IProgressMonitor monitor) throws CoreException {
- Assert.isLegal(OpenShiftMavenProfile.isMavenProject(project));
-
- OpenShiftMavenProfile profile = new OpenShiftMavenProfile(project, OpenShiftUIActivator.PLUGIN_ID);
- if (profile.existsInPom()) {
- return null;
- }
- profile.addToPom(project.getName());
- return profile.savePom(monitor);
- }
-
/**
* Copies the openshift configuration from the given application to the
* given project. Clones the application to a tmp-folder, copies
Modified: trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureUnsharedProject.java
===================================================================
--- trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureUnsharedProject.java 2012-03-05 12:46:59 UTC (rev 39280)
+++ trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/ui/wizard/appimport/ConfigureUnsharedProject.java 2012-03-05 13:04:57 UTC (rev 39281)
@@ -95,6 +95,7 @@
copyOpenshiftConfigurations(getApplication(), getRemoteName(), project, monitor);
createGitIgnore(project, monitor);
+ setupOpenShiftMavenProfile(project, monitor);
shareProject(project, monitor);
addRemoteRepo(getRemoteName(), getApplication().getGitUri(), EGitUtils.getRepository(project));
12 years, 10 months
JBoss Tools SVN: r39280 - trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui.
by jbosstools-commits@lists.jboss.org
Author: snjeza
Date: 2012-03-05 07:46:59 -0500 (Mon, 05 Mar 2012)
New Revision: 39280
Modified:
trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java
Log:
JBDS-2048 Runtime detection: Location not added to the paths list
Modified: trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java
===================================================================
--- trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java 2012-03-05 12:29:50 UTC (rev 39279)
+++ trunk/runtime/plugins/org.jboss.tools.runtime.ui/src/org/jboss/tools/runtime/ui/JBossRuntimeStartup.java 2012-03-05 12:46:59 UTC (rev 39280)
@@ -49,22 +49,25 @@
public static void initializeRuntimes(IProgressMonitor monitor) {
if (isJBDS()) {
- final Set<RuntimePath> runtimePaths = new HashSet<RuntimePath>();
- parseRuntimeLocationsFile(runtimePaths);
- RuntimePath eapPath = null;
+ JBossRuntimeLocator locator = new JBossRuntimeLocator();
try {
String configuration = getConfiguration();
File directory = new File(configuration, JBOSS_EAP_HOME);
if (directory.isDirectory()) {
RuntimePath runtimePath = new RuntimePath(directory.getAbsolutePath());
- runtimePaths.add(runtimePath);
- eapPath = runtimePath;
+ List<RuntimeDefinition> serverDefinitions = locator
+ .searchForRuntimes(runtimePath.getPath(), monitor);
+ runtimePath.getServerDefinitions().clear();
+ for (RuntimeDefinition serverDefinition : serverDefinitions) {
+ serverDefinition.setRuntimePath(runtimePath);
+ }
+ initializeRuntimes(serverDefinitions);
}
} catch (IOException e) {
RuntimeUIActivator.log(e);
}
-
- JBossRuntimeLocator locator = new JBossRuntimeLocator();
+ final Set<RuntimePath> runtimePaths = new HashSet<RuntimePath>();
+ parseRuntimeLocationsFile(runtimePaths);
for (RuntimePath runtimePath : runtimePaths) {
List<RuntimeDefinition> serverDefinitions = locator
.searchForRuntimes(runtimePath.getPath(), monitor);
@@ -73,9 +76,6 @@
serverDefinition.setRuntimePath(runtimePath);
}
runtimePath.getServerDefinitions().addAll(serverDefinitions);
- if (runtimePath.equals(eapPath)) {
- initializeRuntimes(serverDefinitions);
- }
}
if (runtimePaths.size() > 0) {
RuntimeUIActivator.getDefault().getRuntimePaths().addAll(runtimePaths);
12 years, 10 months
JBoss Tools SVN: r39279 - trunk/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console.
by jbosstools-commits@lists.jboss.org
Author: koen.aers(a)jboss.com
Date: 2012-03-05 07:29:50 -0500 (Mon, 05 Mar 2012)
New Revision: 39279
Modified:
trunk/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console/ForgeCommandProcessor.java
Log:
JBIDE-10714: Forge "rm" does not clean up Eclipse UI
-> refresh Project Explorer manually
Modified: trunk/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console/ForgeCommandProcessor.java
===================================================================
--- trunk/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console/ForgeCommandProcessor.java 2012-03-05 12:22:14 UTC (rev 39278)
+++ trunk/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console/ForgeCommandProcessor.java 2012-03-05 12:29:50 UTC (rev 39279)
@@ -11,6 +11,7 @@
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.navigator.CommonNavigator;
import org.jboss.tools.forge.ui.ForgeUIPlugin;
import org.jboss.tools.forge.ui.part.ForgeView;
@@ -53,6 +54,7 @@
if (postProcessor != null) {
postProcessor.postProcess(getCommandDetails(commandString));
}
+ refreshProjectExplorer();
showForgeConsole();
}
});
@@ -82,17 +84,22 @@
}
private void showForgeConsole() {
-// try {
- IWorkbenchWindow workbenchWindow = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
- IWorkbenchPage workbenchPage = workbenchWindow.getActivePage();
- IViewPart forgeView = workbenchPage.findView(ForgeView.ID);
- if (forgeView != null) {
- forgeView.setFocus();
- }
-// workbenchPage.showView(ForgeView.ID).setFocus();
-// } catch (PartInitException e) {
-// ForgeUIPlugin.log(e);
-// }
+ IWorkbenchWindow workbenchWindow = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+ IWorkbenchPage workbenchPage = workbenchWindow.getActivePage();
+ IViewPart forgeView = workbenchPage.findView(ForgeView.ID);
+ if (forgeView != null) {
+ forgeView.setFocus();
+ }
}
+ private void refreshProjectExplorer() {
+ IWorkbenchPage workbenchPage = ForgeCommandPostProcessorHelper.getActiveWorkbenchPage();
+ if (workbenchPage != null) {
+ IViewPart projectExplorer = workbenchPage.findView("org.eclipse.ui.navigator.ProjectExplorer");
+ if (projectExplorer != null && projectExplorer instanceof CommonNavigator) {
+ ((CommonNavigator)projectExplorer).getCommonViewer().refresh();
+ }
+ }
+ }
+
}
12 years, 10 months
JBoss Tools SVN: r39278 - branches/jbosstools-3.3.0.Beta1/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console.
by jbosstools-commits@lists.jboss.org
Author: koen.aers(a)jboss.com
Date: 2012-03-05 07:22:14 -0500 (Mon, 05 Mar 2012)
New Revision: 39278
Modified:
branches/jbosstools-3.3.0.Beta1/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console/ForgeCommandProcessor.java
Log:
JBIDE-10714: Forge "rm" does not clean up Eclipse UI
-> manually refresh project explorer
Modified: branches/jbosstools-3.3.0.Beta1/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console/ForgeCommandProcessor.java
===================================================================
--- branches/jbosstools-3.3.0.Beta1/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console/ForgeCommandProcessor.java 2012-03-05 09:42:08 UTC (rev 39277)
+++ branches/jbosstools-3.3.0.Beta1/forge/plugins/org.jboss.tools.forge.ui/src/org/jboss/tools/forge/ui/console/ForgeCommandProcessor.java 2012-03-05 12:22:14 UTC (rev 39278)
@@ -11,6 +11,7 @@
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.navigator.CommonNavigator;
import org.jboss.tools.forge.ui.ForgeUIPlugin;
import org.jboss.tools.forge.ui.part.ForgeView;
@@ -53,6 +54,7 @@
if (postProcessor != null) {
postProcessor.postProcess(getCommandDetails(commandString));
}
+ refreshProjectExplorer();
showForgeConsole();
}
});
@@ -82,17 +84,22 @@
}
private void showForgeConsole() {
-// try {
- IWorkbenchWindow workbenchWindow = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
- IWorkbenchPage workbenchPage = workbenchWindow.getActivePage();
- IViewPart forgeView = workbenchPage.findView(ForgeView.ID);
- if (forgeView != null) {
- forgeView.setFocus();
- }
-// workbenchPage.showView(ForgeView.ID).setFocus();
-// } catch (PartInitException e) {
-// ForgeUIPlugin.log(e);
-// }
+ IWorkbenchWindow workbenchWindow = PlatformUI.getWorkbench().getActiveWorkbenchWindow();
+ IWorkbenchPage workbenchPage = workbenchWindow.getActivePage();
+ IViewPart forgeView = workbenchPage.findView(ForgeView.ID);
+ if (forgeView != null) {
+ forgeView.setFocus();
+ }
}
+ private void refreshProjectExplorer() {
+ IWorkbenchPage workbenchPage = ForgeCommandPostProcessorHelper.getActiveWorkbenchPage();
+ if (workbenchPage != null) {
+ IViewPart projectExplorer = workbenchPage.findView("org.eclipse.ui.navigator.ProjectExplorer");
+ if (projectExplorer != null && projectExplorer instanceof CommonNavigator) {
+ ((CommonNavigator)projectExplorer).getCommonViewer().refresh();
+ }
+ }
+ }
+
}
12 years, 10 months