Skip to content

Instantly share code, notes, and snippets.

@gavi
Created June 16, 2016 15:47
Show Gist options
  • Save gavi/b51eb739168e756f3ddc9f2a76caa5f6 to your computer and use it in GitHub Desktop.
Save gavi/b51eb739168e756f3ddc9f2a76caa5f6 to your computer and use it in GitHub Desktop.
//: Playground - noun: a place where people can play
import UIKit
import MapKit
import PlaygroundSupport
class Container:UIView{
let mapView:MKMapView
override init(frame: CGRect) {
mapView=MKMapView(frame: frame)
super.init(frame: frame)
self.addSubview(mapView)
}
required init?(coder aDecoder: NSCoder) {
fatalError("init(coder:) has not been implemented")
}
}
var container=Container(frame:CGRect(x:0,y:0,width:500,height:500))
PlaygroundPage.current.liveView=container
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment