William Bowling is sharing code with you

Bitbucket is a code hosting site. Unlimited public and private repositories. Free for small teams.

Don't show this again

wbowling / adium (fork of adium / adium)

Fork of Adium for patches/improvements

Clone this repository (size: 338.7 MB): HTTPS / SSH
hg clone https://bitbucket.org/wbowling/adium
hg clone ssh://hg@bitbucket.org/wbowling/adium

adium / Source / AIFilterBarView.m

//
//  AIFilterBarView.m
//  Adium
//
//  Created by Zachary West on 2009-04-02.
//

#import "AIFilterBarView.h"

#import <AIUtilities/AIBezierPathAdditions.h>

@implementation AIFilterBarView

@synthesize backgroundColor, backgroundIsRounded, drawsBackground;

- (id)initWithFrame:(NSRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
                
    }
    return self;
}

- (void)drawRect:(NSRect)rect
{       
        if (drawsBackground && backgroundColor) {
                NSBezierPath *bezierPath;
                
                if (backgroundIsRounded) {
                        bezierPath = [NSBezierPath bezierPathWithRoundedRect:self.bounds];
                } else {
                        bezierPath = [NSBezierPath bezierPathWithRect:self.bounds];
                }
                
                [backgroundColor set];
                [bezierPath fill];
        }
        
        [super drawRect:rect];
}

@end