unit uMlSkinLinkResDM;

interface

uses
  SysUtils, uMlSkinResDM, uMlSkinImageList, uMlSkinSvgImageList;

function ExistsMlSkinResDM: Boolean;

function GetMlSkinResDM: TMlSkinResDM;

procedure ReloadMlSkinResDM;

function GetMlSkinResDM_MlSkinImageListMain: TMlSkinImageList;

function GetMlSkinResDM_MlSkinSvgImageListMain: TMlSkinSvgImageList;

implementation

function ExistsMlSkinResDM: Boolean;
begin
  Result := GetMlSkinResDM <> nil;
end;

procedure ReloadMlSkinResDM;
begin
  if Assigned(MlSkinResDM) then
    FreeAndNil(MlSkinResDM);
  MlSkinResDM := TMlSkinResDM.Create(nil);
  MlSkinResDM.Name := 'MlSkinResDM';
end;

function GetMlSkinResDM_MlSkinImageListMain: TMlSkinImageList;
begin
  Result := GetMlSkinResDM.MlSkinImageListMain;
end;

function GetMlSkinResDM_MlSkinSvgImageListMain: TMlSkinSvgImageList;
begin
  Result := TMlSkinSvgImageList
    (GetMlSkinResDM.FindComponent('MlSkinImageListSvg'));
end;

function GetMlSkinResDM: TMlSkinResDM;
begin
  Result := MlSkinResDM;
end;

end.
