Skip to content

Commit

Permalink
Added sources and removed Firebase from the iOS plugin. Not it lives …
Browse files Browse the repository at this point in the history
…in separate plugin
  • Loading branch information
Shchvova committed Dec 27, 2020
1 parent e3672c6 commit c6076a5
Show file tree
Hide file tree
Showing 360 changed files with 23,539 additions and 12 deletions.
16 changes: 15 additions & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ on:
push:
paths:
- 'plugins/**'
repository_dispatch:

env:
releaseName: v${{ github.run_number }}
Expand All @@ -24,6 +25,7 @@ jobs:
(
if [ ! -d "$platform" ] ; then continue ; fi
cd "$platform"
if ! ls * &> /dev/null ; then continue ; fi
COPYFILE_DISABLE=true tar -czvf ../../"$build-$platform.tgz" --exclude=".*" *
)
done
Expand All @@ -37,4 +39,16 @@ jobs:
tag_name: ${{ env.releaseName }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

- name: Directory update request
run: |
[ -z "${{ secrets.ISSUE_PAT }}" ] && echo "Skipping, no ISSUE_PAT" && exit 0
curl --request POST \
--url https://api.github.com/repos/solar2d/plugins.solar2d.com/dispatches \
--header 'authorization: Bearer ${{ secrets.ISSUE_PAT }}' \
--header 'content-type: application/json' \
--data '{
"event_type": "repo_updated",
"client_payload": {
"repo": "${{ github.repository }}"
}
}'
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
Sources for the plugin `plugin.notifications.v2`.
Sources for the plugin `plugin.notifications.v2` and `plugin.notifications.v2.firebase`

