SetUpActivityがエラーを起こしていたので、再度作り直しました

This commit is contained in:
Ekamo-11 2024-06-11 16:25:29 +09:00
parent 86e77532dc
commit afa4b678e0
4 changed files with 138 additions and 165 deletions

View File

@ -1,7 +1,6 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android" <manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools" >
xmlns:tools="http://schemas.android.com/tools">
<application <application
android:allowBackup="true" android:allowBackup="true"
@ -13,23 +12,20 @@
android:supportsRtl="true" android:supportsRtl="true"
android:theme="@style/Theme.Oplogy" android:theme="@style/Theme.Oplogy"
tools:ignore="ExtraText" tools:ignore="ExtraText"
tools:targetApi="31"> tools:targetApi="31" >
<activity
<!-- TODO: Before you run your application, you need a Google Maps API key.--> android:name=".SetUpActivity"
android:exported="false" />
<!-- To get one, follow the directions here:--> <!-- TODO: Before you run your application, you need a Google Maps API key. -->
<!-- To get one, follow the directions here: -->
<!-- https://developers.google.com/maps/documentation/android-sdk/get-api-key--> <!-- https://developers.google.com/maps/documentation/android-sdk/get-api-key -->
<!-- Once you have your API key (it starts with "AIza"), define a new property in your -->
<!-- Once you have your API key (it starts with "AIza"), define a new property in your--> <!-- project's local.properties file (e.g. MAPS_API_KEY=Aiza...), and replace the -->
<!-- project's local.properties file (e.g. MAPS_API_KEY=Aiza...), and replace the--> <!-- "YOUR_API_KEY" string in this file with "${MAPS_API_KEY}". -->
<!-- "YOUR_API_KEY" string in this file with "${MAPS_API_KEY}".-->
<meta-data <meta-data
android:name="com.google.android.geo.API_KEY" android:name="com.google.android.geo.API_KEY"
android:value="AIzaSyBQ1Ak-I2NL5TP4K59ZI0VgzKk6HNZuusw" /> android:value="AIzaSyBQ1Ak-I2NL5TP4K59ZI0VgzKk6HNZuusw" />
<activity <activity
android:name=".Maps" android:name=".Maps"
android:exported="false" android:exported="false"
@ -43,22 +39,16 @@
<activity <activity
android:name=".RootSearchActivity" android:name=".RootSearchActivity"
android:exported="false" /> android:exported="false" />
<activity
android:name=".SetupActivity"
android:exported="false" />
<activity <activity
android:name=".CreateUUID" android:name=".CreateUUID"
android:exported="false" /> android:exported="false" />
<activity <activity
android:name="com.example.oplogy.DialogFragment" android:name=".DialogFragment"
android:exported="false" /> android:exported="false" />
<activity <activity
android:name=".MainActivity" android:name=".MainActivity"
android:exported="true" android:exported="true"
tools:ignore="DuplicateActivity"> tools:ignore="DuplicateActivity" >
<intent-filter> <intent-filter>
<action android:name="android.intent.action.MAIN" /> <action android:name="android.intent.action.MAIN" />
@ -67,12 +57,4 @@
</activity> </activity>
</application> </application>
</manifest> </manifest>

View File

@ -87,7 +87,7 @@ public class MainActivity extends AppCompatActivity implements View.OnClickListe
// セットアップのクリック処理 // セットアップのクリック処理
if(view == setUp){ if(view == setUp){
imageSetup.setImageResource(R.drawable.ischecked_uuid); imageSetup.setImageResource(R.drawable.ischecked_uuid);
Intent toSetup = new Intent(MainActivity.this,SetupActivity.class); Intent toSetup = new Intent(MainActivity.this, SetUpActivity.class);
startActivity(toSetup); startActivity(toSetup);
} }

View File

