mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-14 12:35:22 +02:00
[276195] Avoid unnecessary selectionChanged when restoring connections
This commit is contained in:
parent
a527bfdda5
commit
c985ce92ca
1 changed files with 62 additions and 57 deletions
|
@ -69,6 +69,7 @@
|
||||||
* David McKnight (IBM) - [257721] Doubleclick doing special handling and expanding
|
* David McKnight (IBM) - [257721] Doubleclick doing special handling and expanding
|
||||||
* David McKnight (IBM) - [190805] [performance][dstore] Right-click > Disconnect on a dstore connection is slow and spawns many Jobs
|
* David McKnight (IBM) - [190805] [performance][dstore] Right-click > Disconnect on a dstore connection is slow and spawns many Jobs
|
||||||
* David McKnight (IBM) - [190001] [refresh] Avoid unnecessary duplicate queries during drag&drop to filter
|
* David McKnight (IBM) - [190001] [refresh] Avoid unnecessary duplicate queries during drag&drop to filter
|
||||||
|
* Martin Oberhuber (Wind River) - [276195] Avoid unnecessary selectionChanged when restoring connections
|
||||||
********************************************************************************/
|
********************************************************************************/
|
||||||
|
|
||||||
package org.eclipse.rse.internal.ui.view;
|
package org.eclipse.rse.internal.ui.view;
|
||||||
|
@ -1779,8 +1780,12 @@ public class SystemView extends SafeTreeViewer
|
||||||
if (!getControl().isDisposed()) {
|
if (!getControl().isDisposed()) {
|
||||||
ResourceChangedJob job = new ResourceChangedJob(event, this);
|
ResourceChangedJob job = new ResourceChangedJob(event, this);
|
||||||
job.setPriority(Job.INTERACTIVE);
|
job.setPriority(Job.INTERACTIVE);
|
||||||
|
if (Display.getCurrent() != null) {
|
||||||
|
job.runInUIThread(null);
|
||||||
|
} else {
|
||||||
// job.setUser(true);
|
// job.setUser(true);
|
||||||
job.schedule();
|
job.schedule();
|
||||||
|
}
|
||||||
/*
|
/*
|
||||||
Display display = Display.getCurrent();
|
Display display = Display.getCurrent();
|
||||||
try {
|
try {
|
||||||
|
@ -1904,7 +1909,7 @@ public class SystemView extends SafeTreeViewer
|
||||||
if (debug) {
|
if (debug) {
|
||||||
logDebugMsg("SV event: EVENT_ADD "); //$NON-NLS-1$
|
logDebugMsg("SV event: EVENT_ADD "); //$NON-NLS-1$
|
||||||
}
|
}
|
||||||
clearSelection();
|
// clearSelection();
|
||||||
//refresh(parent);t
|
//refresh(parent);t
|
||||||
parentItem = findItem(parent);
|
parentItem = findItem(parent);
|
||||||
if (parentItem == null) return Status.OK_STATUS;
|
if (parentItem == null) return Status.OK_STATUS;
|
||||||
|
@ -1970,7 +1975,7 @@ public class SystemView extends SafeTreeViewer
|
||||||
{
|
{
|
||||||
createTreeItem(parentItem, src, pos);
|
createTreeItem(parentItem, src, pos);
|
||||||
}
|
}
|
||||||
setSelection(new StructuredSelection(src), true);
|
// setSelection(new StructuredSelection(src), true);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case ISystemResourceChangeEvents.EVENT_ADD_MANY:
|
case ISystemResourceChangeEvents.EVENT_ADD_MANY:
|
||||||
|
|
Loading…
Add table
Reference in a new issue