Skip to content

Instantly share code, notes, and snippets.

View uniring's full-sized avatar

Sergi Ramón uniring

View GitHub Profile
@uniring
uniring / Cocoa Block Animation
Created June 6, 2013 10:01
Cocoa (mac) animation with blocks
__block NSView *bView = self;
[NSAnimationContext runAnimationGroup:^(NSAnimationContext *context) {
context.duration = 0.3;
context.timingFunction = [CAMediaTimingFunction functionWithName:kCAMediaTimingFunctionEaseIn];
[[bView animator] setAlphaValue:0];
} completionHandler:^{
[bView removeFromSuperview];
}];
@uniring
uniring / gist:4621346
Last active December 11, 2015 15:29
CSS: Border Radius
-webkit-background-clip: padding-box;
-webkit-border-radius: 5px;
-moz-border-radius: 5px;
border-radius: 5px;