@ -1,12 +1,12 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout 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" xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="match_parent" android:layout_height="match_parent"
tools:context=".SetUpActivity" tools:context=".SetUpActivity"
android:orientation="vertical" android:orientation="vertical"
android:gravity="center" android:gravity="center">
android:layout_margin="25dp">
<TextView <TextView
android:layout_width="wrap_content" android:layout_width="wrap_content"
@ -22,19 +22,19 @@
android:padding="10dp" android:padding="10dp"
android:gravity="center"> android:gravity="center">
<TextView <TextView
android:layout_width="90sp" android:layout_width="90sp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/teacherName" android:text="@string/teacherName"
android:gravity="center"/> android:gravity="center"/>
<EditText <EditText
android:id="@+id/teacherName" android:id="@+id/teacherName"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:autofillHints="" android:autofillHints=""
android:inputType="" android:inputType=""
tools:ignore="LabelFor" /> tools:ignore="LabelFor" />
</LinearLayout> </LinearLayout>
@ -45,20 +45,20 @@
android:padding="10dp" android:padding="10dp"
android:gravity="center"> android:gravity="center">
<TextView <TextView
android:layout_width="90sp" android:layout_width="90sp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/startPoint" android:text="@string/startPoint"
android:gravity="center"/> android:gravity="center"/>
<EditText <EditText
android:id="@+id/startPoint" android:id="@+id/startPoint"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:hint="住所" android:hint="住所"
android:autofillHints="" android:autofillHints=""
android:inputType="" android:inputType=""
tools:ignore="LabelFor" /> tools:ignore="LabelFor" />
</LinearLayout> </LinearLayout>
@ -69,19 +69,19 @@
android:padding="10dp" android:padding="10dp"
android:gravity="center"> android:gravity="center">
<TextView <TextView
android:layout_width="90sp" android:layout_width="90sp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/startTime" android:text="@string/startTime"
android:gravity="center"/> android:gravity="center"/>
<EditText <EditText
android:id="@+id/startTime" android:id="@+id/startTime"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:autofillHints="" android:autofillHints=""
android:inputType="" android:inputType=""
tools:ignore="LabelFor"/> tools:ignore="LabelFor"/>
</LinearLayout> </LinearLayout>
@ -92,19 +92,19 @@
android:padding="10dp" android:padding="10dp"
android:gravity="center"> android:gravity="center">
<TextView <TextView
android:layout_width="90sp" android:layout_width="90sp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/endTime" android:text="@string/endTime"
android:gravity="center"/> android:gravity="center"/>
<EditText <EditText
android:id="@+id/endTime" android:id="@+id/endTime"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:autofillHints="" android:autofillHints=""
android:inputType="" android:inputType=""
tools:ignore="LabelFor"/> tools:ignore="LabelFor"/>
</LinearLayout> </LinearLayout>
@ -115,46 +115,46 @@
android:padding="10dp" android:padding="10dp"
android:gravity="center"> android:gravity="center">
<TextView <TextView
android:layout_width="90sp" android:layout_width="90sp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/intervalTime" android:text="@string/intervalTime"
android:gravity="center"/> android:gravity="center"/>
<RadioGroup <RadioGroup
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:orientation="horizontal" android:orientation="horizontal"
android:weightSum="3"> android:weightSum="3">
<RadioButton <RadioButton
android:id="@+id/tenMinute" android:id="@+id/tenMinute"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
android:text="10分" android:text="10分"
android:paddingEnd="20dp" android:paddingEnd="20dp"
tools:ignore="RtlSymmetry" /> tools:ignore="RtlSymmetry" />
<RadioButton <RadioButton
android:id="@+id/fifteenMinute" android:id="@+id/fifteenMinute"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
android:text="15分" android:text="15分"
android:paddingEnd="20dp" android:paddingEnd="20dp"
tools:ignore="RtlSymmetry" /> tools:ignore="RtlSymmetry" />
<RadioButton <RadioButton
android:id="@+id/thirtyMinute" android:id="@+id/thirtyMinute"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_weight="1" android:layout_weight="1"
android:text="30分" android:text="30分"
android:paddingEnd="20dp" android:paddingEnd="20dp"
tools:ignore="RtlSymmetry" /> tools:ignore="RtlSymmetry" />
</RadioGroup> </RadioGroup>
</LinearLayout> </LinearLayout>
@ -165,20 +165,20 @@
android:padding="10dp" android:padding="10dp"
android:gravity="center"> android:gravity="center">
<TextView <TextView
android:layout_width="90sp" android:layout_width="90sp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/breakTime" android:text="@string/breakTime"
android:gravity="center"/> android:gravity="center"/>
<EditText <EditText
android:id="@+id/breakTime" android:id="@+id/breakTime"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:hint="例30分➝30 1時間半➝90" android:hint="例30分➝30 1時間半➝90"
android:autofillHints="" android:autofillHints=""
android:inputType="" android:inputType=""
tools:ignore="LabelFor"/> tools:ignore="LabelFor"/>
</LinearLayout> </LinearLayout>
@ -189,20 +189,20 @@
android:padding="10dp" android:padding="10dp"
android:gravity="center"> android:gravity="center">
<TextView <TextView
android:layout_width="90sp" android:layout_width="90sp"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/totalStudent" android:text="@string/totalStudent"
android:gravity="center"/> android:gravity="center"/>
<EditText <EditText
android:id="@+id/totalStudent" android:id="@+id/totalStudent"
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:hint="例30人➝30" android:hint="例30人➝30"
android:autofillHints="" android:autofillHints=""
android:inputType="" android:inputType=""
tools:ignore="LabelFor"/> tools:ignore="LabelFor"/>
</LinearLayout> </LinearLayout>
@ -213,18 +213,18 @@
android:weightSum="2" android:weightSum="2"
android:layout_marginTop="20sp"> android:layout_marginTop="20sp">
<Button <Button
android:id="@+id/resetButton" android:id="@+id/resetButton"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/reset" android:text="@string/reset"
android:layout_marginEnd="100dp"/> android:layout_marginEnd="100dp"/>
<Button <Button
android:id="@+id/setUpButton" android:id="@+id/setUpButton"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/setUp"/> android:text="@string/setUp"/>
</LinearLayout> </LinearLayout>

View File

@ -1,9 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout 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"
android:layout_height="match_parent"
tools:context=".SetupActivity">
</androidx.constraintlayout.widget.ConstraintLayout>