[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.tools] Re: INavigationLocation and NavigationHistory

Here is some information regarding the Navigation classes.  Note that the
only documentation is the java doc.

> I'm not clear on when markLocation should be used

Figuring it out is not a easy task..  You call markLocation whenever the
user does a significant jump in the editor. The problem here is to define
what "significant" means. And that problem must be resolved by the person
who understands how to use the editor (should be the person who writes the
editor). You can't call it too much, otherwise you end up with to many
entries in the history making it useless.

The AbstractTextEditor calls markLocation whenever the selection changes
from outside (go to line, outline, tasklist etc).

> INavigationLocation.update

The message update is sent to the active location whenever another location
is added so that you can save information that you did not want to keep
track of. It is more like an optimization. We do not want to keep the
position as the user clicks around but we want the last position to be the
previous one when a new one is added.

"Michael Conner" <michael.conner@xxxxxxxxx> wrote in message
news:b7imfp$hkr$1@xxxxxxxxxxxxxxxx
> Is there any documentation on the use of the navigation history, other
than
> the Javadoc.  I'm not clear  on when markLocation shoul be used, or what
the
> method update in INavigationLocation is for.
>
> Thanks,
>
> Michael Conner
>
>
>