Skip to content

Commit bf3b600

Browse files
authored
Merge pull request #34 from PSPDFKit/simone/android-6.5.2-update
Bump Android version and Cordova version
2 parents 03a0280 + fbe1fc2 commit bf3b600

File tree

4 files changed

+19
-6
lines changed

4 files changed

+19
-6
lines changed

docs/android/README.md

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ This plugin defines a global `PSPDFKit` object, which provides an API for viewin
99
## Requirements
1010
- Android SDK API level 19+ / Android 4.4+ (KitKat)
1111
- Cordova Android 8+.
12-
- PSPDFKit for Android 6.5
12+
- PSPDFKit for Android 6.5.2
1313

1414
## Installation
1515

@@ -157,9 +157,22 @@ cordova plugin add https://github.com/PSPDFKit/PSPDFKit-Cordova.git
157157
pspdfkit.license=LICENSE_STRING
158158
```
159159

160+
160161
> Note: If you're already a customer then please make sure that the package ID matches with your bundle ID that's assigned to your license (e.g. com.ionic.test). You can check this in your `AndroidManifest.xml` by searching for `package`. If you are using a trial license then you don't have to worry about that.
161162
162-
5. Now open your `index.js` file located in `www/js/` and paste the below code into the `receivedEvent: function(id)` function. For this to work you need to create a folder called `documents` in `www` and paste a PDF in this folder.
163+
5. PSPDFKit requires modern Jetpack libraries AndroidX. To enable AndroidX modify the `config.xml` adding the following line in the `android` section:
164+
165+
```diff
166+
...
167+
<platform name="android">
168+
+ <preference name="AndroidXEnabled" value="true" />
169+
<allow-intent href="market:*" />
170+
</platform>
171+
...
172+
173+
```
174+
175+
6. Now open your `index.js` file located in `www/js/` and paste the below code into the `onDeviceReady()` function. For this to work you need to create a folder called `documents` in `www` and paste a PDF in this folder.
163176

164177
```javascript
165178
PSPDFKit.presentFromAssets("www/documents/A.pdf", {
@@ -171,7 +184,7 @@ PSPDFKit.presentFromAssets("www/documents/A.pdf", {
171184
});
172185
```
173186

174-
6. You are now ready to build and test your app!
187+
7. You are now ready to build and test your app!
175188

176189
```shell
177190
cordova build

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "pspdfkit-cordova",
3-
"version": "1.1.0",
3+
"version": "1.1.1",
44
"description": "PSPDFKit Cordova Plugin for Android and iOS",
55
"cordova": {
66
"id": "pspdfkit-cordova",

plugin.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="UTF-8"?>
2-
<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android" id="pspdfkit-cordova" version="1.1.0">
2+
<plugin xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android" id="pspdfkit-cordova" version="1.1.1">
33
<engines>
44
<engine name="cordova" version="&gt;=6.3.1" />
55
</engines>

src/android/config.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,5 +31,5 @@ if (pspdfkitLicense == null || pspdfkitLicense == '') {
3131
ext.pspdfkitMavenModuleName = 'pspdfkit'
3232
ext.pspdfkitVersion = localProperties.getProperty('pspdfkit.version')
3333
if (pspdfkitVersion == null || pspdfkitVersion == '') {
34-
ext.pspdfkitVersion = '6.5.0'
34+
ext.pspdfkitVersion = '6.5.2'
3535
}

0 commit comments

Comments
 (0)