aschuch/AXStatusItemPopup — pull request #12 by mralexgray (2014-05-24 09:48:26+00:00)
Title: added block-drawn option, cleaned up code

![140524-0004](https://cloud.githubusercontent.com/assets/262517/3074149/9767a9bc-e327-11e3-8ce2-18b44f668b17.png)

![screencrop](https://cloud.githubusercontent.com/assets/262517/3074166/0e03c16e-e328-11e3-8330-d4d0a40e3313.png)

![140524-0003](https://cloud.githubusercontent.com/assets/262517/3074152/9d7caa8c-e327-11e3-8128-0d1c55f0f410.png)

with an implementation (as shown) of...

```objc

statusItemPopup = [AXStatusItemPopup.alloc
initWithViewController:popupVC
drawnWithBlock:^(AXStatusItemPopup *p) {
CGFloat h = NSHeight(p.frame);
NSPoint o = (NSPoint){( (NSWidth(p.frame) - h) / 2) + 4, p.frame.origin.y + 5};
NSBezierPath* x = [NSBezierPath bezierPathWithOvalInRect:(NSRect){o,{h-8,h-8}}];
[p.isActive ? NSColor.redColor : NSColor.yellowColor set], [x fill];
[x setLineWidth:2], [p.isActive ? NSColor.whiteColor : NSColor.blackColor set], [x stroke];
}];
```