Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate OwncloudClient - DirectEditing #12267

Merged
merged 7 commits into from
Jun 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -324,8 +324,8 @@ private void updateCapabilities() {
}

private void updateDirectEditing(ArbitraryDataProvider arbitraryDataProvider, String newDirectEditingEtag) {
RemoteOperationResult<DirectEditing> result = new DirectEditingObtainRemoteOperation().execute(user,
mContext);
RemoteOperationResult<DirectEditing> result =
new DirectEditingObtainRemoteOperation().executeNextcloudClient(user, mContext);

if (result.isSuccess()) {
DirectEditing directEditing = result.getResultData();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,15 +47,15 @@ protected String doInBackground(Void... voids) {
return "";
}

RemoteOperationResult result = new DirectEditingOpenFileRemoteOperation(file.getRemotePath(), editor.getId())
.execute(user, editorWebViewWeakReference.get());
RemoteOperationResult<String> result = new DirectEditingOpenFileRemoteOperation(file.getRemotePath(), editor.getId())
.executeNextcloudClient(user, editorWebView);


if (!result.isSuccess()) {
return "";
}

return (String) result.getData().get(0);
return result.getResultData();
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -282,12 +282,13 @@ class ChooseTemplateDialogFragment : DialogFragment(), View.OnClickListener, Tem
override fun doInBackground(vararg params: Void): String {
return try {
val client = clientFactory!!.create(user)
val nextcloudClient = clientFactory.createNextcloudClient(user)
val result = DirectEditingCreateFileRemoteOperation(
path,
creator!!.editor,
creator.id,
template.title
).execute(client)
).execute(nextcloudClient)
if (!result.isSuccess) {
return ""
}
Expand Down Expand Up @@ -352,7 +353,7 @@ class ChooseTemplateDialogFragment : DialogFragment(), View.OnClickListener, Tem

override fun doInBackground(vararg voids: Void): TemplateList {
return try {
val client = clientFactory!!.create(user)
val client = clientFactory!!.createNextcloudClient(user)
val result = DirectEditingObtainListOfTemplatesRemoteOperation(
creator!!.editor,
creator.id
Expand Down
3 changes: 2 additions & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
*/
buildscript {
ext {
androidLibraryVersion = "cda1b08aa81b74201177f29c2326abee62f32c15"
androidLibraryVersion = "354911a81da973d8874381480ed0ea577e992572"
androidPluginVersion = '8.4.0'
androidxMediaVersion = '1.3.1'
androidxTestVersion = "1.5.0"
Expand All @@ -23,6 +23,7 @@ buildscript {
jacoco_version = '0.8.12'
kotlin_version = '2.0.0'
markwonVersion = "4.6.2"
prismVersion = "2.0.0"
mockitoVersion = "4.11.0"
mockitoKotlinVersion = "4.1.0"
mockkVersion = "1.13.10"
Expand Down
14 changes: 13 additions & 1 deletion gradle/verification-metadata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -667,7 +667,8 @@
</component>
<component group="androidx.arch.core" name="core-runtime" version="2.2.0">
<artifact name="core-runtime-2.2.0.aar">
<sha256 value="a1be5e0caa2b07623862af6ae21b3ab0718123245184d0e30dea81b53f990a47" origin="Generated by Gradle"/>
<sha256 value="a1be5e0caa2b07623862af6ae21b3ab0718123245184d0e30dea81b53f990a47"
origin="Generated by Gradle" reason="Artifact is not signed" />
</artifact>
<artifact name="core-runtime-2.2.0.module">
<sha256 value="a8b17513949e5db6c9601c30be19df953762dd877512f1e2cfcfae81d2440944" origin="Generated by Gradle" reason="Artifact is not signed"/>
Expand Down Expand Up @@ -5749,6 +5750,17 @@
<sha256 value="b4f19aae9d8687651cf8f760cb89be155cfa0a9aed818cb50cfbcb15f36c9f2d" origin="Generated by Gradle" reason="Artifact is not signed"/>
</artifact>
</component>
<component group="com.github.nextcloud" name="android-library"
version="354911a81da973d8874381480ed0ea577e992572">
<artifact name="android-library-354911a81da973d8874381480ed0ea577e992572.aar">
<sha256 value="a8db03b27d8289fd2e6d5cbe99712e7bb387628a83c387298287a4e5f20a0db0"
origin="Generated by Gradle" reason="Artifact is not signed" />
</artifact>
<artifact name="android-library-354911a81da973d8874381480ed0ea577e992572.module">
<sha256 value="803eeabdbf8e78808a42986a9e6ec7d5e7e74ec9024a38a577898ef699f504db"
origin="Generated by Gradle" reason="Artifact is not signed" />
</artifact>
</component>
<component group="com.github.nextcloud" name="android-library" version="5f92d92c490d2d9039bfd392cf16c61a37738646">
<artifact name="android-library-5f92d92c490d2d9039bfd392cf16c61a37738646.aar">
<sha256 value="adec67393e6d6a05d1d96ed4e4dd2e675999e43ca544ea069cee1dbac4d3132c" origin="Generated by Gradle" reason="Artifact is not signed"/>
Expand Down
Loading