Browse Source

Changed some stuff on the videolist layout

bk_master_copy
Bastian Kohler 11 months ago
parent
commit
2c9b2523a4

+ 1
- 10
app/src/main/java/com/example/ueberwachungssystem/Detection/DetectorService.java View File

@@ -30,11 +30,6 @@ public class DetectorService extends LifecycleService {
public WifiCommunication wifiCommunication;


// Recording logic
private boolean detectedVideo = false;
private boolean detectedAudio = false;
private boolean detectedMotion = false;

String wifiData;
StringBuffer stringBufferWifi = new StringBuffer();

@@ -75,13 +70,9 @@ public class DetectorService extends LifecycleService {
//passToServiceListener(detectionReport);

if(detectionReport.detectionState){
detectedVideo = true;
videoDetector.startRecording();
} else {
detectedVideo = false;
if(!(detectedVideo || detectedAudio || detectedMotion)) {
videoDetector.stopRecording();
}
videoDetector.stopRecording();
}

wifiCommunication.sendTrue(detectionReport.toMessage());

+ 12
- 9
app/src/main/res/layout/videolist_fragment.xml View File

@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
<androidx.appcompat.widget.LinearLayoutCompat xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
@@ -8,18 +8,21 @@
android:orientation="vertical"
android:background="@android:color/holo_blue_light">

<ListView
android:id = "@+id/listView"
android:layout_width = "wrap_content"
android:layout_height = "wrap_content"
tools:ignore="MissingConstraints" />

<Button
android:id="@+id/button"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Aufnahmen Löschen"
app:layout_constraintBottom_toBottomOf="parent"
android:backgroundTint="#010C49"
tools:ignore="MissingConstraints" />

</androidx.constraintlayout.widget.ConstraintLayout>
<ListView
android:id="@+id/listView"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
tools:ignore="MissingConstraints"
tools:layout_editor_absoluteX="0dp"
tools:layout_editor_absoluteY="0dp" />


</androidx.appcompat.widget.LinearLayoutCompat>

Loading…
Cancel
Save