public
Description: A handy OS X menu icon application for launching commands in Terminal.app and iTerm.
Homepage: http://mbcharbonneau.github.com/terminalicious
Clone URL: git://github.com/mbcharbonneau/terminalicious.git
terminalicious / DSHTransparentView.m
100755 32 lines (24 sloc) 0.698 kb
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
//
// DSHTransparentView.m
// Terminalicious
//
// Created by Marc Charbonneau on 3/13/05.
// Copyright 2005 Downtown Software House. All rights reserved.
//
 
#import "DSHTransparentView.h"
 
@implementation DSHTransparentView
 
- (void)awakeFromNib
{
// Some day I should convert this to using a rounded bezier path instead of
// an image.
 
background = [NSImage imageNamed:@"background"];
    [self setNeedsDisplay:YES];
}
 
- (void)drawRect:(NSRect)rect
{
// I had a call to fill the window with clearColor before-- pretty sure I
// don't need that.
 
[background compositeToPoint:NSZeroPoint operation:NSCompositeSourceOver fraction:0.7];
[[self window] invalidateShadow];
}
 
@end