Skip to content

Commit

Permalink
Adds a map view to the main view controller
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Davies committed Nov 10, 2014
1 parent 095d209 commit 2563391
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
20 changes: 17 additions & 3 deletions 38-handoff/MapOff/MapOff/Base.lproj/Main.storyboard
Original file line number Diff line number Diff line change
@@ -1,22 +1,36 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="6211" systemVersion="14A298i" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="6250" systemVersion="14B17" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6204"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="6244"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="tne-QT-ifu">
<objects>
<viewController id="BYZ-38-t0r" customClass="ViewController" customModuleProvider="target" sceneMemberID="viewController">
<viewController id="BYZ-38-t0r" customClass="ViewController" customModule="MapOff" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="y3c-jy-aDJ"/>
<viewControllerLayoutGuide type="bottom" id="wfy-db-euE"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<mapView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" mapType="standard" translatesAutoresizingMaskIntoConstraints="NO" id="64h-TK-71n">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
</mapView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="64h-TK-71n" secondAttribute="trailing" id="Dox-6p-ugK"/>
<constraint firstItem="64h-TK-71n" firstAttribute="leading" secondItem="8bC-Xf-vdC" secondAttribute="leading" id="JOj-Ws-h3l"/>
<constraint firstItem="wfy-db-euE" firstAttribute="top" secondItem="64h-TK-71n" secondAttribute="bottom" id="NZp-jS-TyO"/>
<constraint firstItem="64h-TK-71n" firstAttribute="top" secondItem="8bC-Xf-vdC" secondAttribute="top" id="ukp-Ts-91T"/>
</constraints>
</view>
<connections>
<outlet property="mapView" destination="64h-TK-71n" id="Wl4-1F-Red"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
</objects>
Expand Down
3 changes: 3 additions & 0 deletions 38-handoff/MapOff/MapOff/ViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,12 @@
//

import UIKit
import MapKit

class ViewController: UIViewController {

@IBOutlet weak var mapView: MKMapView!

override func viewDidLoad() {
super.viewDidLoad()
// Do any additional setup after loading the view, typically from a nib.
Expand Down

0 comments on commit 2563391

Please sign in to comment.