Lines 593-600
Link Here
|
593 |
public void mouseUp(MouseEvent e) { |
593 |
public void mouseUp(MouseEvent e) { |
594 |
if (!stickyPreview) { |
594 |
if (!stickyPreview) { |
595 |
int offset = previewViewer.getTextWidget().getCaretOffset(); |
595 |
int offset = previewViewer.getTextWidget().getCaretOffset(); |
|
|
596 |
Point p = previewViewer.getTextWidget().getSelectionRange(); |
596 |
showEditor(); |
597 |
showEditor(); |
597 |
editorViewer.getTextWidget().setCaretOffset(offset); |
598 |
editorViewer.getTextWidget().setCaretOffset(offset); |
|
|
599 |
editorViewer.getTextWidget().setSelection(p); |
598 |
} |
600 |
} |
599 |
} |
601 |
} |
600 |
}); |
602 |
}); |
Lines 603-609
Link Here
|
603 |
public void focusLost(FocusEvent e) { |
605 |
public void focusLost(FocusEvent e) { |
604 |
super.focusLost(e); |
606 |
super.focusLost(e); |
605 |
if (!stickyPreview) { |
607 |
if (!stickyPreview) { |
|
|
608 |
Point p = editorViewer.getTextWidget().getSelectionRange(); |
606 |
showPreview(false); |
609 |
showPreview(false); |
|
|
610 |
previewViewer.getTextWidget().setSelection(p); |
607 |
} |
611 |
} |
608 |
} |
612 |
} |
609 |
}); |
613 |
}); |