diff options
author | Michael Valenta | 2004-03-23 21:48:41 +0000 |
---|---|---|
committer | Michael Valenta | 2004-03-23 21:48:41 +0000 |
commit | c75a2b44abc7c20c4d78aeaed77b7ff20a9e5390 (patch) | |
tree | e92c77312f4c7727fe26d944b0add2e622e48e80 | |
parent | 40c6f751b9b54e3f7ad09d20104a27019e757f51 (diff) | |
download | eclipse.platform.team-c75a2b44abc7c20c4d78aeaed77b7ff20a9e5390.tar.gz eclipse.platform.team-c75a2b44abc7c20c4d78aeaed77b7ff20a9e5390.tar.xz eclipse.platform.team-c75a2b44abc7c20c4d78aeaed77b7ff20a9e5390.zip |
Fix DNF in tests
2 files changed, 13 insertions, 10 deletions
diff --git a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/operations/ShareProjectOperation.java b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/operations/ShareProjectOperation.java index ca64b51ce..a0bbffe08 100644 --- a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/operations/ShareProjectOperation.java +++ b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/operations/ShareProjectOperation.java @@ -60,10 +60,9 @@ public class ShareProjectOperation extends CVSOperation { exception[0] = e; } } - }, project, 0, Policy.subMonitorFor(monitor, 40)); + }, project, 0, Policy.subMonitorFor(monitor, 10)); if (exception[0] != null) throw exception[0]; - waitForCollector(Policy.subMonitorFor(monitor, 10)); } catch (CoreException e) { throw CVSException.wrapException(e); } finally { @@ -71,12 +70,6 @@ public class ShareProjectOperation extends CVSOperation { } } - private void waitForCollector(IProgressMonitor sub) { - sub.beginTask(Policy.bind("ShareProjectOperation.1"), IProgressMonitor.UNKNOWN); //$NON-NLS-1$ - sub.subTask(Policy.bind("ShareProjectOperation.1")); //$NON-NLS-1$ - CVSUIPlugin.getPlugin().getCvsWorkspaceSynchronizeParticipant().getSubscriberSyncInfoCollector().waitForCollector(sub); - } - /** * Create the remote folder to which the project is being mapped * (as well as any ancestors) and return it. If the remote folder does not diff --git a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/wizards/SharingWizard.java b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/wizards/SharingWizard.java index f7c9310cb..88bbcd32f 100644 --- a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/wizards/SharingWizard.java +++ b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/wizards/SharingWizard.java @@ -502,18 +502,28 @@ public class SharingWizard extends Wizard implements IConfigurationWizard, ICVSW private void populateSyncPage(final boolean exists) throws InvocationTargetException, InterruptedException { getContainer().run(true, true, new IRunnableWithProgress() { public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException { + monitor.beginTask(null, 100); if (exists) { - reconcileProject(monitor); + reconcileProject(Policy.subMonitorFor(monitor, 90)); } else { - shareProject(monitor); + shareProject(Policy.subMonitorFor(monitor, 90)); } + waitForCollector(Policy.subMonitorFor(monitor, 10)); if (monitor.isCanceled()) { throw new InterruptedException(); } + monitor.done(); } }); } + private void waitForCollector(IProgressMonitor sub) { + sub.beginTask(Policy.bind("ShareProjectOperation.1"), IProgressMonitor.UNKNOWN); //$NON-NLS-1$ + sub.subTask(Policy.bind("ShareProjectOperation.1")); //$NON-NLS-1$ + CVSUIPlugin.getPlugin().getCvsWorkspaceSynchronizeParticipant().getSubscriberSyncInfoCollector().waitForCollector(sub); + sub.done(); + } + /* (non-Javadoc) * @see org.eclipse.jface.wizard.IWizard#getPreviousPage(org.eclipse.jface.wizard.IWizardPage) */ |