-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathmsShapesForToolbar.pas
51 lines (38 loc) · 1.01 KB
/
msShapesForToolbar.pas
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
unit msShapesForToolbar;
interface
uses
{$Include msShapeClassListSingleton.mixin.pas}
;
type
{$Include msShapeClassListSingleton.mixin.pas}
TmsShapesForToolbar = class(TmsShapeClassListSingleton)
public
class function Instance: TmsShapesForToolbar;
procedure RegisterMC(const aValue: MCmsShape); override;
procedure IterateShapes(aLambda: TmsShapeClassLambda); override;
end;//TmsShapesForToolbar
implementation
uses
{$Include msShapeClassListSingleton.mixin.pas}
;
{$Include msShapeClassListSingleton.mixin.pas}
class function TmsShapesForToolbar.Instance: TmsShapesForToolbar;
begin
Result := inherited Instance As TmsShapesForToolbar;
end;
procedure TmsShapesForToolbar.RegisterMC(const aValue: MCmsShape);
begin
if aValue.IsForToolbar then
inherited;
end;
procedure TmsShapesForToolbar.IterateShapes(aLambda: TmsShapeClassLambda);
begin
inherited IterateShapes(
procedure (const aShapeClass : MCmsShape)
begin
if aShapeClass.IsForToolbar then
aLambda(aShapeClass);
end
);
end;
end.