Skip to content

Commit 692db42

Browse files
author
Simon Kapl
committed
Made the changes requested by the iText team.
1 parent 38654ac commit 692db42

File tree

17 files changed

+25
-127
lines changed

17 files changed

+25
-127
lines changed

.idea/.name

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,9 @@ Therefore you need to clone 3 repositories in order to setup your build environm
2020
Run the following commands at a folder of your choice:
2121

2222
```
23-
git clone ssh://git@git.itextsupport.com:7999/i7a/itext7-android.git
24-
git clone ssh://git@git.itextsupport.com:7999/i7a/pdfiumandroid.git
25-
git clone ssh://git@git.itextsupport.com:7999/i7a/androidpdfviewer.git
23+
git clone ssh://git@github.com:itext/PdfiumAndroid.git
24+
git clone ssh://git@github.com:itext/AndroidPdfViewer.git
25+
git clone ssh://git@github.com:itext/itext7-android-ui.git
2626
```
2727

2828
This will generate the following folder structure on your machine:
@@ -43,7 +43,7 @@ If you want to use a different folder structure, make sure to update your settin
4343
Do not use spaces in your local paths/directories, as it can lead to all sorts of errors related to Android NDK, ndk-build or cmake.
4444

4545
### NDK setup
46-
If you are having problems related to Android NKD, make sure to follow the correct setup procedure:
46+
If you are having problems related to Android NDK, make sure to follow the correct setup procedure:
4747
https://developer.android.com/studio/projects/install-ndk
4848

4949

app/build.gradle

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ android {
2424
// "pm clear" command after each test invocation. This command ensures
2525
// that the app's state is completely cleared between tests.
2626
testInstrumentationRunnerArguments clearPackageData: 'true'
27-
2827
}
2928

