Google map for IOS

Are there any guide to use google map in silver?

Same as it would be to use from Xcode, really. Grab the .framework, (run it thru the FXGen to generate a .fx file; especially easy with .2253 and later as that’s now exposed in the Fire UI, under Tools), then use the exact same APIs as documented by Google.

(disclaimer, I have not personally used Google Maps API)

I have downloaded the google map sdk. Then using FXGen->import sdk from XCode, choose the GoogleMaps.framework but it has go to list down files inside the framework.

Did I miss something?


FXGen -> import Third Party .framework is disabled.

You need a newer version of Fire. IIrc this was added in 2251.

old FXGen doesn’t support frameworks automatically. but you can use the last tab with simple custom script:

//var hi = "/Users/mh/Code/Fire/Bin/Build/macOS/Fire.app/Contents/Resources/HeaderImporter.exe";
var fxBaseFolder = "/Users/mh/Code/Elements/Bin/Toffee SDKs";
//var developerFolder = "/Users/mh/Applications/Xcode-9.2GM.app/Contents/Developer";
//include("/Users/mh/Code/Fire/Bin/Build/macOS/Fire.app/Contents/Resources/generate.train");
iOSSdkVersion="11.2";
processIOSFramework({
    framework: "/path/to/your.framework",
    link: [],
    destinationFolder: "/path/to/folder/where/you/want/the/fx"
});
file.remove("/var/folders/wl/n_01zc255cv_1b994z_kdf9c0000gn/T/D666A62B-2516-4853-B70F-B56F48AA1773.train")

(the three lines I commented out via // should be added by FXGen automatically IIRC. if not, adjust them to match your folders and add em in.

I already using Fire 2551 already.

Hmm, maybe its new in 2253 then. i can’t keep track on a week-by-week basis ;).

ok. 2253 is in preview channel. Thanks.

I have imported the framework using FXGen but I can’t import the library.
import GoogleMaps -> error (unknown namespace).

what namespace did you set when importing it? can you post the.fx and source files the impor generated? the source files (eg the .cs) should tell you what namespace it has.

Files can be downloaded here imported fx

The successfully imported framework is GoogleMapsBase.framework but it fail when import GoogleMaps.framework. Here the error code:
An error occurred: HeaderImporter.ParserException: GoogleMaps/GMSGeometryUtils.h (44:13 pp: 22013) One of semicolon, comma, (eof) expected; current token: Identifier (GMSProject)
Surrounded by:
at HeaderImporter.CParser.RaiseError (System.String aError) [0x00136] in :0
at HeaderImporter.CParser.Expect (HeaderImporter.TokenKind[] aTokens) [0x00042] in :0
at HeaderImporter.CParser.ParseDeclaration (System.Boolean aAllowFunction, System.Action1[T] aAddToParent, System.Boolean aALlowIn) [0x00576] in <c892aa0bc8ea410b8a3d41e0140b8dbc>:0 at HeaderImporter.CParser.ParseDeclaration (System.Boolean aAllowFunction, System.Action1[T] aAddToParent, System.Boolean aALlowIn) [0x002a1] in :0
at HeaderImporter.CParser.Parse () [0x00054] in :0
at HeaderImporter.Import.DoImportWithState (System.String aFileName) [0x003fb] in :0

            Error calling Process.Execute: Failed with error code: 1

System.Exception: Failed with error code: 1
at RemObjects.Train.API.Shell.Exec (RemObjects.Script.EcmaScript.ExecutionContext ec, System.Object aSelf, System.Object[] args) [0x003b9] in :0

It sounds like the second import doesn’t see the first, but needs it for reference.

try adding

  frameworkpaths = "/path/to/folder/with/first/fx/",
  frameworks = "GoogleMapsBase"

to the options set.

I’m sorry. How/where to set the options?