Skip to content

Commit

Permalink
Merge pull request #695 from OneSignal/major_release_3.0.0
Browse files Browse the repository at this point in the history
Major release 3.0.0
  • Loading branch information
jkasten2 authored Aug 6, 2021
2 parents beb1290 + ded0b88 commit 0c873a9
Show file tree
Hide file tree
Showing 28 changed files with 2,307 additions and 1,144 deletions.
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
{
"version": "2.11.4",
"version": "3.0.0",

"name": "onesignal-cordova-plugin",
"cordova_name": "OneSignal Push Notifications",
"description": "OneSignal is a high volume Push Notification service for mobile apps. In addition to basic notification delivery, OneSignal also provides tools to localize, target, schedule, and automate notifications that you send.",
"license": "MIT",
"main": "www/OneSignalPlugin.js",
"typings": "types/index.d.ts",
"keywords": [
"push",
"notification",
Expand All @@ -23,7 +25,6 @@
"platforms": [
"android",
"ios",
"windows",
"amazon-fireos"
],
"engines": [
Expand Down Expand Up @@ -53,7 +54,6 @@
"platforms": [
"android",
"ios",
"windows",
"amazon-fireos"
]
},
Expand Down
82 changes: 29 additions & 53 deletions plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@
<plugin xmlns="http://www.phonegap.com/ns/plugins/1.0"
xmlns:android="http://schemas.android.com/apk/res/android"
id="onesignal-cordova-plugin"
version="2.11.4">
version="3.0.0">

<name>OneSignal Push Notifications</name>
<author>Josh Kasten, Bradley Hesse, Rodrigo Gomez-Palacio</author>

<description>OneSignal is a high volume Push Notification service for mobile apps. In addition to basic notification delivery, OneSignal also provides tools to localize, target, schedule, A/B test, and automate notifications that you send.</description>

<keywords>push,notification,push notification,push notifications,apns,gcm,adm,retention,messaging,ios,android,windows phone</keywords>
<keywords>push,notification,push notification,push notifications,apns,gcm,adm,retention,messaging,ios,android</keywords>

<license>MIT</license>

<js-module src="www/OneSignal.js" name="OneSignal">
<js-module src="www/OneSignalPlugin.js" name="OneSignalPlugin">
<clobbers target="OneSignal" />
</js-module>

Expand All @@ -25,43 +25,29 @@
<engine name="apple-ios" version=">=7.0.0" />
</engines>

<js-module src="www/NotificationReceived.js" name="NotificationReceived" />
<js-module src="www/NotificationOpened.js" name="NotificationOpened" />
<js-module src="www/InAppMessage.js" name="InAppMessage" />
<js-module src="www/Subscription.js" name="Subscription" />

<platform name="android">
<framework src="com.onesignal:OneSignal:3.16.0" />
<framework src="com.onesignal:OneSignal:4.4.2" />
<framework src="build-extras-onesignal.gradle" custom="true" type="gradleReference" />

<config-file target="res/xml/config.xml" parent="/*">
<feature name="OneSignalPush" >
<param name="android-package" value="com.plugin.gcm.OneSignalPush" />
<param name="android-package" value="com.onesignal.cordova.OneSignalPush" />
</feature>
</config-file>

<!-- PhoneGap Build (PGB) does not have a amazon build target so it include the required manifest entries in all Android builds. -->
<config-file target="AndroidManifest.xml" parent="/manifest">
<uses-permission android:name="com.amazon.device.messaging.permission.RECEIVE" />
<permission android:name="$PACKAGE_NAME.permission.RECEIVE_ADM_MESSAGE" android:protectionLevel="signature" />
<uses-permission android:name="$PACKAGE_NAME.permission.RECEIVE_ADM_MESSAGE" />
</config-file>
<config-file target="AndroidManifest.xml" parent="/manifest/application">
<amazon:enable-feature android:name="com.amazon.device.messaging" android:required="false" xmlns:amazon="http://schemas.amazon.com/apk/res/android" />
<service android:name="com.onesignal.ADMMessageHandler" android:exported="false" />
<receiver
android:name="com.onesignal.ADMMessageHandler$Receiver"
android:permission="com.amazon.device.messaging.permission.SEND" >
<intent-filter>
<action android:name="com.amazon.device.messaging.intent.REGISTRATION" />
<action android:name="com.amazon.device.messaging.intent.RECEIVE" />
<category android:name="$PACKAGE_NAME" />
</intent-filter>
</receiver>
</config-file>

<source-file src="src/android/com/plugin/gcm/OneSignalPush.java" target-dir="src/com/plugin/gcm/" />
<source-file src="src/android/com/plugin/gcm/OneSignalController.java" target-dir="src/com/plugin/gcm/" />
<source-file src="src/android/com/plugin/gcm/OneSignalEmailController.java" target-dir="src/com/plugin/gcm/" />
<source-file src="src/android/com/plugin/gcm/OneSignalObserverController.java" target-dir="src/com/plugin/gcm/" />
<source-file src="src/android/com/plugin/gcm/OneSignalOutcomeController.java" target-dir="src/com/plugin/gcm/" />
<source-file src="src/android/com/plugin/gcm/OneSignalInAppMessagingController.java" target-dir="src/com/plugin/gcm/" />
<source-file src="src/android/com/plugin/gcm/CallbackHelper.java" target-dir="src/com/plugin/gcm/" />
<source-file src="src/android/com/onesignal/cordova/OneSignalPush.java" target-dir="src/com/onesignal/cordova/" />
<source-file src="src/android/com/onesignal/cordova/OneSignalController.java" target-dir="src/com/onesignal/cordova/" />
<source-file src="src/android/com/onesignal/cordova/OneSignalEmailController.java" target-dir="src/com/onesignal/cordova/" />
<source-file src="src/android/com/onesignal/cordova/OneSignalSMSController.java" target-dir="src/com/onesignal/cordova/" />
<source-file src="src/android/com/onesignal/cordova/OneSignalObserverController.java" target-dir="src/com/onesignal/cordova/" />
<source-file src="src/android/com/onesignal/cordova/OneSignalOutcomeController.java" target-dir="src/com/onesignal/cordova/" />
<source-file src="src/android/com/onesignal/cordova/OneSignalInAppMessagingController.java" target-dir="src/com/onesignal/cordova/" />
<source-file src="src/android/com/onesignal/cordova/CallbackHelper.java" target-dir="src/com/onesignal/cordova/" />
</platform>

<!-- ios -->
Expand All @@ -70,11 +56,9 @@
<config-file target="config.xml" parent="/*">
<feature name="OneSignalPush">
<param name="ios-package" value="OneSignalPush"/>
</feature>
</feature>
</config-file>

<framework src="SystemConfiguration.framework" />

<config-file target="*-Info.plist" parent="UIBackgroundModes">
<array>
<string>remote-notification</string>
Expand All @@ -88,28 +72,20 @@
<string>production</string>
</config-file>

<framework src="OneSignal" type="podspec" spec="2.16.5" />
<podspec>
<config>
<source url="https://github.com/CocoaPods/Specs.git"/>
<source url="https://github.com/OneSignal/OneSignal-iOS-SDK.git"/>
</config>
<pods use-frameworks="true">
<pod name="OneSignalXCFramework" spec="3.6.0" />
</pods>
</podspec>

<header-file src="src/ios/OneSignalPush.h" />
<source-file src="src/ios/OneSignalPush.m" />

</platform>

<!-- Windows Phone 8.1 -->
<platform name="windows">
<config-file target="config.xml" parent="/*">
<feature name="OneSignalPush">
<param name="ios-package" value="OneSignalPush"/>
</feature>
</config-file>

<js-module src="src/windows/OneSignalPushProxy.js" name="OneSignalPushProxy">
<merges target="" />
</js-module>

<framework src="src/windows/OneSignalSDK_WP_WNS_WRTC.winmd" custom="true" />
<framework src="src/windows/OneSignalSDK_WP_WNS.dll" custom="true" />
<framework src="src/windows/Newtonsoft.Json.dll" custom="true" />
</platform>

</plugin>

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package com.plugin.gcm;
package com.onesignal.cordova;

import org.apache.cordova.CallbackContext;
import org.json.JSONObject;
Expand Down
Loading

0 comments on commit 0c873a9

Please sign in to comment.