Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » TMF (Xtext) » Build clean - no effect in dirty editor
Build clean - no effect in dirty editor [message #735835] Wed, 12 October 2011 20:04 Go to next message
Henrik Lindberg is currently offline Henrik LindbergFriend
Messages: 2509
Registered: July 2009
Senior Member
Hi,
I have an issue with clean builds and dirty editor state.

If I perform a 'build clean' and an editor is dirty its state does not
seem to be affected. In order to make the effect of the 'build clean'
visible, I need to save, and clean again.

If I save before I invoke 'build clean' it works.

If I just open the editor, and change the condition (a preference) on
which the validation depends, and invoke build clean, it always works.

The logic that performs the checks are in the linker's afterModelLinked
method.

What could I be doing wrong?
Do I need to do something special to affect the dirty editor state?
(Pretty please, really, really clean).

Regards
- henrik
Re: Build clean - no effect in dirty editor [message #735958 is a reply to message #735835] Thu, 13 October 2011 08:17 Go to previous message
Sebastian Zarnekow is currently offline Sebastian ZarnekowFriend
Messages: 3118
Registered: July 2009
Senior Member
Hi Henrik,

your XtextDocument should listen for preference changes and use
checkAndUpdateAnnotations() to revalidate itself.

Regards,
Sebastian
--
Need professional support for Eclipse Modeling?
Go visit: http://xtext.itemis.com

On 12.10.11 22:04, Henrik Lindberg wrote:
> Hi,
> I have an issue with clean builds and dirty editor state.
>
> If I perform a 'build clean' and an editor is dirty its state does not
> seem to be affected. In order to make the effect of the 'build clean'
> visible, I need to save, and clean again.
>
> If I save before I invoke 'build clean' it works.
>
> If I just open the editor, and change the condition (a preference) on
> which the validation depends, and invoke build clean, it always works.
>
> The logic that performs the checks are in the linker's afterModelLinked
> method.
>
> What could I be doing wrong?
> Do I need to do something special to affect the dirty editor state?
> (Pretty please, really, really clean).
>
> Regards
> - henrik
Previous Topic:Implicit imports based on type
Next Topic:Customized InternalMyDSLLexer
Goto Forum:
  


Current Time: Sat May 04 22:20:07 GMT 2024

Powered by FUDForum. Page generated in 0.03105 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top