Skip to content
Closed
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
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,5 @@ fastlane/.idea
apps/captures

libs/DocumentScanner/build/
apps/buildSrc/src/main/java/candroid.keystore
open_source_data/student/google-services.json
1 change: 1 addition & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
[submodule "apps/mobile-offline-downloader-android"]
path = apps/mobile-offline-downloader-android
url = https://github.com/2uinc/mobile-offline-downloader-android.git
branch = main
7 changes: 0 additions & 7 deletions apps/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -45,13 +45,6 @@ allprojects {
}
mavenCentral()
maven { url 'https://jitpack.io' }
maven {
credentials {
username pspdfMavenUser
password pspdfMavenPass
}
url 'https://customers.pspdfkit.com/maven/'
}
maven { url "https://maven.google.com/" }
}
}
Expand Down
2 changes: 0 additions & 2 deletions apps/buildSrc/src/main/java/GlobalDependencies.kt
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ object Versions {

/* Others */
const val APOLLO = "4.1.1"
const val PSPDFKIT = "2024.8.0"
const val PHOTO_VIEW = "2.3.0"
const val MOBIUS = "1.2.1"
const val HILT = "2.52"
Expand Down Expand Up @@ -127,7 +126,6 @@ object Libs {
const val COMPOSE_VIEW_MODEL = "androidx.lifecycle:lifecycle-viewmodel-compose:${Versions.LIFECYCLE}"

/* Media and content handling */
const val PSPDFKIT = "com.pspdfkit:pspdfkit:${Versions.PSPDFKIT}"
const val EXOPLAYER = "com.google.android.exoplayer:exoplayer:2.18.5" // This is deprecated, we should migrate to https://developer.android.com/guide/topics/media/media3/getting-started/migration-guide
const val MEDIA3 = "androidx.media3:media3-exoplayer:${Versions.MEDIA3}"
const val MEDIA3_UI = "androidx.media3:media3-ui:${Versions.MEDIA3}"
Expand Down
4 changes: 2 additions & 2 deletions apps/buildSrc/src/main/java/OfflineDependencies.kt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
object OfflineDependencies {
const val versionCode = 10
const val versionName = "1.5"
const val versionCode = 15
const val versionName = "1.9"
const val constraintLayout = "2.1.0"
const val appCompat = "1.5.0"
const val recyclerView = "1.2.1"
Expand Down
10 changes: 0 additions & 10 deletions apps/parent/proguard-rules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -187,16 +187,6 @@
-dontwarn okhttp3.**
-keep class okhttp3.** { *; }

# PSPDFKit
-keep class com.pspdfkit.** { *; }
-dontwarn com.pspdfkit.**
-dontwarn sun.misc.**
-dontwarn android.view.WindowInsets
-dontwarn android.graphics.Insets
-dontwarn edu.umd.cs.findbugs.annotations.SuppressWarnings
-keepnames class io.reactivex.android.schedulers.AndroidSchedulers
-keepnames class io.reactivex.Observable

# RxJava
-keep class rx.internal.util.unsafe.** { *; }

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,6 @@ class AppManager : BaseAppManager() {

private fun initPendo() {
val options = Pendo.PendoOptions.Builder().setJetpackComposeBeta(true).build()
Pendo.setup(this, BuildConfig.PENDO_TOKEN, options, null)
// Pendo.setup(this, BuildConfig.PENDO_TOKEN, options, null)
Copy link

Copilot AI Nov 26, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Commenting out the Pendo initialization is unrelated to PDF/PSPDFKit removal and should not be part of this PR. This could break analytics functionality in the parent app.

Suggested change
// Pendo.setup(this, BuildConfig.PENDO_TOKEN, options, null)
Pendo.setup(this, BuildConfig.PENDO_TOKEN, options, null)

Copilot uses AI. Check for mistakes.
}
}
2 changes: 0 additions & 2 deletions apps/settings.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
/* Top-level project modules */
include ':student'
Copy link

Copilot AI Nov 26, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removing the teacher and parent module includes will break the build for those apps. This change appears to be accidental and unrelated to PSPDFKit removal.

Suggested change
include ':student'
include ':student'
include ':teacher'
include ':parent'

Copilot uses AI. Check for mistakes.
include ':teacher'
include ':parent'

/* Library modules */
include ':annotations'
Expand Down
1 change: 0 additions & 1 deletion apps/student/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ android {
/* Add private data */
PrivateData.merge(project, "student")
buildConfigField "String", "TRANSLATION_TAGS", "\"${LocaleScanner.getAvailableLanguageTags(project)}\""
buildConfigField "String", "PSPDFKIT_LICENSE_KEY", "\"$pspdfkitLicenseKey\""

testBuildType = "debug"

Expand Down
10 changes: 0 additions & 10 deletions apps/student/proguard-rules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -193,16 +193,6 @@
-dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
-dontwarn okhttp3.**

#PSPDFKit
-keep class com.pspdfkit.** { *; }
-dontwarn sun.misc.**
-dontwarn edu.umd.cs.findbugs.annotations.SuppressWarnings
-keepnames class io.reactivex.android.schedulers.AndroidSchedulers
-keepnames class io.reactivex.Observable
-dontwarn com.pspdfkit.**
-dontwarn android.view.WindowInsets
-dontwarn android.graphics.Insets

# Keep third party lib class names. PSPDFKit relies on those class names to be present.
-keepnames class rx.android.schedulers.AndroidSchedulers
-keepnames class rx.Observable
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -127,55 +127,6 @@ class PdfInteractionTest : StudentComposeTest() {
fileListPage.assertPdfPreviewDisplayed()
}

@Test
@TestMetaData(Priority.IMPORTANT, FeatureCategory.ASSIGNMENTS, TestCategory.INTERACTION, SecondaryFeatureCategory.SUBMISSIONS_ANNOTATIONS)
fun testAnnotations_openPdfsInPSPDFKitFromLinksInAssignment() {
// Annotation toolbar icon needs to be present, this link is specific to assignment details, as that was the advertised use case
val data = MockCanvas.init(
studentCount = 1,
courseCount = 1
)

val course = data.courses.values.first()
val student = data.students[0]
val token = data.tokenFor(student)!!
data.addAssignmentsToGroups(course)
tokenLogin(data.domain, token, student)
routeTo("courses/${course.id}/assignments", data.domain)

val fileId = data.newItemId()
val url = """https://mock-data.instructure.com/courses/${course.id}/files/${fileId}/download?"""

data.addFileToCourse(
courseId = course.id,
displayName = pdfFileName,
contentType = "application/pdf",
fileId = fileId,
url = url
)

val uniqueFileName = OpenMediaAsyncTaskLoader.makeFilenameUnique(pdfFileName, url, fileId.toString())

cacheFile(student.id.toString(), uniqueFileName)

val pdfUrlElementId = "testLinkElement"
val assignmentDescriptionHtml = """<a id="$pdfUrlElementId" href="$url">pdf baby!!!</a>"""

val assignment = data.addAssignment(courseId = course.id, submissionTypeList = listOf(Assignment.SubmissionType.ONLINE_UPLOAD), description = assignmentDescriptionHtml)

assignmentListPage.refreshAssignmentList()
assignmentListPage.clickAssignment(assignment)
assignmentDetailsPage.assertAssignmentDetails(assignment)

// Scroll to the description, as it will likely be offscreen for landscape tests
assignmentDetailsPage.scrollToAssignmentDescription()

// Click the url in the description to load the pdf
Web.onWebView(withId(R.id.contentWebView))
.withElement(DriverAtoms.findElement(Locator.ID, pdfUrlElementId))
.perform(DriverAtoms.webClick())
fileListPage.assertPdfPreviewDisplayed()
}

private fun getToCourse(): MockCanvas {
val data = MockCanvas.init(
Expand Down
5 changes: 0 additions & 5 deletions apps/student/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -155,11 +155,6 @@
android:foregroundServiceType="dataSync"
android:exported="false" />

<activity
android:name=".activity.CandroidPSPDFActivity"
android:theme="@style/PSPDFKitTheme"
android:windowSoftInputMode="adjustNothing" />

<activity android:name=".activity.PandaAvatarActivity"
android:label="@string/pandaAvatar"
android:theme="@style/CanvasMaterialTheme_Default"/>
Expand Down
Loading
Loading