This repository has been archived by the owner on May 17, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from yandexmobile/release-0.1.1
Release AppMetrica Push Unity Plugin 0.1.1
- Loading branch information
Showing
52 changed files
with
520 additions
and
104 deletions.
There are no files selected for viewing
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
YandexMetricaPushPluginSample/Assets/AppMetricaPush/AppMetricaPush.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
...ricaPushPluginSample/Assets/AppMetricaPush/Editor/PostprocessBuildPlayerAppMetricaPush.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
/* | ||
* Version for Unity | ||
* © 2017 YANDEX | ||
* You may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* https://yandex.com/legal/appmetrica_sdk_agreement/ | ||
*/ | ||
|
||
using UnityEngine; | ||
using UnityEditor; | ||
using UnityEditor.Callbacks; | ||
using UnityEditor.iOS.Xcode; | ||
using System.IO; | ||
using System.Collections; | ||
|
||
/// <summary> | ||
/// Postprocess build player for AppMetrica Push. | ||
/// See https://bitbucket.org/Unity-Technologies/iosnativecodesamples/src/ae6a0a2c02363d35f954d244a6eec91c0e0bf194/NativeIntegration/Misc/UpdateXcodeProject/ | ||
/// </summary> | ||
|
||
public class PostprocessBuildPlayerAppMetricaPush | ||
{ | ||
private static readonly string[] WeakFrameworks = { | ||
"UserNotifications" | ||
}; | ||
|
||
[PostProcessBuild] | ||
public static void OnPostprocessBuild (BuildTarget buildTarget, string path) | ||
{ | ||
if (buildTarget == BuildTarget.iOS) { | ||
var projectPath = path + "/Unity-iPhone.xcodeproj/project.pbxproj"; | ||
|
||
var project = new PBXProject (); | ||
project.ReadFromString (File.ReadAllText (projectPath)); | ||
|
||
var target = project.TargetGuidByName ("Unity-iPhone"); | ||
|
||
foreach (var frameworkName in WeakFrameworks) { | ||
project.AddFrameworkToProject (target, frameworkName + ".framework", true); | ||
} | ||
|
||
File.WriteAllText (projectPath, project.WriteToString ()); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
YandexMetricaPushPluginSample/Assets/AppMetricaPush/ExampleUI/PushSampleSceneManager.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10 changes: 9 additions & 1 deletion
10
YandexMetricaPushPluginSample/Assets/AppMetricaPush/IYandexAppMetricaPush.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file modified
BIN
-4.3 KB
(46%)
...caPushPluginSample/Assets/AppMetricaPush/Plugins/Android/appmetrica-push-unity-plugin.aar
Binary file not shown.
Binary file removed
BIN
-44 KB
...MetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/mobmetricapushlib-0.5.0.jar
Binary file not shown.
Binary file added
BIN
+44.9 KB
...MetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/mobmetricapushlib-0.6.1.aar
Binary file not shown.
Binary file added
BIN
+411 KB
...tricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/play-services-base-10.2.1.aar
Binary file not shown.
Binary file removed
BIN
-491 KB
...etricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/play-services-base-9.6.1.aar
Binary file not shown.
Binary file added
BIN
+342 KB
...aPushPluginSample/Assets/AppMetricaPush/Plugins/Android/play-services-basement-10.2.1.aar
Binary file not shown.
Binary file removed
BIN
-485 KB
...caPushPluginSample/Assets/AppMetricaPush/Plugins/Android/play-services-basement-9.6.1.aar
Binary file not shown.
Binary file added
BIN
+36.6 KB
...etricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/play-services-gcm-10.2.1.aar
Binary file not shown.
Binary file removed
BIN
-34.4 KB
...MetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/play-services-gcm-9.6.1.aar
Binary file not shown.
Binary file added
BIN
+16.4 KB
...etricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/play-services-iid-10.2.1.aar
Binary file not shown.
Binary file removed
BIN
-18 KB
...MetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/play-services-iid-9.6.1.aar
Binary file not shown.
Binary file removed
BIN
-594 KB
...exMetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-compat-24.2.1.aar
Binary file not shown.
Binary file added
BIN
+621 KB
...exMetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-compat-26.1.0.aar
Binary file not shown.
Binary file removed
BIN
-236 KB
...xMetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-core-ui-24.2.1.aar
Binary file not shown.
Binary file added
BIN
+228 KB
...xMetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-core-ui-26.1.0.aar
Binary file not shown.
Binary file removed
BIN
-90.3 KB
...tricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-core-utils-24.2.1.aar
Binary file not shown.
Binary file added
BIN
+85.1 KB
...tricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-core-utils-26.1.0.aar
Binary file not shown.
Binary file removed
BIN
-135 KB
...MetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-fragment-24.2.1.aar
Binary file not shown.
Binary file added
BIN
+161 KB
...MetricaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-fragment-26.1.0.aar
Binary file not shown.
Binary file removed
BIN
-243 KB
...icaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-media-compat-24.2.1.aar
Binary file not shown.
Binary file added
BIN
+305 KB
...icaPushPluginSample/Assets/AppMetricaPush/Plugins/Android/support-media-compat-26.1.0.aar
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
...Plugins/iOS/YandexMobileMetricaPush.framework/Headers/YMPUserNotificationCenterDelegate.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
/* | ||
* YMPUserNotificationCenterDelegate.h | ||
* | ||
* This file is a part of the AppMetrica | ||
* | ||
* Version for iOS © 2017 YANDEX | ||
* | ||
* You may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at https://yandex.com/legal/metrica_termsofuse/ | ||
*/ | ||
|
||
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= __IPHONE_10_0 | ||
#define YMP_USER_NOTIFICATIONS_CENTER_AVAILABLE | ||
#endif | ||
|
||
#ifdef YMP_USER_NOTIFICATIONS_CENTER_AVAILABLE | ||
|
||
#import <UserNotifications/UserNotifications.h> | ||
|
||
/** Delegate for handling foreground push notifications on iOS 10+. | ||
To handle foreground push notifications execute this line before application finished launching: | ||
[UNUserNotificationCenter currentNotificationCenter].delegate = [YMPYandexMetricaPush userNotificationCenterDelegate]; | ||
*/ | ||
@protocol YMPUserNotificationCenterDelegate <UNUserNotificationCenterDelegate> | ||
|
||
@required | ||
|
||
/** Notification presentation options to be passed into completion handler of | ||
userNotificationCenter:willPresentNotification:withCompletionHandler: | ||
This delegate calls handler only if nextDelegate property is not set | ||
or if an object in nextDelegate doesn't respond to the selector above. | ||
*/ | ||
@property (nonatomic, assign) UNNotificationPresentationOptions presentationOptions; | ||
|
||
/** Delegate to which calls of this protocol will be proxied. | ||
*/ | ||
@property (nonatomic, weak, nullable) id<UNUserNotificationCenterDelegate> nextDelegate; | ||
|
||
@end | ||
|
||
#endif |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.