Skip to content
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

Use of undeclared identifier 'allowIDFACollection'. #42

Open
georgepiva opened this issue Mar 11, 2015 · 5 comments
Open

Use of undeclared identifier 'allowIDFACollection'. #42

georgepiva opened this issue Mar 11, 2015 · 5 comments

Comments

@georgepiva
Copy link

In order to support Demographics and Interests inside my iOS application I extended the current Google Analytics Plugin for Unity to support the Google Analytics Services SDK for iOS v3.10 as follows:

  1. Download Google Analytics Services SDK for iOS v3.10;
  2. Replace Assets/Plugins/iOS/GAI* files by all GoogleAnalyticsServicesiOS-3.10/GoogleAnalytics/Library files;
  3. Replace Assets/Plugins/iOS/libGoogleAnalyticsServices.a file by the GoogleAnalyticsServicesiOS-3.10/libGoogleAnalyticsServices.a one;
  4. Add the GoogleAnalyticsServicesiOS-3.10/libAdIdAccess.a file to Assets/Plugins/iOS/;
  5. Replace the next Assets/Plugins/iOS/GAIHandler.m methods implementation:
id<GAITracker> trackerWithName(char *name, char *trackingId) {
    id<GAITracker> tracker = [[GAI sharedInstance] trackerWithName: [NSString stringWithUTF8String:name]
                                                        trackingId: [NSString stringWithUTF8String:trackingId]];
    tracker.allowIDFACollection = YES;
    return tracker;
}

id<GAITracker> trackerWithTrackingId(char *trackingId) {
    id<GAITracker> tracker = [[GAI sharedInstance] trackerWithTrackingId:[NSString stringWithUTF8String:trackingId ]];
    tracker.allowIDFACollection = YES;
    return tracker;
}

void setName(char *name) {
    id tracker = [[GAI sharedInstance] defaultTracker];
    [tracker set:kGAIScreenName
           value:[NSString stringWithUTF8String:name ]];
}

Will allowIDFACollection be supported inside the next plugin release?

@mhalttu
Copy link

mhalttu commented Mar 20, 2015

👍

Great job documenting the process, by the way.

@hantingxie
Copy link

Thank you for giving this solution. However I notice that there is currently no method called void setName(char *name) in my GAIHandler.mm, do you mean by adding this method at the same time?

@BestStream
Copy link

+1

@brentvincent
Copy link

+1, thanks, we needed this as well.

@ksnegov
Copy link

ksnegov commented Jul 14, 2017

Still waiting

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants