diff --git a/app/build.gradle b/app/build.gradle
index 9e28bf8..586b387 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -11,7 +11,6 @@ android {
targetSdk 30
versionCode 1
versionName "1.0"
- useLibrary 'org.apache.http.legacy'
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
@@ -41,4 +40,5 @@ dependencies {
testImplementation 'junit:junit:4.+'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.4.0'
+ implementation 'org.apache.commons:commons-lang3:3.12.0'
}
\ No newline at end of file
diff --git a/app/src/androidTest/java/de/server47/rcsexport/ExampleInstrumentedTest.java b/app/src/androidTest/java/de/server47/messageexport/ExampleInstrumentedTest.java
similarity index 95%
rename from app/src/androidTest/java/de/server47/rcsexport/ExampleInstrumentedTest.java
rename to app/src/androidTest/java/de/server47/messageexport/ExampleInstrumentedTest.java
index 16635c0..8be77d8 100644
--- a/app/src/androidTest/java/de/server47/rcsexport/ExampleInstrumentedTest.java
+++ b/app/src/androidTest/java/de/server47/messageexport/ExampleInstrumentedTest.java
@@ -1,4 +1,4 @@
-package de.server47.rcsexport;
+package de.server47.messageexport;
import android.content.Context;
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index ea6f366..06047a3 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -1,6 +1,6 @@
+ package="de.server47.messageexport">
@@ -14,13 +14,13 @@
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
- android:theme="@style/Theme.SmsExport">
+ android:theme="@style/Theme.RcsExport">
+ android:theme="@style/Theme.RcsExport.NoActionBar">
@@ -28,9 +28,6 @@
-
-
-
\ No newline at end of file
diff --git a/app/src/main/java/de/server47/rcsexport/MainActivity.java b/app/src/main/java/de/server47/messageexport/MainActivity.java
similarity index 62%
rename from app/src/main/java/de/server47/rcsexport/MainActivity.java
rename to app/src/main/java/de/server47/messageexport/MainActivity.java
index 0cb3b65..1a8551b 100644
--- a/app/src/main/java/de/server47/rcsexport/MainActivity.java
+++ b/app/src/main/java/de/server47/messageexport/MainActivity.java
@@ -1,4 +1,4 @@
-package de.server47.rcsexport;
+package de.server47.messageexport;
import android.app.Activity;
import android.content.Intent;
@@ -8,11 +8,15 @@ import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
+import android.widget.RadioButton;
import android.widget.Toast;
import androidx.annotation.Nullable;
import androidx.documentfile.provider.DocumentFile;
+import org.apache.commons.lang3.StringEscapeUtils;
+import org.apache.commons.lang3.StringUtils;
+
import java.io.IOException;
import java.io.OutputStream;
import java.text.SimpleDateFormat;
@@ -24,81 +28,27 @@ import java.util.Map;
public class MainActivity extends Activity
{
- Button bRead, bWrite;
+ Button bExport;
+ RadioButton rbRcs, rbSms, rbMms;
final static int typeSMS = 0;
final static int typeMMS = 1;
- final static int typeICS = 2;
+ final static int typeRCS = 2;
final static int requestCodeExport = 815;
- String contentToWrite = "bla";
-
@Override
protected void onCreate(@Nullable Bundle savedInstanceState)
{
super.onCreate(savedInstanceState);
setContentView(R.layout.main_activity);
- bRead = (Button)findViewById(R.id.bRead);
- bWrite = (Button)findViewById(R.id.bWrite);
+ bExport = (Button)findViewById(R.id.bExport);
+ rbRcs = (RadioButton)findViewById(R.id.rbRcs);
+ rbSms = (RadioButton)findViewById(R.id.rbSms);
+ rbMms = (RadioButton)findViewById(R.id.rbMms);
- bRead.setOnClickListener(new View.OnClickListener()
- {
- @Override
- public void onClick(View v)
- {
- List