Added pager so we can swipe between fragments - only have two dummy fragments so far though - need to port the original mainActivity display components to separate fragments next.
This commit is contained in:
@@ -6,11 +6,16 @@
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".MainActivity2">
|
||||
|
||||
<androidx.fragment.app.FragmentContainerView
|
||||
<!--<androidx.fragment.app.FragmentContainerView
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/fragment_container_view"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
/>
|
||||
|
||||
-->
|
||||
<androidx.viewpager2.widget.ViewPager2
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:id="@+id/fragment_pager"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
@@ -34,7 +34,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="16dp"
|
||||
android:text="View Error Log"
|
||||
android:textColor="#212121"/>
|
||||
android:textColor="#212121"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/button_copy_error_log"
|
||||
@@ -42,7 +43,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="Copy Error Log"
|
||||
android:textColor="#212121"/>
|
||||
android:textColor="#212121"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/button_share_error_log"
|
||||
@@ -50,7 +52,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="Share Error Log"
|
||||
android:textColor="#212121"/>
|
||||
android:textColor="#212121"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/button_email_error_log"
|
||||
@@ -66,7 +69,8 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
android:text="Save Error Log"
|
||||
android:textColor="#212121"/>
|
||||
android:textColor="#212121"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<Button
|
||||
android:id="@+id/button_close_app"
|
||||
|
||||
28
app/src/main/res/layout/fragment_hr_alg.xml
Normal file
28
app/src/main/res/layout/fragment_hr_alg.xml
Normal file
@@ -0,0 +1,28 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<FrameLayout 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"
|
||||
tools:context=".FragmentSdDataViewer">
|
||||
|
||||
<!-- TODO: Update blank fragment layout -->
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="253dp"
|
||||
android:orientation="vertical">
|
||||
<!-- TODO: Update blank fragment layout -->
|
||||
<TextView
|
||||
android:id="@+id/fragment_hr_alg_tv1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Fragment_HrAlg" />
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="HR Algorithm Status" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
|
||||
|
||||
</FrameLayout>
|
||||
@@ -5,10 +5,55 @@
|
||||
android:layout_height="match_parent"
|
||||
tools:context=".FragmentSdDataViewer">
|
||||
|
||||
<!-- TODO: Update blank fragment layout -->
|
||||
<TextView
|
||||
<androidx.appcompat.widget.LinearLayoutCompat
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:text="Fragment_OsdAlg" />
|
||||
android:layout_height="253dp"
|
||||
android:orientation="vertical">
|
||||
<!-- TODO: Update blank fragment layout -->
|
||||
<TextView
|
||||
android:id="@+id/fragment_osdalg_tv1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Fragment_OsdAlg" />
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/fragment_osdalg_tv2"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="OSD Algorithm Status" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/powerTv"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="---" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/powerProgressBar"
|
||||
style="?android:attr/progressBarStyleHorizontal"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:minHeight="20dp" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/spectrumTv"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="---" />
|
||||
|
||||
<ProgressBar
|
||||
android:id="@+id/spectrumProgressBar"
|
||||
style="?android:attr/progressBarStyleHorizontal"
|
||||
android:layout_width="fill_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:indeterminate="false"
|
||||
android:minHeight="20dp" />
|
||||
|
||||
<com.github.mikephil.charting.charts.BarChart
|
||||
android:id="@+id/chart1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||
</FrameLayout>
|
||||
@@ -9,6 +9,9 @@
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:text="@string/hello_blank_fragment" />
|
||||
android:text="@string/hello_blank_fragment"
|
||||
android:id="@+id/fragment_sddata_viewer_tv1"/>
|
||||
|
||||
|
||||
|
||||
</FrameLayout>
|
||||
Reference in New Issue
Block a user