Kyou/layout #4

Merged
r-ca merged 5 commits from kyou/layout into main 2024-01-11 07:19:44 +00:00
3 changed files with 110 additions and 91 deletions
Showing only changes of commit 9dda0adbed - Show all commits

View File

@ -17,6 +17,9 @@ import android.os.Vibrator;
import com.google.android.material.bottomnavigation.BottomNavigationView; import com.google.android.material.bottomnavigation.BottomNavigationView;
import java.util.Random;
import java.util.UUID;
public class MainActivity extends AppCompatActivity { public class MainActivity extends AppCompatActivity {
BluetoothManager bluetoothManager; BluetoothManager bluetoothManager;
@ -27,6 +30,7 @@ public class MainActivity extends AppCompatActivity {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main); setContentView(R.layout.activity_main);
//通知のやつ //通知のやつ
int importance = NotificationManager.IMPORTANCE_DEFAULT; int importance = NotificationManager.IMPORTANCE_DEFAULT;

View File

@ -16,7 +16,7 @@
android:name="com.example.childguard.HomeFragment" android:name="com.example.childguard.HomeFragment"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="0dp" android:layout_height="0dp"
app:layout_constraintBottom_toBottomOf="parent" app:layout_constraintBottom_toTopOf="@id/nav_view"
app:layout_constraintEnd_toEndOf="parent" app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" /> app:layout_constraintTop_toTopOf="parent" />

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools" xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/frameLayout" android:id="@+id/frameLayout"
@ -8,112 +8,127 @@
android:orientation="vertical" android:orientation="vertical"
tools:context=".HomeFragment"> tools:context=".HomeFragment">
<FrameLayout
android:id="@+id/situation_bg"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="20dp"
android:layout_marginTop="30dp"
android:layout_marginRight="20dp"
android:background="@drawable/frame_style">
<TextView <ScrollView
android:layout_width="0dp"
android:layout_height="0dp"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent">
<LinearLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="20dp" android:orientation="vertical" >
android:text="現在の状態" <FrameLayout
android:textAlignment="center" android:id="@+id/situation_bg"
android:textColor="@color/black" android:layout_width="match_parent"
android:textSize="25dp" /> android:layout_height="wrap_content"
android:layout_marginLeft="20dp"
android:layout_marginTop="30dp"
android:layout_marginRight="20dp"
android:background="@drawable/frame_style">
<TextView <TextView
android:id="@+id/situation" android:layout_width="match_parent"
android:layout_width="match_parent" android:layout_height="wrap_content"
android:layout_height="200dp" android:layout_marginTop="20dp"
android:layout_marginTop="10dp" android:text="現在の状態"
android:text="\n降車状態" android:textAlignment="center"
android:textAlignment="center" android:textColor="@color/black"
android:textColor="@color/black" android:textSize="25dp" />
android:textSize="55dp" />
</FrameLayout> <TextView
android:id="@+id/situation"
android:layout_width="match_parent"
android:layout_height="200dp"
android:layout_marginTop="10dp"
android:text="\n降車状態"
android:textAlignment="center"
android:textColor="@color/black"
android:textSize="55dp" />
<FrameLayout </FrameLayout>
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="20dp"
android:layout_marginTop="30dp"
android:layout_marginRight="20dp"
android:background="@drawable/frame_style">
<TextView <FrameLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="5dp" android:layout_marginLeft="20dp"
android:text="切断中" android:layout_marginTop="30dp"
android:textAlignment="center" android:layout_marginRight="20dp"
android:textColor="@color/black" android:background="@drawable/frame_style">
android:textSize="30dp" />
<ImageView <TextView
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="100dp" android:layout_height="wrap_content"
android:layout_marginTop="50dp" android:layout_marginTop="5dp"
android:src="@drawable/bluetooth_drive_fill0_wght400_grad0_opsz24" android:text="切断中"
android:textAlignment="center" /> android:textAlignment="center"
android:textColor="@color/black"
android:textSize="30dp" />
<ImageView <ImageView
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="100dp" android:layout_height="100dp"
android:layout_marginTop="50dp" android:layout_marginTop="50dp"
android:src="@drawable/close_fill0_wght400_grad0_opsz24" android:src="@drawable/bluetooth_drive_fill0_wght400_grad0_opsz24"
android:textAlignment="center" /> android:textAlignment="center" />
</FrameLayout> <ImageView
android:layout_width="match_parent"
android:layout_height="100dp"
android:layout_marginTop="50dp"
android:src="@drawable/close_fill0_wght400_grad0_opsz24"
android:textAlignment="center" />
<Button </FrameLayout>
android:id="@+id/QRprinting"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="70dp"
android:backgroundTint="#778899"
android:text="QRコード印刷"
android:textColor="@color/white"
android:textSize="40dp" />
<Button <Button
android:id="@+id/Bluetooth_setup" android:id="@+id/QRprinting"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:backgroundTint="#778899" android:layout_marginTop="70dp"
android:text="Bluetooth設定" android:backgroundTint="#778899"
android:textColor="@color/white" android:text="QRコード印刷"
android:textSize="40dp" /> android:textColor="@color/white"
android:textSize="40dp" />
<FrameLayout <Button
android:layout_width="match_parent" android:id="@+id/Bluetooth_setup"
android:layout_height="wrap_content" android:layout_width="match_parent"
android:layout_marginLeft="20dp" android:layout_height="wrap_content"
android:layout_marginRight="20dp" android:backgroundTint="#778899"
android:background="@drawable/frame_style_button"> android:text="Bluetooth設定"
android:textColor="@color/white"
android:textSize="40dp" />
<FrameLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginLeft="20dp"
android:layout_marginRight="20dp"
android:background="@drawable/frame_style_button">
</FrameLayout> </FrameLayout>
<FrameLayout <FrameLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginLeft="20dp" android:layout_marginLeft="20dp"
android:layout_marginRight="20dp" android:layout_marginRight="20dp"
android:background="@drawable/frame_style_button"> android:background="@drawable/frame_style_button">
<!--<ImageView <!--<ImageView
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:src="@drawable/ss"/>--> android:src="@drawable/ss"/>-->
<!--android:layout_gravity="center"--> <!--android:layout_gravity="center"-->
</FrameLayout> </FrameLayout>
</LinearLayout> </LinearLayout>
</ScrollView>
</androidx.constraintlayout.widget.ConstraintLayout>