Skip to content

Instantly share code, notes, and snippets.

@santoshrajan
Created November 7, 2014 17:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save santoshrajan/27d9456f82a882e0982f to your computer and use it in GitHub Desktop.
Save santoshrajan/27d9456f82a882e0982f to your computer and use it in GitHub Desktop.
override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view, typically from a nib.
view.backgroundColor = UIColor.lightGrayColor()
var hLayout = HorizontalLayout(height: 200)
hLayout.backgroundColor = UIColor.cyanColor()
view.addSubview(hLayout)
let view1 = UIView(frame: CGRectMake(50, 50, 100, 100))
view1.backgroundColor = UIColor.redColor()
hLayout.addSubview(view1)
let view2 = UIView(frame: CGRectMake(50, 50, 100, 100))
view2.backgroundColor = UIColor.magentaColor()
hLayout.addSubview(view2)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment