This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!--- Paste into ~/Library/Developer/Xcode/UserData/CodeSnippets ---> | |
<!--- Created by @wannafedor4 aka @itjustcrashed ---> | |
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>IDECodeSnippetCompletionPrefix</key> | |
<string>maps_url</string> | |
<key>IDECodeSnippetCompletionScopes</key> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func markerIcon(for mapItem: MKMapItem) -> String { | |
let catagory = mapItem.pointOfInterestCategory | |
var icon = "mappin" | |
if catagory == .museum { | |
icon = "building.columns" | |
} else if catagory == .musicVenue { | |
icon = "music.microphone" | |
} else if catagory == .theater { | |
icon = "theatermasks" | |
} else if catagory == .library { |