Skip to content

Instantly share code, notes, and snippets.

@lsinger
Created January 17, 2009 02:18
Show Gist options
  • Save lsinger/48240 to your computer and use it in GitHub Desktop.
Save lsinger/48240 to your computer and use it in GitHub Desktop.
@import <Foundation/CPObject.j>
@implementation MessageListView : CPView
{
}
- (id)initWithFrame:(CGRect)aFrame
{
self = [super initWithFrame: aFrame];
if (self)
{
var bounds = [self bounds];
[self setBackgroundColor: [CPColor colorWithPatternImage: [[CPThreePartImage alloc] initWithImageSlices: [CPArray arrayWithObjects:
[[CPImage alloc] initWithContentsOfFile: @"Resources/MessageListView-background.png" size: CPSizeMake(1,600)],
[[CPImage alloc] initWithContentsOfFile: @"Resources/MessageListView-background-solid.png" size: CPSizeMake(1,1)],
[[CPImage alloc] initWithContentsOfFile: @"Resources/MessageListView-background-solid.png" size: CPSizeMake(1, 1)]
]
isVertical: YES]]];
//[self setBackgroundColor: [CPColor colorWithPatternImage: [[CPImage alloc] initWithContentsOfFile: @"Resources/MessageListView-background.png"]]];
}
return self;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment