SynEdit: Syncron-edit mode, ignore column-mode selections

git-svn-id: trunk@20924 -
This commit is contained in:
martin 2009-07-22 19:34:36 +00:00
parent 7de27e1bdf
commit 2be288911d

View File

@ -28,7 +28,7 @@ interface
uses uses
Classes, Controls, SysUtils, math, LCLProc, Forms, Graphics, SynEditMiscClasses, Classes, Controls, SysUtils, math, LCLProc, Forms, Graphics, SynEditMiscClasses,
LCLType, SynEdit, SynPluginSyncronizedEditBase, SynEditTextBase, SynEditMiscProcs, LCLType, SynEdit, SynPluginSyncronizedEditBase, SynEditTextBase, SynEditMiscProcs,
SynEditMouseCmds, SynEditKeyCmds; SynEditMouseCmds, SynEditKeyCmds, SynEditTypes;
type type
@ -1014,7 +1014,7 @@ end;
procedure TSynPluginSyncroEdit.DoSelectionChanged(Sender: TObject); procedure TSynPluginSyncroEdit.DoSelectionChanged(Sender: TObject);
begin begin
if FMode = spseEditing then exit; if FMode = spseEditing then exit;
If not SelectionObj.SelAvail then begin If (not SelectionObj.SelAvail) or (SelectionObj.ActiveSelectionMode = smColumn) then begin
FLastSelStart := Point(-1,-1); FLastSelStart := Point(-1,-1);
FLastSelEnd := Point(-1,-1); FLastSelEnd := Point(-1,-1);
FWordIndex.Clear; FWordIndex.Clear;
@ -1064,7 +1064,7 @@ var
var var
i, j: Integer; i, j: Integer;
begin begin
Repeat while (FCallQueued) and (FMode = spseSelecting) do begin
FCallQueued := False; FCallQueued := False;
FWordScanCount := 0; FWordScanCount := 0;
@ -1124,9 +1124,11 @@ begin
FCallQueued := True; FCallQueued := True;
Application.ProcessMessages; Application.ProcessMessages;
end; end;
until not FCallQueued; end;
if FEditModeQueued then FCallQueued := False;
if FEditModeQueued and (FMode = spseSelecting) then
StartSyncroMode; StartSyncroMode;
FEditModeQueued := False;
end; end;
procedure TSynPluginSyncroEdit.DoOnDeactivate; procedure TSynPluginSyncroEdit.DoOnDeactivate;