LCL: Revert 0c285d6eb9 (fixes issue #39861).

This commit is contained in:
wp_xyz 2022-08-17 22:59:27 +02:00
parent b75a7c1e81
commit 7950515229
2 changed files with 1 additions and 18 deletions

View File

@ -92,7 +92,6 @@ type
AlignInfo: TAlignInfo); override;
procedure CalculatePreferredSize(var PreferredWidth,
PreferredHeight: integer; WithThemeSpace: Boolean); override;
procedure Loaded; override;
procedure Notification(AComponent: TComponent; Operation: TOperation); override;
procedure SetAlign(Value: TAlign); override;
procedure CMAppShowBtnGlyphChanged(var Message: TLMessage); message CM_APPSHOWBTNGLYPHCHANGED;
@ -486,12 +485,6 @@ begin
end;
end;
procedure TCustomButtonPanel.Loaded;
begin
inherited;
DoShowGlyphs;
end;
procedure TCustomButtonPanel.Notification(AComponent: TComponent;
Operation: TOperation);
var

View File

@ -315,17 +315,7 @@ begin
idButton := BitBtnImages[Kind];
if (idButton >= Low(BitBtnResNames)) and (idButton <= High(BitBtnResNames))
and (BitBtnResNames[idButton] <> '') then
begin
FButtonGlyph.LCLGlyphName := BitBtnResNames[idButton];
CustomGlyph := GetLCLDefaultBtnGlyph(Kind);
try
if not Assigned(Glyph) then
Glyph := TBitmap.Create;
Glyph.Assign(CustomGlyph);
finally
CustomGlyph.Free;
end;
end
FButtonGlyph.LCLGlyphName := BitBtnResNames[idButton]
else
ImageIndex := -1;
GlyphValid := True;