LCL: SetBidiMode: call AdjustSize, bug #14951

git-svn-id: trunk@24687 -
This commit is contained in:
mattias 2010-04-17 20:08:46 +00:00
parent f95b2f63d5
commit d3bbbfee65
2 changed files with 8 additions and 2 deletions

View File

@ -5084,7 +5084,12 @@ begin
if FBiDiMode=AValue then exit;
FBiDiMode:=AValue;
FParentBiDiMode := False;
Perform(CM_BIDIMODECHANGED, 0, 0);
DisableAutoSizing;
try
Perform(CM_BIDIMODECHANGED, 0, 0); // see TWinControl.CMBiDiModeChanged
finally
EnableAutoSizing;
end;
end;
{------------------------------------------------------------------------------

View File

@ -6478,11 +6478,12 @@ end;
procedure TWinControl.CMBiDiModeChanged(var Message: TLMessage);
begin
inherited;
inherited CMBiDiModeChanged(Message);
NotifyControls(CM_PARENTBIDIMODECHANGED);
if HandleAllocated and (Message.wParam = 0) then
TWSWinControlClass(WidgetSetClass).SetBiDiMode(Self,
UseRightToLeftAlignment, UseRightToLeftReading, UseRightToLeftScrollBar);
AdjustSize;
end;
procedure TWinControl.CMBorderChanged(var Message: TLMessage);