You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Update dropbox-api-spec to point to more recent version (Sept 01, 2022) [#431](https://github.com/dropbox/dropbox-sdk-java/pull/431)
4
+
- Generated stone api code is now checked into repository for greater visibility of spec changes [#418](https://github.com/dropbox/dropbox-sdk-java/pull/418)
- Added gradle version catalog [#414](https://github.com/dropbox/dropbox-sdk-java/pull/414)[#436](https://github.com/dropbox/dropbox-sdk-java/pull/436)
7
+
- Moved android code from `dropbox-sdk-java` into `dropbox-sdk-android`[#429](https://github.com/dropbox/dropbox-sdk-java/pull/429)
8
+
- Converted Java code to Kotlin in `dropbox-sdk-android` while mostly maintaining binary compatibility. [#430](https://github.com/dropbox/dropbox-sdk-java/pull/430)
9
+
- Binary Compatibility Changes since `v5.3.0`[#449](https://github.com/dropbox/dropbox-sdk-java/pull/449) ([see changes](https://github.com/dropbox/dropbox-sdk-java/pull/441/commits/fd9b0a56152d72cd8310c849dbbe42ee239ff371?diff=unified&w=0)):
10
+
- The following classes are now `final` and cannot be extended.
Copy file name to clipboardExpand all lines: README.md
+28-17Lines changed: 28 additions & 17 deletions
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,3 @@
1
-
# ⚠️ Please use version `5.3.0` or `5.4.1` (These versions are identical). Version `5.4.0` was published prematurely due to a scripting misconfiguration. A follow up release is actively being worked on and will be released during this week (September 27th-30th). Thank you! ⚠️
* Example for a simple web app: [Web File Browser example](examples/web-file-browser/src/main/java/com/dropbox/core/examples/web_file_browser/DropboxAuth.java)
162
+
* Example for a simple web app: [Web File Browser example](examples/examples/src/main/java/com/dropbox/core/examples/web_file_browser/DropboxAuth.java)
165
163
* Example for an Android app written in Kotlin: [Android Kotlin Example](examples/android)
166
-
* Example for a command-line tool: [Command-Line Authorization example](examples/authorize/src/main/java/com/dropbox/core/examples/authorize/Main.java)
167
164
168
165
To try out running these examples, please follow the instructions below.
169
166
@@ -265,20 +262,36 @@ To run individual tests, use the `--tests` gradle test filter:
Android support *** CALL OUT METHODS USED TO AUTHENTICATE ***
269
268
270
-
In the event you are using the Android-specific code in this library (i.e. the code in `com.dropbox.core.android` package), you will need to add some code to your `AndroidManifest.xml` when you bump your target SDK version to 30. If your app does not use this code, you can ignore this section.
269
+
### Required Dependencies For Android
270
+
The Android code in this SDK is written in Kotlin and is now a runtime dependency. If you do not already have Kotlin in your project, you will need to add `implementation("org.jetbrains.kotlin:kotlin-stdlib:1.6.21")` to your dependencies block.
271
271
272
-
When targeting/running on Android 11 (targetSdk 30 in your app's `build.gradle`), the Android OS will restrict what installed apps your app can query for through the `PackageManager`. Since the android code in this library queries for the official Dropbox app, those restrictions will affect your app when you target SDK 30. In particular, if you don't declare that your app queries for the official Dropbox app, then you will see crashes when you hit the code that talks to the official Dropbox app.
272
+
The last published version without Kotlin is `5.3.0`. All future Android code will be written in Kotlin.
273
273
274
-
To resolve the issue, add the following to your`AndroidManifest.xml`
274
+
###`AndroidManifest.xml`
275
275
276
+
The following two entries may need to be added to your `AndroidManifest.xml` depending on your target SDK level.
277
+
278
+
For SDK levels >= `30`
276
279
```xml
277
280
<queries>
278
281
<packageandroid:name="com.dropbox.android" />
279
282
</queries>
280
283
```
281
284
285
+
For SDK levels >= `33`
286
+
287
+
See [#406](https://github.com/dropbox/dropbox-sdk-java/issues/406) for context
We are working on pulling out this Android-specific code into its own android library with an `AndroidManifest.xml` that can be merged with your existing manifest, but in the meantime, this will work.
OSGi containers running on Java 1.6 or above should provide this capability. Unfortunately, some OSGi containers don't do this correctly and will reject the bundle JAR in the OSGi subsystem context.
320
+
Most OSGi containers should provide this capability. Unfortunately, some OSGi containers don't do this correctly and will reject the bundle JAR in the OSGi subsystem context.
308
321
309
322
As a workaround, you can build your own version of the JAR that omits the "osgi.ee" capability by running:
(This is equivalent to passing the "-noee" option to the OSGi "bnd" tool.)
@@ -334,5 +347,3 @@ Versions 2.0.0-2.0.3 of this SDK require SDK-specific ProGuard rules when shrink
334
347
-dontwarn javax.servlet.**
335
348
-dontwarn org.apache.**
336
349
```
337
-
338
-
**IMPORTANT: If you are running version 2.0.x before 2.0.3, you should update to the latest Dropbox SDK version to avoid a deserialization bug that can cause Android apps that use ProGuard to crash.**
2. Build the SDK: run `./gradlew build` in the SDK root directory (two levels up from this folder).
15
15
3. In Android Studio, choose "Import Project" and select this folder.
16
-
4. Edit local.properties and add `DROPBOX_APP_KEY=YOUR_KEY_HERE` with your Dropbox API key ([how to get a Dropbox API key](../../ReadMe.md#get-a-dropbox-api-key)).
16
+
4. Edit local.properties and add `DROPBOX_APP_KEY=YOUR_KEY_HERE` with your Dropbox API key ([how to get a Dropbox API key](../../README.md#get-a-dropbox-api-key)).
17
17
5. Build and run.
18
18
19
19
If you don't have Android Studio, you can use the command-line:
0 commit comments