mirror of https://gitlab.com/basile.b/dexed.git
fix, editor modified file, invalid content could be paste
if new version of the file was an empty file
This commit is contained in:
parent
2902b26310
commit
a1672f7187
|
|
@ -852,9 +852,12 @@ begin
|
||||||
str := TStringList.Create;
|
str := TStringList.Create;
|
||||||
try
|
try
|
||||||
str.LoadFromFile(fFilename);
|
str.LoadFromFile(fFilename);
|
||||||
DoCopyToClipboard(str.Text);
|
|
||||||
ClearAll;
|
ClearAll;
|
||||||
PasteFromClipboard;
|
if str.Count > 0 then
|
||||||
|
begin
|
||||||
|
DoCopyToClipboard(str.Text);
|
||||||
|
PasteFromClipboard;
|
||||||
|
end;
|
||||||
fModified := true;
|
fModified := true;
|
||||||
finally
|
finally
|
||||||
str.Free;
|
str.Free;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue