Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 11766 Details for
Bug 65504
No progress feedback when changing VM installs
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
patch for org.eclipse.jdt.debug.ui
65504.txt (text/plain), 5.12 KB, created by
Kevin Barnes
on 2004-06-08 16:47:11 EDT
(
hide
)
Description:
patch for org.eclipse.jdt.debug.ui
Filename:
MIME Type:
Creator:
Kevin Barnes
Created:
2004-06-08 16:47:11 EDT
Size:
5.12 KB
patch
obsolete
>Index: ui/org/eclipse/jdt/internal/debug/ui/jres/JREMessages.properties >=================================================================== >RCS file: /home/eclipse/org.eclipse.jdt.debug.ui/ui/org/eclipse/jdt/internal/debug/ui/jres/JREMessages.properties,v >retrieving revision 1.18 >diff -u -r1.18 JREMessages.properties >--- ui/org/eclipse/jdt/internal/debug/ui/jres/JREMessages.properties 18 May 2004 03:28:33 -0000 1.18 >+++ ui/org/eclipse/jdt/internal/debug/ui/jres/JREMessages.properties 8 Jun 2004 20:37:16 -0000 >@@ -78,3 +78,6 @@ > JREsUpdater.0=&OK > JREsUpdater.1=Rebuilding > JREsUpdater.2=Build all... >+JREsUpdater.3=Save VM Definitions >+JREsUpdater.4=Convert VM Definitions to XML >+JREsUpdater.5=Saving Preferences >Index: ui/org/eclipse/jdt/internal/debug/ui/jres/JREsPreferencePage.java >=================================================================== >RCS file: /home/eclipse/org.eclipse.jdt.debug.ui/ui/org/eclipse/jdt/internal/debug/ui/jres/JREsPreferencePage.java,v >retrieving revision 1.12 >diff -u -r1.12 JREsPreferencePage.java >--- ui/org/eclipse/jdt/internal/debug/ui/jres/JREsPreferencePage.java 14 May 2004 02:39:26 -0000 1.12 >+++ ui/org/eclipse/jdt/internal/debug/ui/jres/JREsPreferencePage.java 8 Jun 2004 20:37:16 -0000 >@@ -126,16 +126,12 @@ > */ > public boolean performOk() { > final boolean[] canceled = new boolean[] {false}; >- BusyIndicator.showWhile(null, new Runnable() { >- public void run() { >- IVMInstall defaultVM = getCurrentDefaultVM(); >- IVMInstall[] vms = fJREBlock.getJREs(); >- JREsUpdater updater = new JREsUpdater(getShell()); >- if (!updater.updateJRESettings(vms, defaultVM)) { >- canceled[0] = true; >- } >- } >- }); >+ IVMInstall defaultVM = getCurrentDefaultVM(); >+ IVMInstall[] vms = fJREBlock.getJREs(); >+ JREsUpdater updater = new JREsUpdater(getShell()); >+ if (!updater.updateJRESettings(vms, defaultVM)) { >+ canceled[0] = true; >+ } > > if(canceled[0]) { > return false; >Index: ui/org/eclipse/jdt/internal/debug/ui/jres/JREsUpdater.java >=================================================================== >RCS file: /home/eclipse/org.eclipse.jdt.debug.ui/ui/org/eclipse/jdt/internal/debug/ui/jres/JREsUpdater.java,v >retrieving revision 1.6 >diff -u -r1.6 JREsUpdater.java >--- ui/org/eclipse/jdt/internal/debug/ui/jres/JREsUpdater.java 12 May 2004 20:10:59 -0000 1.6 >+++ ui/org/eclipse/jdt/internal/debug/ui/jres/JREsUpdater.java 8 Jun 2004 20:37:16 -0000 >@@ -11,6 +11,7 @@ > package org.eclipse.jdt.internal.debug.ui.jres; > > import java.io.IOException; >+import java.lang.reflect.InvocationTargetException; > import java.util.List; > > import javax.xml.parsers.ParserConfigurationException; >@@ -36,8 +37,9 @@ > import org.eclipse.jdt.launching.JavaRuntime; > import org.eclipse.jdt.launching.LibraryLocation; > import org.eclipse.jface.dialogs.MessageDialog; >-import org.eclipse.swt.custom.BusyIndicator; >+import org.eclipse.jface.operation.IRunnableWithProgress; > import org.eclipse.swt.widgets.Shell; >+import org.eclipse.ui.progress.IProgressService; > > /** > * Processes add/removed/changed VMs. >@@ -126,12 +128,10 @@ > > // Generate XML for the VM defs and save it as the new value of the VM preference > saveVMDefinitions(vmContainer); >- > // do a build if required > if (build) { > doFullBuild(); > } >- > return true; > } > >@@ -230,22 +230,34 @@ > } > > private void saveVMDefinitions(final VMDefinitionsContainer container) { >- BusyIndicator.showWhile(getShell().getDisplay(), new Runnable() { >- public void run() { >- // Generate XML for the VM defs and save it as the new value of the VM preference >- try { >- String vmDefXML = container.getAsXML(); >- JavaRuntime.getPreferences().setValue(JavaRuntime.PREF_VM_XML, vmDefXML); >- JavaRuntime.savePreferences(); >- } catch (IOException ioe) { >- JDIDebugUIPlugin.log(ioe); >- } catch (ParserConfigurationException e) { >- JDIDebugUIPlugin.log(e); >- } catch (TransformerException e) { >- JDIDebugUIPlugin.log(e); >+ IProgressService progressService = JDIDebugUIPlugin.getDefault().getWorkbench().getProgressService(); >+ try { >+ progressService.busyCursorWhile(new IRunnableWithProgress() { >+ public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException { >+ // Generate XML for the VM defs and save it as the new value of the VM preference >+ try { >+ monitor.beginTask(JREMessages.getString("JREsUpdater.3"), 2); //$NON-NLS-1$ >+ monitor.subTask(JREMessages.getString("JREsUpdater.4")); //$NON-NLS-1$ >+ String vmDefXML = container.getAsXML(); >+ monitor.worked(1); >+ monitor.subTask(JREMessages.getString("JREsUpdater.5")); //$NON-NLS-1$ >+ JavaRuntime.getPreferences().setValue(JavaRuntime.PREF_VM_XML, vmDefXML); >+ JavaRuntime.savePreferences(); >+ monitor.worked(1); >+ } catch (IOException ioe) { >+ JDIDebugUIPlugin.log(ioe); >+ } catch (ParserConfigurationException e) { >+ JDIDebugUIPlugin.log(e); >+ } catch (TransformerException e) { >+ JDIDebugUIPlugin.log(e); >+ } > } >- } >- }); >+ >+ }); >+ } catch (InvocationTargetException e) { >+ JDIDebugUIPlugin.log(e); >+ } catch (InterruptedException e) { >+ } > } > > private Shell getShell() {
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 65504
: 11766 |
11863