Add following to your `build.settings` to use:
```lua
{
plugins = {
"plugin.notifications.v2" = {
"[plugin.notifications.v2]" = {
publisherId = "com.coronalabs",
},
},
Expand Down
4 changes: 4 additions & 0 deletions plugins/2020.3569/android/corona.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
android.defaultConfig {
minSdkVersion Math.max(minSdkVersion?.apiLevel ?: 15, 16)
}
ext["minSdkVersion"] = Math.max(ext.find("minSdkVersion")?:15, 16)
7 changes: 0 additions & 7 deletions plugins/2020.3569/android/metadata.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,6 @@ local metadata =
<action android:name="com.google.firebase.MESSAGING_EVENT"/>
</intent-filter>
</service>
<service
android:name="plugin.notifications.v2.CoronaFirebaseInstanceIdService">
<intent-filter>
<action android:name="com.google.firebase.INSTANCE_ID_EVENT"/>
</intent-filter>
</service>
]]
}
}
Expand Down
Binary file modified plugins/2020.3569/android/plugin.notifications.v2.jar
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified plugins/2020.3569/iphone-sim/libNotificationsV2Plugin.a
Binary file not shown.
2 changes: 1 addition & 1 deletion plugins/2020.3569/iphone-sim/metadata.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ local metadata =
{
format = "staticLibrary",
staticLibs = { 'NotificationsV2Plugin', },
frameworks = { 'GoogleUtilities', 'protobuf', 'FBLPromises', 'FirebaseInstanceID', 'FirebaseMessaging', 'FirebaseInstallations', 'FirebaseCore', },
frameworks = { },
frameworksOptional = { "UserNotifications", "UserNotificationsUI" },
delegates = { "CoronaNotificationsDelegate" }
}
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file modified plugins/2020.3569/iphone/libNotificationsV2Plugin.a
Binary file not shown.
2 changes: 1 addition & 1 deletion plugins/2020.3569/iphone/metadata.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ local metadata =
{
format = "staticLibrary",
staticLibs = { 'NotificationsV2Plugin', },
frameworks = { 'GoogleUtilities', 'protobuf', 'FBLPromises', 'FirebaseInstanceID', 'FirebaseMessaging', 'FirebaseInstallations', 'FirebaseCore', },
frameworks = { },
frameworksOptional = { "UserNotifications", "UserNotificationsUI" },
delegates = { "CoronaNotificationsDelegate" }
}
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
8 changes: 8 additions & 0 deletions src/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
*xcuser*
build/
BuiltPlugin/
ios/libNotificationsV2Plugin.a
ios/libNotificationsV2Plugin.firebase.a
.gradle/
build/
.idea/
7 changes: 7 additions & 0 deletions src/Corona/.atom-build.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"cmd": "/Applications/Corona/Corona\\ Simulator.app/Contents/MacOS/Corona\\ Simulator",
"args": ["main.lua"],
"name": "Corona SDK",
"cwd": "{PROJECT_PATH}",
"sh": true
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_launcher_background"/>
<foreground android:drawable="@mipmap/ic_launcher_foreground"/>
</adaptive-icon>
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions src/Corona/AndroidResources/res/values/values.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_launcher_background">#e2e2e2</color>
</resources>
Binary file added src/Corona/Default-568h.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
40 changes: 40 additions & 0 deletions src/Corona/GoogleService-Info.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>AD_UNIT_ID_FOR_BANNER_TEST</key>
<string>ca-app-pub-3940256099942544/2934735716</string>
<key>AD_UNIT_ID_FOR_INTERSTITIAL_TEST</key>
<string>ca-app-pub-3940256099942544/4411468910</string>
<key>CLIENT_ID</key>
<string>532108303969-411utnrj5qonacu8ecghpd4q392qlur7.apps.googleusercontent.com</string>
<key>REVERSED_CLIENT_ID</key>
<string>com.googleusercontent.apps.532108303969-411utnrj5qonacu8ecghpd4q392qlur7</string>
<key>API_KEY</key>
<string>AIzaSyCNNa0PFeXPtX5QZnIux9uD92VYljHtB_0</string>
<key>GCM_SENDER_ID</key>
<string>532108303969</string>
<key>PLIST_VERSION</key>
<string>1</string>
<key>BUNDLE_ID</key>
<string>com.coronalabs.firebase.messaging</string>
<key>PROJECT_ID</key>
<string>fir-cloud-messaging-16d9a</string>
<key>STORAGE_BUCKET</key>
<string>fir-cloud-messaging-16d9a.appspot.com</string>
<key>IS_ADS_ENABLED</key>
<true/>
<key>IS_ANALYTICS_ENABLED</key>
<false/>
<key>IS_APPINVITE_ENABLED</key>
<false/>
<key>IS_GCM_ENABLED</key>
<true/>
<key>IS_SIGNIN_ENABLED</key>
<true/>
<key>GOOGLE_APP_ID</key>
<string>1:532108303969:ios:a7f606ca19b0b13b</string>
<key>DATABASE_URL</key>
<string>https://fir-cloud-messaging-16d9a.firebaseio.com</string>
</dict>
</plist>
Binary file added src/Corona/Icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
108 changes: 108 additions & 0 deletions src/Corona/Images.xcassets/AppIcon.appiconset/Contents.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,108 @@
{
"images" : [
{
"size" : "20x20",
"idiom" : "iphone",
"filename" : "Icon-40.png",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "Icon-58.png",
"scale" : "2x"
},
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "Icon-87.png",
"scale" : "3x"
},
{
"size" : "40x40",
"idiom" : "iphone",
"filename" : "Icon-80.png",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "40x40",
"scale" : "3x"
},
{
"size" : "60x60",
"idiom" : "iphone",
"filename" : "Icon-120.png",
"scale" : "2x"
},
{
"size" : "60x60",
"idiom" : "iphone",
"filename" : "Icon-180.png",
"scale" : "3x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "29x29",
"scale" : "2x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "1x"
},
{
"idiom" : "ipad",
"size" : "40x40",
"scale" : "2x"
},
{
"size" : "76x76",
"idiom" : "ipad",
"filename" : "Icon-76.png",
"scale" : "1x"
},
{
"size" : "76x76",
"idiom" : "ipad",
"filename" : "Icon-152.png",
"scale" : "2x"
},
{
"size" : "83.5x83.5",
"idiom" : "ipad",
"filename" : "Icon-167.png",
"scale" : "2x"
},
{
"size" : "1024x1024",
"idiom" : "ios-marketing",
"filename" : "Icon-1024.png",
"scale" : "1x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 6 additions & 0 deletions src/Corona/Images.xcassets/Contents.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"info" : {
"version" : 1,
"author" : "xcode"
}
}
Binary file not shown.
Binary file added src/Corona/LaunchScreen.storyboardc/Info.plist
Binary file not shown.
Binary file not shown.
31 changes: 31 additions & 0 deletions src/Corona/LaunchScreen.storyboardc/designable.storyboard
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="11762" systemVersion="16D32" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="01J-lp-oVM">
<device id="retina4_7" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="11757"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="EHf-IW-A2E">
<objects>
<viewController id="01J-lp-oVM" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="Llm-lL-Icb"/>
<viewControllerLayoutGuide type="bottom" id="xb3-aO-Qok"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3">
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</view>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="53" y="375"/>
</scene>
</scenes>
</document>
31 changes: 31 additions & 0 deletions src/Corona/build.settings
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
settings =
{
orientation =
{
default = "portrait",
supported = { "portrait" }
},

iphone =
{
useGoogleServicesJson = true,
xcassets = "Images.xcassets",
plist =
{
UIBackgroundModes = {"remote-notification"},
FirebaseAppDelegateProxyEnabled = false,
}
},

android =
{
minSDKVersion = 16,
useGoogleServicesJson = true,
},

plugins =
{
["plugin.notifications.v2.firebase"] = { publisherId = "com.coronalabs", },
-- ["plugin.notifications.v2"] = { publisherId = "com.coronalabs", },
}
}
18 changes: 18 additions & 0 deletions src/Corona/config.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
application =
{
content = {
width = 320,
height = 480,
scale = "letterbox"
},

notification = {
iphone = {
types = {
"badge",
"sound",
"alert"
}
}
}
}
Binary file added src/Corona/firebaselogo.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
42 changes: 42 additions & 0 deletions src/Corona/google-services.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"project_info": {
"project_number": "532108303969",
"firebase_url": "https://fir-cloud-messaging-16d9a.firebaseio.com",
"project_id": "fir-cloud-messaging-16d9a",
"storage_bucket": "fir-cloud-messaging-16d9a.appspot.com"
},
"client": [
{
"client_info": {
"mobilesdk_app_id": "1:532108303969:android:a7f606ca19b0b13b",
"android_client_info": {
"package_name": "com.coronalabs.firebase.messaging"
}
},
"oauth_client": [
{
"client_id": "532108303969-6hgarnooc5dclgmb7q9lu4f2k5l6qs9p.apps.googleusercontent.com",
"client_type": 3
}
],
"api_key": [
{
"current_key": "AIzaSyAdBEHHph7nxPlcAtpAkMXhIS5cSpOhcK8"
}
],
"services": {
"analytics_service": {
"status": 1
},
"appinvite_service": {
"status": 1,
"other_platform_oauth_client": []
},
"ads_service": {
"status": 2
}
}
}
],
"configuration_version": "1"
}
Loading

0 comments on commit c6076a5

Please sign in to comment.