On Tue, Jan 23, 2001 at 11:16:57AM +0000, Angus Leeming wrote:
> Dekel, will this have been fixed by your recent patch? Perhaps you'd care to
> comment?
Don't try to blame me. It is your fault.
The problem is that when a label is selected in the browser, we call to
Dispatch(LFUN_REF_BACK) (in FormRef::input). I guess the idea is to return
you to the original position from which the browser was opened, so the
reference will be inserted there. However, if there are previously saved
positions (i.e. you open the dialog, press "goto reference" and closed the
dialog without pressing "go back"), the cursor will move to the last save
positions, which can be in a different buffer, and the buffer switching
causes the closing of the dialog.
It is not hard to fix this problem, but I want to discuss what is the
behavior that we want for the dialog. Here are three suggestions
1. The cursor is moved only when explicitly pressing goto reference/go back.
2. Pressing a label in the browser doesn't move the cursor. However, when you
press OK/Apply, the cursor is moved to the original position (i.e. the
position from which the dialog was opened), and the reference is inserted
there.
3. Pressing a label in the browser automatically moves you to the label,
(without the need to press "goto reference"). Again, pressing OK/Apply
returns you to the original position.
I think that 3 is the best option.