Changeset 4095 in josm


Ignore:
Timestamp:
2011-05-25T09:01:54+02:00 (13 years ago)
Author:
bastiK
Message:

applied #6256 (patch by Hojoe) - Cursor Right behaviour after autocomplete not consistent

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/tagging/ac/AutoCompletingTextField.java

    r3312 r4095  
    2222
    2323import org.openstreetmap.josm.Main;
    24 import org.openstreetmap.josm.gui.tagging.ac.AutoCompletionList;
    2524import org.openstreetmap.josm.gui.util.TableCellEditorSupport;
    2625
     
    9897                super.insertString(0,matchingString,a);
    9998
    100                 // highlight from end to insert position
    101                 //
    102                 setCaretPosition(getLength());
    103                 moveCaretPosition(offs + str.length());
     99                // highlight from insert position to end position to put the caret at the end
     100                setCaretPosition(offs + str.length());
     101                moveCaretPosition(getLength());
    104102            } else {
    105103                // there are no matches. Insert the new text, do not highlight
Note: See TracChangeset for help on using the changeset viewer.