-
-
Notifications
You must be signed in to change notification settings - Fork 129
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
added showPin option to snapshotter #478
base: master
Are you sure you want to change the base?
Conversation
when snapshotting a location the option to display a pin (annotation) in the snapshot image was missing option "showPin" (default is set to FALSE) will allow to display a pin var Snapshotter = .Map.createSnapshotter({ mapType: global.Map.NORMAL_TYPE, showPin:true, region: { latitude: location.latitude, longitude: location.longitude }, size: { width: 300, height: 200 } });
|
@mbender74 there are some linting errors e.g. https://github.com/appcelerator-modules/ti.map/blob/a984949b96e737d8c058a968a13c3f23efe882fd/ios/Classes/TiMapSnapshotterProxy.m#L39-L40 or that try to run |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good and should be merged.
any other comments? @m1ga @mbender74
only looking at the files here: not sure about the change of the package-lock file. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Happy to take this once the proposed changes are in! 🙂 In addition, please add the new property to the api docs and bump the manifest version to the next minor (e.g. 7.3.0 to 7.4.0)
@@ -12,6 +12,10 @@ | |||
|
|||
@implementation TiMapSnapshotterProxy | |||
|
|||
CLLocationDegrees latitudeCoord; | |||
CLLocationDegrees longitudeCoord; | |||
bool showPin = NO; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please save the resulting CLLocationCoordinate2D
instead, also use the ObjC BOOL
type
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
oh dear, this is old, I already forgot, I did this PR :-D
Ok, I will take care about this all next week ;-)
|
||
TiBlob *blob = [[TiBlob alloc] initWithImage:snapshot.image]; | ||
TiBlob *blob; | ||
if (showPin == YES) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No explicit == YES
check necessary
@@ -4,7 +4,7 @@ | |||
// OF YOUR TITANIUM SDK YOU'RE BUILDING FOR | |||
// | |||
// | |||
TITANIUM_SDK_VERSION = 10.0.1.GA | |||
TITANIUM_SDK_VERSION = 10.0.0.GA |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Restore the version change (pulling from main
should use a recent one)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Restore this file
when snapshotting a location the option to display a pin (annotation) in the snapshot image was missing
option "showPin" (default is set to FALSE) will allow to display a pin