diff options
author | Susan Franklin | 2010-03-07 17:40:48 +0000 |
---|---|---|
committer | Susan Franklin | 2010-03-07 17:40:48 +0000 |
commit | cbac1dc3a189b4a9a73ecca736f3e9dde5d27686 (patch) | |
tree | 4e67f046148eb12944f62e5b1fab0807a7aba2c7 /examples | |
parent | 9b2d5617f5d98b6456998bf52881cd7a85398d83 (diff) | |
download | rt.equinox.p2-cbac1dc3a189b4a9a73ecca736f3e9dde5d27686.tar.gz rt.equinox.p2-cbac1dc3a189b4a9a73ecca736f3e9dde5d27686.tar.xz rt.equinox.p2-cbac1dc3a189b4a9a73ecca736f3e9dde5d27686.zip |
Bug 302183 - [operations] ProvisioningSession is weirdv20100307-1300
Diffstat (limited to 'examples')
2 files changed, 3 insertions, 2 deletions
diff --git a/examples/org.eclipse.equinox.p2.examples.rcp.prestartupdate/src/org/eclipse/equinox/p2/examples/rcp/prestartupdate/ApplicationWorkbenchAdvisor.java b/examples/org.eclipse.equinox.p2.examples.rcp.prestartupdate/src/org/eclipse/equinox/p2/examples/rcp/prestartupdate/ApplicationWorkbenchAdvisor.java index 7fcbdac50..ee686a763 100644 --- a/examples/org.eclipse.equinox.p2.examples.rcp.prestartupdate/src/org/eclipse/equinox/p2/examples/rcp/prestartupdate/ApplicationWorkbenchAdvisor.java +++ b/examples/org.eclipse.equinox.p2.examples.rcp.prestartupdate/src/org/eclipse/equinox/p2/examples/rcp/prestartupdate/ApplicationWorkbenchAdvisor.java @@ -10,6 +10,7 @@ import org.eclipse.equinox.internal.p2.core.helpers.LogHelper; import org.eclipse.equinox.internal.p2.core.helpers.ServiceHelper; import org.eclipse.equinox.p2.core.IProvisioningAgent; import org.eclipse.equinox.p2.operations.ProvisioningSession; +import org.eclipse.equinox.p2.operations.UpdateOperation; import org.eclipse.jface.dialogs.MessageDialog; import org.eclipse.jface.dialogs.ProgressMonitorDialog; import org.eclipse.jface.operation.IRunnableWithProgress; @@ -49,7 +50,7 @@ public class ApplicationWorkbenchAdvisor extends WorkbenchAdvisor { public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException { IStatus updateStatus = P2Util.checkForUpdates(agent, monitor); - if (updateStatus.getCode() == ProvisioningSession.STATUS_NOTHING_TO_UPDATE) { + if (updateStatus.getCode() == UpdateOperation.STATUS_NOTHING_TO_UPDATE) { PlatformUI.getWorkbench().getDisplay().asyncExec(new Runnable() { public void run() { MessageDialog.openInformation(null, "Updates", "No updates were found"); diff --git a/examples/org.eclipse.equinox.p2.examples.rcp.prestartupdate/src/org/eclipse/equinox/p2/examples/rcp/prestartupdate/P2Util.java b/examples/org.eclipse.equinox.p2.examples.rcp.prestartupdate/src/org/eclipse/equinox/p2/examples/rcp/prestartupdate/P2Util.java index 17aa000c6..66c9027ef 100644 --- a/examples/org.eclipse.equinox.p2.examples.rcp.prestartupdate/src/org/eclipse/equinox/p2/examples/rcp/prestartupdate/P2Util.java +++ b/examples/org.eclipse.equinox.p2.examples.rcp.prestartupdate/src/org/eclipse/equinox/p2/examples/rcp/prestartupdate/P2Util.java @@ -32,7 +32,7 @@ public class P2Util { SubMonitor sub = SubMonitor.convert(monitor, "Checking for application updates...", 200); IStatus status = operation.resolveModal(sub.newChild(100)); - if (status.getCode() == ProvisioningSession.STATUS_NOTHING_TO_UPDATE) { + if (status.getCode() == UpdateOperation.STATUS_NOTHING_TO_UPDATE) { return status; } if (status.getSeverity() == IStatus.CANCEL) |