mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-11 11:48:10 +02:00
Merged revision(s) 59586 #a3b056875f, 59621 #a08b455ead from trunk:
LCL: Read a streamed WideString CollectionItem property correctly. Issue #34561, patch from Anton Kavalenka. ........ LCL: Win32: Fixed PageControl corrupts display when TabPosition is tpLeft or tpRight. Issue #34577 ........ git-svn-id: branches/fixes_2_0@59630 -
This commit is contained in:
parent
99a67d1fdb
commit
90daa49155
@ -324,19 +324,22 @@ var
|
||||
LMessage: TLMessage;
|
||||
begin
|
||||
case Msg of
|
||||
// prevent flickering
|
||||
WM_ERASEBKGND:
|
||||
begin
|
||||
Control := GetWin32WindowInfo(Window)^.WinControl;
|
||||
LMessage.msg := Msg;
|
||||
LMessage.wParam := WParam;
|
||||
LMessage.lParam := LParam;
|
||||
LMessage.Result := 0;
|
||||
Result := DeliverMessage(Control, LMessage);
|
||||
if not ThemeServices.ThemesEnabled then
|
||||
begin
|
||||
// prevent flickering
|
||||
Control := GetWin32WindowInfo(Window)^.WinControl;
|
||||
LMessage.msg := Msg;
|
||||
LMessage.wParam := WParam;
|
||||
LMessage.lParam := LParam;
|
||||
LMessage.Result := 0;
|
||||
Result := DeliverMessage(Control, LMessage);
|
||||
Exit;
|
||||
end;
|
||||
end;
|
||||
else
|
||||
Result := WindowProc(Window, Msg, WParam, LParam);
|
||||
end;
|
||||
Result := WindowProc(Window, Msg, WParam, LParam);
|
||||
end;
|
||||
|
||||
class function TWin32WSCustomTabControl.CreateHandle(const AWinControl: TWinControl;
|
||||
|
@ -374,8 +374,8 @@ type
|
||||
procedure HandleAlphaNum;
|
||||
procedure HandleNumber;
|
||||
procedure HandleHexNumber;
|
||||
function HandleQuotedString : string;
|
||||
function HandleDecimalString(var IsWideString: Boolean): string;
|
||||
function HandleQuotedString: string;
|
||||
function HandleDecimalString: string;
|
||||
procedure HandleString;
|
||||
procedure HandleMinus;
|
||||
procedure HandleUnknown;
|
||||
@ -5628,8 +5628,9 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
function TUTF8Parser.HandleDecimalString(var IsWideString: Boolean): string;
|
||||
var i : integer;
|
||||
function TUTF8Parser.HandleDecimalString: string;
|
||||
var
|
||||
i: integer;
|
||||
begin
|
||||
Result:='';
|
||||
inc(fPos);
|
||||
@ -5642,13 +5643,7 @@ begin
|
||||
end;
|
||||
if not TryStrToInt(Result,i) then
|
||||
i:=0;
|
||||
if i > 255 then begin
|
||||
Result:=UnicodeToUTF8(i); // widestring
|
||||
IsWideString:=true;
|
||||
end else if i > 127 then
|
||||
Result:=SysToUTF8(chr(i)) // windows codepage
|
||||
else
|
||||
Result:=chr(i); // ascii, does not happen
|
||||
Result:=UnicodeToUTF8(i); // widestring
|
||||
end;
|
||||
|
||||
procedure TUTF8Parser.HandleString;
|
||||
@ -5660,12 +5655,15 @@ begin
|
||||
while true do begin
|
||||
case fBuf[fPos] of
|
||||
'''' : fLastTokenStr:=fLastTokenStr+HandleQuotedString;
|
||||
'#' : fLastTokenStr:=fLastTokenStr+HandleDecimalString(IsWideString);
|
||||
'#' : begin
|
||||
fLastTokenStr:=fLastTokenStr+HandleDecimalString;
|
||||
IsWideString:=true;
|
||||
end;
|
||||
else break;
|
||||
end;
|
||||
end;
|
||||
if IsWideString then
|
||||
fToken:=toWString
|
||||
fToken:=Classes.toWString
|
||||
else
|
||||
fToken:=Classes.toString;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user