Skip to content

Commit

Permalink
use FurnaceHelper.createStartRuntimeJob(runtime)
Browse files Browse the repository at this point in the history
  • Loading branch information
koentsje committed May 5, 2014
1 parent 9c446b7 commit 5f93762
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

import org.eclipse.jface.action.Action;
import org.eclipse.jface.resource.ImageDescriptor;
import org.jboss.tools.forge.core.furnace.FurnaceService;
import org.jboss.tools.forge.core.runtime.ForgeRuntime;
import org.jboss.tools.forge.core.runtime.ForgeRuntimeState;
import org.jboss.tools.forge.ui.internal.ForgeUIPlugin;
Expand All @@ -22,13 +21,13 @@ public StartAction(ForgeRuntime runtime) {

@Override
public void run() {
if (runtime == null || ForgeRuntimeState.RUNNING.equals(runtime.getState())) return;
FurnaceHelper.createStartFurnaceJob().schedule();
if (ForgeRuntimeState.RUNNING.equals(runtime.getState())) return;
FurnaceHelper.createStartRuntimeJob(runtime).schedule();
}

@Override
public boolean isEnabled() {
return FurnaceService.INSTANCE.getContainerStatus().isStopped();
return ForgeRuntimeState.STOPPED.equals(runtime.getState());
}

private ImageDescriptor createImageDescriptor() {
Expand Down

0 comments on commit 5f93762

Please sign in to comment.