3029
buildFeatures {
@@ -34,7 +33,6 @@ android {
3433
buildTypes {
3534
release {
3635
minifyEnabled false
37-
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
3836
}
3937
debug {
4038
testCoverageEnabled = true
@@ -75,7 +73,7 @@ dependencies {
7573
androidTestImplementation "androidx.test.ext:truth:1.4.0"
7674

7775
// Espresso
78-
def espresso_version = "3.5.0-alpha04"
76+
def espresso_version = "3.5.0-alpha05"
7977
androidTestImplementation "androidx.test.espresso:espresso-core:$espresso_version"
8078
androidTestImplementation "androidx.test.espresso:espresso-contrib:$espresso_version"
8179

app/proguard-rules.pro

Lines changed: 0 additions & 21 deletions
This file was deleted.

app/src/androidTest/java/com/itextpdf/android/app/ExampleInstrumentedTest.kt

Lines changed: 0 additions & 24 deletions
This file was deleted.

app/src/main/AndroidManifest.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
android:label="@string/app_name"
99
android:roundIcon="@mipmap/ic_launcher_round"
1010
android:supportsRtl="true"
11-
android:theme="@style/Theme.iTextPdfDemo"
11+
android:theme="@style/Theme.iText7AndroidUiDemo"
1212
android:fullBackupContent="true">
1313
<provider
1414
android:name="androidx.core.content.FileProvider"

app/src/main/res/values-night/themes.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<resources xmlns:tools="http://schemas.android.com/tools">
22
<!-- Base application theme. -->
3-
<style name="Theme.iTextPdfDemo" parent="Theme.MaterialComponents.DayNight.DarkActionBar">
3+
<style name="Theme.iText7AndroidUiDemo" parent="Theme.MaterialComponents.DayNight.DarkActionBar">
44
<!-- Primary brand color. -->
55
<item name="colorPrimary">@color/orange_200</item>
66
<item name="colorPrimaryVariant">@color/orange_700</item>

app/src/main/res/values/themes.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<resources xmlns:tools="http://schemas.android.com/tools">
22
<!-- Base application theme. -->
3-
<style name="Theme.iTextPdfDemo" parent="Theme.MaterialComponents.DayNight.NoActionBar">
3+
<style name="Theme.iText7AndroidUiDemo" parent="Theme.MaterialComponents.DayNight.NoActionBar">
44
<!-- Primary brand color. -->
55
<item name="colorPrimary">@color/orange_500</item>
66
<item name="colorPrimaryVariant">@color/orange_700</item>

app/src/test/java/com/itextpdf/android/app/ExampleUnitTest.kt

Lines changed: 0 additions & 17 deletions
This file was deleted.

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ buildscript {
88
jcenter()
99
}
1010
dependencies {
11-
classpath 'com.android.tools.build:gradle:7.1.2'
11+
classpath 'com.android.tools.build:gradle:7.1.3'
1212
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
1313

1414
// Required by AndroidPdfViewer
@@ -24,7 +24,7 @@ allprojects {
2424
mavenCentral()
2525

2626
maven {
27-
url "https://repo.itextsupport.com/snapshot"
27+
url "https://repo.itextsupport.com/releases"
2828
}
2929
}
3030
}

library/build.gradle

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@ android {
2323
// "pm clear" command after each test invocation. This command ensures
2424
// that the app's state is completely cleared between tests.
2525
testInstrumentationRunnerArguments = ['clearPackageData': 'true', 'useTestStorageService': 'true']
26-
27-
consumerProguardFiles "consumer-rules.pro"
2826
}
2927

3028
sourceSets {
@@ -47,7 +45,6 @@ android {
4745
buildTypes {
4846
release {
4947
minifyEnabled false
50-
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
5148
}
5249
debug {
5350
testCoverageEnabled = true
@@ -68,7 +65,7 @@ android {
6865

6966
// Enable/Disable android-x test-orchestrator
7067
// The orchestrator is used to ensure empty/clean app-data for each instrumented-test
71-
// execution 'ANDROIDX_TEST_ORCHESTRATOR'
68+
execution 'ANDROIDX_TEST_ORCHESTRATOR'
7269

7370
animationsDisabled = true
7471

@@ -80,12 +77,10 @@ android {
8077

8178
dependencies {
8279
// PDF
83-
// https://mvnrepository.com/artifact/com.itextpdf/kernel
84-
api("com.itextpdf:kernel:7.2.2-SNAPSHOT")
85-
// https://mvnrepository.com/artifact/com.itextpdf/layout
86-
api("com.itextpdf:layout:7.2.2-SNAPSHOT")
87-
api("com.itextpdf:io:7.2.2-SNAPSHOT")
88-
api("com.itextpdf:forms:7.2.2-SNAPSHOT")
80+
api("com.itextpdf:kernel:7.2.2")
81+
api("com.itextpdf:layout:7.2.2")
82+
api("com.itextpdf:io:7.2.2")
83+
api("com.itextpdf:forms:7.2.2")
8984

9085
implementation project(path: ':android-pdf-viewer')
9186

@@ -99,7 +94,7 @@ dependencies {
9994
implementation 'com.google.android.material:material:1.5.0'
10095
androidTestImplementation 'com.google.android.material:material:1.5.0'
10196

102-
implementation 'androidx.compose.material3:material3:1.0.0-alpha08'
97+
implementation 'androidx.compose.material3:material3:1.0.0-alpha09'
10398

10499
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.6.0'
105100
implementation('org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.0')

library/consumer-rules.pro

Whitespace-only changes.

library/proguard-rules.pro

Lines changed: 0 additions & 21 deletions
This file was deleted.

library/src/main/java/com/itextpdf/android/library/PdfActivity.kt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,4 @@ internal class PdfActivity : AppCompatActivity() {
1818
private fun copyFileFromAssets() {
1919
fileUtil.loadFileFromAssets(this, "sample_1.pdf")
2020
}
21-
22-
2321
}

library/src/main/java/com/itextpdf/android/library/SplitPdfActivity.kt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,22 @@ package com.itextpdf.android.library
33
import android.os.Bundle
44
import androidx.appcompat.app.AppCompatActivity
55
import com.itextpdf.android.library.fragments.SplitDocumentFragment
6+
import com.itextpdf.android.library.util.FileUtil
67

78
/**
89
* This class is only used during UI testing regarding XML inflation of [SplitDocumentFragment].
910
*/
1011
internal class SplitPdfActivity : AppCompatActivity() {
1112

13+
private val fileUtil = FileUtil.getInstance()
14+
1215
override fun onCreate(savedInstanceState: Bundle?) {
16+
copyFileFromAssets()
1317
super.onCreate(savedInstanceState)
1418
setContentView(R.layout.activity_split_pdf)
1519
}
1620

21+
private fun copyFileFromAssets() {
22+
fileUtil.loadFileFromAssets(this, "sample_1.pdf")
23+
}
1724
}

library/src/test/java/com/itextpdf/android/library/ExampleUnitTest.kt

Lines changed: 0 additions & 17 deletions
This file was deleted.

settings.gradle

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
rootProject.name = "iTextPDF"
1+
rootProject.name = "itext7-android-ui"
22
include ':app'
33
include ':library'
44
include ':android-pdf-viewer'

0 commit comments

Comments
 (0)