更新後,谷歌播放服務7.0.3我的自定義INSTALL_REFERRER braodcast接收器壞了。 我用CampaignTrackingService(也得到了更新)將意圖轉發到谷歌分析。自定義INSTALL_REFERRER接收器與多個跟蹤服務
在AndroidManifest.xml<receiver
android:name="myapp.analytics.installReferrer.InstallReferrerBroadcastReceiver"
android:exported="true">
<intent-filter>
<action android:name="com.android.vending.INSTALL_REFERRER" />
</intent-filter>
</receiver>
而且我的自定義廣播接收器
(這裏是問題):
public class InstallReferrerBroadcastReceiver extends BroadcastReceiver{
private final static String TAG = InstallReferrerBroadcastReceiver.class.getSimpleName();
@Override
public void onReceive(Context context, Intent intent) {
// Send to Different Analytics services
// Send to Google Analytics
CampaignTrackingService campaignTrackingService = new CampaignTrackingService();
// I used onHandleIntent() in google-play services 7.0.0, in 7.3.0 its gone
campaignTrackingService.onHandleIntent(intent);
}
}
歡迎來到堆棧。請告訴我們你曾經嘗試過什麼,以及你有什麼問題。一個好的開始將在這裏https://developers.google.com/analytics/devguides/collection/android/v4/campaigns – DaImTo