mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-07 14:38:01 +02:00
* fixes for newstyle imagelist
git-svn-id: trunk@10932 -
This commit is contained in:
parent
65004ef893
commit
584a1f6a33
@ -146,7 +146,7 @@ begin
|
||||
// If we have a image, us it. Otherwise supply a default.
|
||||
if AMenuItem.HasBitmap then
|
||||
begin
|
||||
i := BI.AddCopy(AMenuItem.Bitmap, AMenuItem.Bitmap);
|
||||
i := BI.Add(AMenuItem.Bitmap, AMenuItem.Bitmap);
|
||||
B.ImageIndex := i;
|
||||
end
|
||||
else
|
||||
|
@ -1289,7 +1289,8 @@ procedure TPackageEditorForm.SetupComponents;
|
||||
Pixmap:=TPixmap.Create;
|
||||
Pixmap.TransparentColor:=clWhite;
|
||||
Pixmap.LoadFromLazarusResource(ResName);
|
||||
ImageList.AddDirect(Pixmap,nil)
|
||||
ImageList.Add(Pixmap,nil);
|
||||
Pixmap.Free;
|
||||
end;
|
||||
|
||||
procedure LoadBitBtnGlyph(ABitBtn: TBitBtn; const ResName: string);
|
||||
|
@ -269,23 +269,13 @@ begin
|
||||
end;
|
||||
|
||||
procedure TPkgGraphExplorerDlg.SetupComponents;
|
||||
|
||||
function AddResImg(const ResName: string): integer;
|
||||
var Pixmap: TPixmap;
|
||||
begin
|
||||
Pixmap:=TPixmap.Create;
|
||||
Pixmap.TransparentColor:=clWhite;
|
||||
Pixmap.LoadFromLazarusResource(ResName);
|
||||
Result:=ImageList.AddDirect(Pixmap,nil)
|
||||
end;
|
||||
|
||||
begin
|
||||
ImgIndexPackage:=AddResImg('pkg_package');
|
||||
ImgIndexInstalledPackage:=AddResImg('pkg_package_install');
|
||||
ImgIndexInstallPackage:=AddResImg('pkg_package_autoinstall');
|
||||
ImgIndexUninstallPackage:=AddResImg('pkg_package_uninstall');
|
||||
ImgIndexCirclePackage:=AddResImg('pkg_package_circle');
|
||||
ImgIndexMissingPackage:=AddResImg('pkg_conflict');
|
||||
ImgIndexPackage := ImageList.AddLazarusResource('pkg_package');
|
||||
ImgIndexInstalledPackage := ImageList.AddLazarusResource('pkg_package_install');
|
||||
ImgIndexInstallPackage := ImageList.AddLazarusResource('pkg_package_autoinstall');
|
||||
ImgIndexUninstallPackage := ImageList.AddLazarusResource('pkg_package_uninstall');
|
||||
ImgIndexCirclePackage := ImageList.AddLazarusResource('pkg_package_circle');
|
||||
ImgIndexMissingPackage := ImageList.AddLazarusResource('pkg_conflict');
|
||||
|
||||
PkgTreeLabel.Caption:=lisPckExplLoadedPackages;
|
||||
PkgListLabel.Caption:=lisPckExplIsRequiredBy;
|
||||
|
Loading…
Reference in New Issue
Block a user