8000 Resolve #214 Keep validation markers for model reload by tanjaem · Pull Request #223 · eclipsesource/graphical-lsp · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
This repository was archived by the owner on Jan 15, 2020. It is now read-only.

Resolve #214 Keep validation markers for model reload #223

Merged
merged 6 commits into from
Apr 15, 2019

Conversation

tanjaem
Copy link
Contributor
@tanjaem tanjaem commented Mar 24, 2019

No description provided.

@tortmayr
Copy link
Collaborator

Thanks! Seems to work in most cases, but I found a bug where error markers for resolved problems are not cleared on (re)validation:
no_marker_dis

Why do we need to reapply old markers before an update? Doesn't SetModelAction.markers contain the entire marker information anyways?
Correct me If I'm wrong, but wouldn't it be sufficient to implement the current SetModelMarkersCommand (i.e the version on master) as FeedbackCommand and dispatch the corresponding action in the tool-palette via FeedbackActionDispatcher?

@tortmayr tortmayr self-requested a review March 25, 2019 12:06
tanjaem added 6 commits April 10, 2019 19:08
This commit improves the model index to correctly update the indices for incoming and outgoing edges of nodes in case edges are deleted. Beforehand, these indices were not updated.
In case of deleting edges, the model index got unnecessarily polluted due to calling the operation SModelIndex.get[Incomging|Outgoing]Edges also for edges when computing dependent elements that should be deleted together with the edges. This commit introduces a condition so that incoming and outgoing edges are only considered as dependent elements of nodes, i.e., the mentioned SModelIndex operations are only for nodes.
This commit introduces an own feedback emitter for the (re-)application of validation markers on the diagram. This feedback emitter eases the addition and removal of feedback actions for marker (re-)application. Also, the interface IFeedbackEmitter could be simplified.
This commit introduces the Clear Markes Action and corresponding command, which are responsible for clearing old markers visualized on the diagram. This can be necessary in case of a re-validation, namely when previously retrieved markers become obsolete. Also, it can be used to allow the user to clear all visualized makers.
@tanjaem tanjaem force-pushed the tanjaem/issues/214 branch from cda36c5 to ff8ed1f Compare April 11, 2019 18:28
@tanjaem
Copy link
Contributor Author
tanjaem commented Apr 11, 2019

@tortmayr, thanks for your review and feedback! I hope my new changes fix the problems you encountered!

Copy link
Collaborator
@tortmayr tortmayr left a comment

Choose a reason for hiding this comment

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

Thanks! Code looks good and now everything works great. 👍

@tortmayr tortmayr merged commit a8d59b9 into eclipsesource:master Apr 15, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0