2
using System.Collections.Generic;
7
using MonoMac.Foundation;
9
using MonoMac.CoreAnimation;
10
using MonoMac.CoreGraphics;
12
namespace AnimatedClock
14
class ClockLayer : CALayer {
19
[Export ("initWithLayer:")]
20
public ClockLayer (CALayer other)
25
public override void Clone (CALayer other)
27
ClockColor = ((ClockLayer) other).ClockColor;
31
[Export ("clockColor")]
32
public CGColor ClockColor { get; set; }
34
[Export ("needsDisplayForKey:")]
35
static bool NeedsDisplayForKey (NSString key)
37
switch (key.ToString ()) {
41
return CALayer.NeedsDisplayForKey (key);
45
public override void DrawInContext (CGContext context)
47
base.DrawInContext (context);
49
context.AddEllipseInRect (Bounds);
50
context.SetFillColor (ClockColor);