Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

complete the initial method to make the MapKitExample running well. #53

Open
wants to merge 1 commit into from

1 participant

@croath

No description provided.

@croath

anyone here? it can not launch you guys don't notice it ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 10, 2013
  1. @croath
This page is out of date. Refresh to see the latest.
View
15 examples/MapKitExample/scripts/SimpleAnnotation.lua
@@ -2,13 +2,16 @@ waxClass{"SimpleAnnotation", NSObject, protocols={"MKAnnotation"}}
function initWithLatLong(self, lat, long)
self.super:init()
- self.lat = lat
- self.long = long
+ if self then
+ self.lat = lat
+ self.long = long
- -- These variables have underscores because they would have conflicted with
- -- method names required by the MKAnnotation protocol.
- self._title = 'Untitled'
- self._subtitle = ''
+ -- These variables have underscores because they would have conflicted with
+ -- method names required by the MKAnnotation protocol.
+ self._title = 'Untitled'
+ self._subtitle = ''
+ end
+ return self
end
function coordinate(self)
View
13 examples/MapKitExample/scripts/SimpleMapController.lua
@@ -4,11 +4,14 @@ waxClass{"SimpleMapController", UIViewController, protocols={"MKMapViewDelegate"
function init(self)
self.super:init()
- -- San Francisco, CA
- self.location = {
- lat=37.7749295,
- long=-122.4194155,
- }
+ if self then
+ -- San Francisco, CA
+ self.location = {
+ lat=37.7749295,
+ long=-122.4194155,
+ }
+ end
+ return self
end
function viewDidLoad(self)
Something went wrong with that request. Please try again.