Created
December 11, 2014 15:31
-
-
Save laurentpetit/b93f3800fd5c45ba221b to your computer and use it in GitHub Desktop.
Eclipse Markers contribution does not dynamically react to Registry Extension additions, here's how to circumvent this:
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| ;; the markers definitions are cached in the cache field of the MarkerManager instance | |
| ;; the MarkerTypeDefinitionCache constructor gets the marker extensions from the registry | |
| (let [mm (.getMarkerManager (e/workspace)) | |
| cache-field (.getDeclaredField org.eclipse.core.internal.resources.MarkerManager "cache") | |
| new-cache (org.eclipse.core.internal.resources.MarkerTypeDefinitionCache.)] | |
| (.setAccessible cache-field true) | |
| (.set cache-field mm new-cache)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment