Compare commits
12 Commits
6f78836c4d
...
061646a7d6
Author | SHA1 | Date | |
---|---|---|---|
061646a7d6 | |||
746eec18ba | |||
44e056b5fe | |||
df1fefef5f | |||
5bcd465ecc | |||
a6fdf3f774 | |||
b46db4cdfc | |||
74eb3e0d98 | |||
5f7e2a43f2 | |||
07f60f974b | |||
57bf2c2fb7 | |||
5c0263198c |
@ -0,0 +1,48 @@
|
||||
package com.example.ueberwachungssystem.Fragments;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import com.example.ueberwachungssystem.R;
|
||||
|
||||
public class Fragment1 extends Fragment {
|
||||
private String text;
|
||||
private final static String KEY_TEXT = "KEY_TEXT";
|
||||
|
||||
private void log(String nachricht) {
|
||||
Log.d(this.getClass().getSimpleName(), nachricht);
|
||||
}
|
||||
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle bundle) {
|
||||
log("onCreateView");
|
||||
View view = inflater.inflate(R.layout.fragment1, container, false);
|
||||
TextView Sensor = (TextView) view.findViewById(R.id.Sensor);
|
||||
Sensor.setText(text);
|
||||
return view;
|
||||
}
|
||||
public static Fragment1 erstellen(String text) {
|
||||
Fragment1 fragment = new Fragment1();
|
||||
Bundle b = new Bundle();
|
||||
b.putString(KEY_TEXT, text);
|
||||
fragment.setArguments(b);
|
||||
return fragment;
|
||||
}
|
||||
@Override
|
||||
public void onCreate(Bundle bundle) {
|
||||
super .onCreate(bundle);
|
||||
Bundle args = getArguments();
|
||||
if (args != null ) {
|
||||
text = args.getString(KEY_TEXT);
|
||||
log("onCreate: text=" + text);
|
||||
} else {
|
||||
log("onCreate");
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.example.ueberwachungssystem.Fragments;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import com.example.ueberwachungssystem.R;
|
||||
|
||||
public class Fragment2 extends Fragment {
|
||||
private String text;
|
||||
private final static String KEY_TEXT = "KEY_TEXT" ;
|
||||
private void log(String nachricht) {
|
||||
Log.d(this.getClass().getSimpleName(), nachricht);
|
||||
}
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle bundle) {
|
||||
log( "onCreateView" );
|
||||
View view = inflater.inflate(R.layout.fragment2, container, false );
|
||||
TextView Sensor = (TextView) view.findViewById(R.id.Sensor);
|
||||
Sensor.setText(text);
|
||||
return view;
|
||||
}
|
||||
public static Fragment2 erstellen(String text) {
|
||||
Fragment2 fragment = new Fragment2();
|
||||
Bundle b = new Bundle();
|
||||
b.putString(KEY_TEXT, text);
|
||||
fragment.setArguments(b);
|
||||
return fragment;
|
||||
}
|
||||
@Override
|
||||
public void onCreate(Bundle bundle) {
|
||||
super.onCreate(bundle);
|
||||
Bundle args = getArguments();
|
||||
if (args != null) {
|
||||
text = args.getString(KEY_TEXT);
|
||||
log("onCreate: text=" + text);
|
||||
} else {
|
||||
log("onCreate");
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package com.example.ueberwachungssystem.Fragments;
|
||||
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.TextView;
|
||||
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import com.example.ueberwachungssystem.R;
|
||||
|
||||
public class Fragment3 extends Fragment {
|
||||
private String text;
|
||||
private final static String KEY_TEXT = "KEY_TEXT" ;
|
||||
private void log(String nachricht) {
|
||||
Log.d(this.getClass().getSimpleName(), nachricht);
|
||||
}
|
||||
@Override
|
||||
public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle bundle) {
|
||||
log( "onCreateView" );
|
||||
View view = inflater.inflate(R.layout.fragment2, container, false );
|
||||
TextView Sensor = (TextView) view.findViewById(R.id.Sensor);
|
||||
Sensor.setText(text);
|
||||
return view;
|
||||
}
|
||||
public static Fragment3 erstellen(String text) {
|
||||
Fragment3 fragment = new Fragment3();
|
||||
Bundle b = new Bundle();
|
||||
b.putString(KEY_TEXT, text);
|
||||
fragment.setArguments(b);
|
||||
return fragment;
|
||||
}
|
||||
@Override
|
||||
public void onCreate(Bundle bundle) {
|
||||
super.onCreate(bundle);
|
||||
Bundle args = getArguments();
|
||||
if (args != null) {
|
||||
text = args.getString(KEY_TEXT);
|
||||
log("onCreate: text=" + text);
|
||||
} else {
|
||||
log("onCreate");
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,44 @@
|
||||
package com.example.ueberwachungssystem.Logger;
|
||||
|
||||
import android.util.Log;
|
||||
import android.widget.TextView;
|
||||
|
||||
import java.io.PrintWriter;
|
||||
import java.io.StringWriter;
|
||||
|
||||
public class Logger {
|
||||
private TextView textView;
|
||||
private StringBuffer sb = new StringBuffer();
|
||||
private String tag;
|
||||
|
||||
public Logger(String tag, TextView textView, String logInitText) {
|
||||
this.tag = tag;
|
||||
this.textView = textView;
|
||||
sb.append(logInitText);
|
||||
}
|
||||
|
||||
public void log(String s) {
|
||||
Log.d(tag, s);
|
||||
sb.append(s).append("\n");
|
||||
if (textView != null) {
|
||||
textView.setText(sb.toString());
|
||||
}
|
||||
}
|
||||
|
||||
public void log(Exception e) {
|
||||
StringWriter sw = new StringWriter();
|
||||
e.printStackTrace(new PrintWriter(sw));
|
||||
log(sw.toString());
|
||||
}
|
||||
|
||||
public void clearLog() {
|
||||
sb.setLength(0);
|
||||
if (textView != null) {
|
||||
textView.setText("");
|
||||
}
|
||||
}
|
||||
|
||||
public String getLoggedText() {
|
||||
return sb.toString();
|
||||
}
|
||||
}
|
@ -1,113 +1,126 @@
|
||||
package com.example.ueberwachungssystem;
|
||||
|
||||
import static android.content.ContentValues.TAG;
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.camera.core.ExperimentalGetImage;
|
||||
import androidx.fragment.app.Fragment;
|
||||
import androidx.fragment.app.FragmentTransaction;
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.net.wifi.WifiInfo;
|
||||
import android.net.wifi.WifiManager;
|
||||
import android.net.wifi.WifiInfo;
|
||||
import android.net.wifi.WifiManager;
|
||||
import android.os.Bundle;
|
||||
import android.util.Log;
|
||||
import android.view.MenuItem;
|
||||
import android.widget.Toast;
|
||||
import android.view.Menu;
|
||||
import android.view.MenuItem;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
import android.widget.ScrollView;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
import android.widget.ToggleButton;
|
||||
|
||||
import androidx.appcompat.app.AppCompatActivity;
|
||||
import java.net.InetAddress;
|
||||
import java.net.UnknownHostException;
|
||||
import java.nio.ByteBuffer;
|
||||
import java.nio.ByteOrder;
|
||||
import com.example.ueberwachungssystem.Detection.DetectionReport;
|
||||
import com.example.ueberwachungssystem.Detection.Detector;
|
||||
import com.example.ueberwachungssystem.Detection.VideoDetector;
|
||||
import com.example.ueberwachungssystem.Fragments.Fragment1;
|
||||
import com.example.ueberwachungssystem.Fragments.Fragment2;
|
||||
import com.example.ueberwachungssystem.Fragments.Fragment3;
|
||||
|
||||
@SuppressLint("SetTextI18n")
|
||||
public class MainActivity extends AppCompatActivity {
|
||||
import org.w3c.dom.Text;
|
||||
|
||||
@ExperimentalGetImage
|
||||
public class MainActivity extends AppCompatActivity implements View.OnClickListener {
|
||||
private Fragment aktuellesFragment;
|
||||
private Fragment1 fragment1;
|
||||
private Fragment2 fragment2;
|
||||
private Fragment3 fragment3;
|
||||
|
||||
WifiCommunication communication;
|
||||
PermissionRequest permission;
|
||||
boolean communicationRunning = true;
|
||||
String dataRecieved;
|
||||
TextView textview1;
|
||||
private TextView alarm;
|
||||
private String text = "Das ist ein Alarm des Sensors";
|
||||
//Buttons
|
||||
private ToggleButton toggleKamera;
|
||||
private ToggleButton btnAudio;
|
||||
private ToggleButton btnBewegung;
|
||||
//Detektoren
|
||||
VideoDetector vd = new VideoDetector(this);
|
||||
private void log(String nachricht) {
|
||||
Log.d(this.getClass().getSimpleName(), nachricht);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setContentView(R.layout.activity_main);
|
||||
textview1 = findViewById(R.id.textView1);
|
||||
|
||||
Button button1 = findViewById(R.id.buttonSend);
|
||||
button1.setOnClickListener(new View.OnClickListener() {
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
communication.sendTrue("Testmessage");
|
||||
}
|
||||
});
|
||||
}
|
||||
@Override
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
if (communicationRunning){
|
||||
communication = new WifiCommunication(1234);
|
||||
communication.setOnConnectionListener(new WifiCommunication.OnConnectionListener() {
|
||||
@Override
|
||||
public void onConnection(StringBuffer data) {
|
||||
//Log.d("Test", data.toString());
|
||||
runOnUiThread(new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
textview1.setText(data);
|
||||
}
|
||||
});
|
||||
}
|
||||
});
|
||||
communicationRunning = false;
|
||||
}
|
||||
permission = new PermissionRequest(MainActivity.this);
|
||||
permission.rechtePruefen();
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
setTitle(this.getClass().getSimpleName());
|
||||
setContentView(R.layout.activity_main);
|
||||
alarm = findViewById(R.id.Alarm);
|
||||
alarm.setText(text);
|
||||
toggleKamera = findViewById(R.id.toggleKamera);
|
||||
toggleKamera.setOnClickListener(this);
|
||||
vd.setOnDetectionListener(new Detector.OnDetectionListener() {
|
||||
@Override
|
||||
public void onDetection(@NonNull DetectionReport detectionReport) {
|
||||
DetectionReport dr = detectionReport;
|
||||
String drString = dr.toString();
|
||||
}
|
||||
});
|
||||
|
||||
//boolean isRunning = vd.isRunning();
|
||||
|
||||
}
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
if (v == toggleKamera) {
|
||||
if (toggleKamera.isChecked()) {
|
||||
vd.startDetection();
|
||||
} else {
|
||||
vd.stopDetection();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onPause() {
|
||||
super.onPause();
|
||||
//communication.stopCommunication();
|
||||
communication.stopCommunication();
|
||||
}
|
||||
public boolean onCreateOptionsMenu(Menu menu) {
|
||||
getMenuInflater().inflate(R.menu.options_menu, menu);
|
||||
return true;
|
||||
|
||||
@Override
|
||||
protected void onResume() {
|
||||
super.onResume();
|
||||
communication = new WifiCommunication(MainActivity.this, 1234);
|
||||
}
|
||||
public boolean onOptionsItemSelected(MenuItem item) {
|
||||
Toast.makeText(this, "Selected Item: " + item.getTitle(), Toast.LENGTH_SHORT).show();
|
||||
PopUpClass popUpClass;
|
||||
switch (item.getItemId()) {
|
||||
case R.id.Rechteverwaltung:
|
||||
popUpClass = new PopUpClass(MainActivity.this);
|
||||
//popUpClass.showPopupWindow(tvMessages);
|
||||
popUpClass.RechtePrüfen();
|
||||
return true;
|
||||
case R.id.Sensoren:
|
||||
popUpClass = new PopUpClass(MainActivity.this);
|
||||
//popUpClass.showPopupWindow(tvMessages);
|
||||
popUpClass.Sensoren();
|
||||
return true;
|
||||
case R.id.Impressum:
|
||||
popUpClass = new PopUpClass(MainActivity.this);
|
||||
//popUpClass.showPopupWindow(tvMessages);
|
||||
popUpClass.Impressum();
|
||||
return true;
|
||||
default:
|
||||
return super.onOptionsItemSelected(item);
|
||||
|
||||
public void onClickZeigeFragment1(View view) {
|
||||
Button button = (Button) view;
|
||||
log(button.getText() + " ausgewählt");
|
||||
zeigeFragment(fragment1.erstellen("Fragment 1 wurde angeklickt"));
|
||||
}
|
||||
public void onClickZeigeFragment2(View view) {
|
||||
Button button = (Button) view;
|
||||
log(button.getText() + " ausgewählt");
|
||||
zeigeFragment(fragment2.erstellen("Fragment 2 wurde angeklickt"));
|
||||
}
|
||||
|
||||
public void onClickZeigeFragment3(View view) {
|
||||
Button button = (Button) view;
|
||||
log(button.getText() + " ausgewählt");
|
||||
zeigeFragment(fragment3.erstellen("Fragment 3 wurde angeklickt"));
|
||||
}
|
||||
|
||||
public void onClickEntferneFragment(View view) {
|
||||
entferneFragment();
|
||||
}
|
||||
private void zeigeFragment(Fragment fragment) {
|
||||
FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
|
||||
ft.replace(R.id.frame, fragment);
|
||||
ft.commit();
|
||||
aktuellesFragment = fragment;
|
||||
}
|
||||
private void entferneFragment() {
|
||||
if (aktuellesFragment != null) {
|
||||
FragmentTransaction ft = getSupportFragmentManager().beginTransaction();
|
||||
ft.remove(aktuellesFragment);
|
||||
ft.commit();
|
||||
aktuellesFragment = null ;
|
||||
}
|
||||
}
|
||||
private String getLocalIpAddress() throws UnknownHostException {
|
||||
WifiManager wifiManager = (WifiManager) getApplicationContext().getSystemService(WIFI_SERVICE);
|
||||
assert wifiManager != null;
|
||||
WifiInfo wifiInfo = wifiManager.getConnectionInfo();
|
||||
int ipInt = wifiInfo.getIpAddress();
|
||||
return InetAddress.getByAddress(ByteBuffer.allocate(4).order(ByteOrder.LITTLE_ENDIAN).putInt(ipInt).array()).getHostAddress();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
6
app/src/main/res/layout-land/activity_main_land.xml
Normal file
6
app/src/main/res/layout-land/activity_main_land.xml
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
|
||||
</LinearLayout>
|
@ -1,53 +1,123 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_gravity="center"
|
||||
android:gravity="top"
|
||||
android:orientation="vertical"
|
||||
tools:context=".MainActivity">
|
||||
|
||||
|
||||
<androidx.camera.view.PreviewView
|
||||
android:id="@+id/previewView"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:backgroundTint="@android:color/black"/>
|
||||
android:background="@android:color/holo_green_dark"
|
||||
android:visibility="visible"
|
||||
tools:context="com.example.ueberwachungssystem.MainActivity"
|
||||
tools:visibility="visible">
|
||||
|
||||
<ToggleButton
|
||||
android:id="@+id/toggleButton"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="ToggleButton" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/inputImageView"
|
||||
android:id="@+id/toggleKamera"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:srcCompat="@tools:sample/avatars" />
|
||||
android:layout_alignBottom="@id/toggleAudio"
|
||||
android:layout_marginRight="15dp"
|
||||
android:layout_toStartOf="@+id/toggleAudio"
|
||||
android:layout_toLeftOf="@id/toggleAudio"
|
||||
android:text="Kamera" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/outputImageView"
|
||||
<ToggleButton
|
||||
android:id="@+id/toggleAudio"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:srcCompat="@tools:sample/avatars" />
|
||||
android:layout_alignParentTop="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:text="Audio" />
|
||||
|
||||
<androidx.camera.view.PreviewView
|
||||
<ToggleButton
|
||||
android:id="@+id/toggleBewegung"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="TextView" />
|
||||
android:layout_alignBottom="@id/toggleAudio"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_toEndOf="@+id/toggleAudio"
|
||||
android:layout_toRightOf="@id/toggleAudio"
|
||||
android:text="Bewegung" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/buttonSend"
|
||||
android:layout_width="match_parent"
|
||||
android:id="@+id/btnAudio"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Button" />
|
||||
android:layout_alignBottom="@id/btnKamera"
|
||||
android:layout_marginRight="15dp"
|
||||
android:layout_toStartOf="@+id/btnKamera"
|
||||
android:onClick="onClickZeigeFragment1"
|
||||
android:text="Audio" />
|
||||
|
||||
</LinearLayout>
|
||||
<Button
|
||||
android:id="@+id/btnKamera"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/toggleAudio"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:onClick="onClickZeigeFragment2"
|
||||
android:text="Kamera" />
|
||||
|
||||
<!--
|
||||
<Button
|
||||
android:id="@+id/btnSensorWeg"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_below="@+id/btn1"
|
||||
android:text="Entferne Sensordarstellung"
|
||||
android:onClick="onClickEntferneFragment"/>
|
||||
-->
|
||||
<Button
|
||||
android:id="@+id/btnBewegung"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignBottom="@id/btnKamera"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:layout_toEndOf="@+id/btnKamera"
|
||||
android:layout_toRightOf="@id/btnKamera"
|
||||
android:onClick="onClickZeigeFragment3"
|
||||
android:text="Bewegung" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnAufnahme"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/btnKamera"
|
||||
android:layout_toLeftOf="@id/btnKamera"
|
||||
android:layout_marginRight="15dp"
|
||||
android:onClick="onClickEntferneFragment"
|
||||
android:text="Aufnahme" />
|
||||
|
||||
<Button
|
||||
android:id="@+id/btnWiedergabe"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@+id/btnKamera"
|
||||
android:layout_toRightOf="@id/btnKamera"
|
||||
android:layout_marginLeft="15dp"
|
||||
android:onClick="onClickEntferneFragment"
|
||||
android:text="Wiedergabe" />
|
||||
|
||||
<FrameLayout
|
||||
android:id="@+id/frame"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="200dp"
|
||||
android:layout_below="@+id/btnAufnahme"
|
||||
android:layout_alignParentStart="true">
|
||||
</FrameLayout>
|
||||
|
||||
<ScrollView
|
||||
android:id= "@+id/scrollView1"
|
||||
android:layout_width= "wrap_content"
|
||||
android:layout_height= "wrap_content"
|
||||
android:layout_below= "@id/frame">
|
||||
<LinearLayout
|
||||
android:layout_width= "match_parent"
|
||||
android:layout_height= "match_parent"
|
||||
android:orientation= "vertical" >
|
||||
<TextView
|
||||
android:id= "@+id/Alarm"
|
||||
android:layout_width= "wrap_content"
|
||||
android:layout_height= "wrap_content" />
|
||||
</LinearLayout>
|
||||
</ScrollView>
|
||||
|
||||
</RelativeLayout>
|
22
app/src/main/res/layout/fragment1.xml
Normal file
22
app/src/main/res/layout/fragment1.xml
Normal file
@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
android:background="@android:color/holo_green_light">
|
||||
|
||||
<TextView
|
||||
android:id="@+id/Sensor"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textAppearance="?android:attr/textAppearanceLarge"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/Alarm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/Sensor"
|
||||
android:textAppearance="?android:attr/textAppearanceLarge"/>
|
||||
|
||||
</RelativeLayout>
|
22
app/src/main/res/layout/fragment2.xml
Normal file
22
app/src/main/res/layout/fragment2.xml
Normal file
@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
android:background="@android:color/holo_blue_light" >
|
||||
|
||||
<TextView
|
||||
android:id="@+id/Sensor"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textAppearance="?android:attr/textAppearanceLarge"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/Alarm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/Sensor"
|
||||
android:textAppearance="?android:attr/textAppearanceLarge"/>
|
||||
|
||||
</LinearLayout>
|
22
app/src/main/res/layout/fragment3.xml
Normal file
22
app/src/main/res/layout/fragment3.xml
Normal file
@ -0,0 +1,22 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:gravity="center_horizontal"
|
||||
android:orientation="vertical"
|
||||
android:background="@android:color/holo_blue_light" >
|
||||
|
||||
<TextView
|
||||
android:id="@+id/Sensor"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textAppearance="?android:attr/textAppearanceLarge"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/Alarm"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_below="@id/Sensor"
|
||||
android:textAppearance="?android:attr/textAppearanceLarge"/>
|
||||
|
||||
</LinearLayout>
|
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,4 +1,4 @@
|
||||
#Thu May 11 15:04:30 CEST 2023
|
||||
#Thu May 11 15:19:24 CEST 2023
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.0-bin.zip
|
||||
distributionPath=wrapper/dists
|
||||
|
Loading…
x
Reference in New Issue
Block a user