Skip to content

Commit

Permalink
Don't spam updates when there are no targets!
Browse files Browse the repository at this point in the history
See propagateTarget which will already notify the UI.

Signed-off-by: Matthias Mailänder <[email protected]>
  • Loading branch information
Mailaender committed Mar 24, 2021
1 parent 20a3d20 commit 88ee2c5
Showing 1 changed file with 0 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
import org.eclipse.chemclipse.rcp.ui.icons.core.ApplicationImageFactory;
import org.eclipse.chemclipse.rcp.ui.icons.core.IApplicationImage;
import org.eclipse.chemclipse.support.comparator.SortOrder;
import org.eclipse.chemclipse.support.events.IChemClipseEvents;
import org.eclipse.chemclipse.support.ui.events.IKeyEventProcessor;
import org.eclipse.chemclipse.support.ui.menu.ITableMenuEntry;
import org.eclipse.chemclipse.support.ui.provider.AbstractLabelProvider;
Expand Down Expand Up @@ -737,8 +736,6 @@ private void updateTargets(Display display) {
propagateTarget(display);
}
}
//
UpdateNotifierUI.update(display, IChemClipseEvents.TOPIC_EDITOR_CHROMATOGRAM_UPDATE, "Target(s) have been modified (deleted/updated).");
}

private void propagateTarget(Display display) {
Expand Down

2 comments on commit 88ee2c5

@eselmeister
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Mailaender Unfortunately, the editor chromatogram update event is needed to keep the targets list and the chromatogram in sync. I'm inspecting this issue at the moment and working on a solution. I take over, as this is a bit more tricky issue. The flickering menu is definitively something, we should address immediately. I would rather recommend to add a menu listener to check whether the chromatogram menu is active or not. If active, updates are blocked. I'll keep you updated.

@eselmeister
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Mailaender I found a neat solution. Have a look here:
#540

Please sign in to comment.