Skip to content

Commit 4e1cd4b

Browse files
committed
Merge remote-tracking branch 'origin/main'
2 parents 2ac8ecd + 128a6d3 commit 4e1cd4b

4 files changed

Lines changed: 10 additions & 9 deletions

File tree

PennMobile/src/main/AndroidManifest.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121

2222
<application
2323
android:name="androidx.multidex.MultiDexApplication"
24+
android:label="@string/app_name"
2425
android:allowBackup="true"
2526
android:hardwareAccelerated="true"
2627
android:icon="@mipmap/ic_launcher"

PennMobile/src/main/java/com/pennapps/labs/pennmobile/dining/adapters/DiningInsightsCardAdapter.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ class DiningInsightsCardAdapter(
5252
private const val DINING_DOLLARS_PREDICTIONS = 2
5353
private const val DINING_SWIPES_PREDICTIONS = 3
5454

55-
const val START_DAY_OF_SEMESTER = "2024-08-27"
55+
const val START_DAY_OF_SEMESTER = "2025-01-15"
5656
private const val DAYS_IN_SEMESTER = 117f
5757
}
5858

PennMobile/src/main/java/com/pennapps/labs/pennmobile/laundry/adapters/LaundrySettingsAdapter.kt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ import android.view.View
66
import android.view.ViewGroup
77
import android.widget.BaseExpandableListAdapter
88
import android.widget.ImageView
9-
import android.widget.Switch
109
import android.widget.TextView
10+
import androidx.appcompat.widget.SwitchCompat
1111
import com.pennapps.labs.pennmobile.R
1212
import com.pennapps.labs.pennmobile.laundry.LaundryViewModel
1313
import com.pennapps.labs.pennmobile.laundry.classes.LaundryRoomSimple
@@ -20,7 +20,7 @@ class LaundrySettingsAdapter(
2020
private val mContext: Context,
2121
private val dataModel: LaundryViewModel,
2222
) : BaseExpandableListAdapter() {
23-
private val switches: MutableList<Switch> = ArrayList()
23+
private val switches: MutableList<SwitchCompat> = ArrayList()
2424

2525
init {
2626
dataModel.setToggled()
@@ -65,7 +65,7 @@ class LaundrySettingsAdapter(
6565
val textView = view.findViewById<TextView>(R.id.laundry_building_name)
6666
textView.text = laundryHallName
6767
val imageView = view.findViewById<ImageView>(R.id.laundry_building_dropdown)
68-
val buildingSwitch = view.findViewById<Switch>(R.id.laundry_building_favorite_switch)
68+
val buildingSwitch = view.findViewById<SwitchCompat>(R.id.laundry_building_favorite_switch)
6969

7070
// if there is only one laundry room in the building, don't have dropdown
7171
if (dataModel.getRooms(laundryHallName)!!.size == 1) {
@@ -122,7 +122,7 @@ class LaundrySettingsAdapter(
122122
val textView = view.findViewById<TextView>(R.id.laundry_room_name)
123123
val name = laundryRoom.name
124124
textView.text = name
125-
val favoriteSwitch = view.findViewById<Switch>(R.id.laundry_favorite_switch)
125+
val favoriteSwitch = view.findViewById<SwitchCompat>(R.id.laundry_favorite_switch)
126126

127127
val roomId: Int = laundryRoom.id!!
128128

@@ -153,15 +153,15 @@ class LaundrySettingsAdapter(
153153

154154
private fun updateSwitches() {
155155
if (dataModel.isFull()) {
156-
val iter: Iterator<Switch> = switches.iterator()
156+
val iter: MutableIterator<SwitchCompat> = switches.iterator()
157157
while (iter.hasNext()) {
158158
val nextSwitch = iter.next()
159159
if (!nextSwitch.isChecked) {
160160
nextSwitch.isEnabled = false
161161
}
162162
}
163163
} else {
164-
val iter: Iterator<Switch> = switches.iterator()
164+
val iter: MutableIterator<SwitchCompat> = switches.iterator()
165165
while (iter.hasNext()) {
166166
val nextSwitch = iter.next()
167167
nextSwitch.isEnabled = true

PennMobile/src/main/res/layout/laundry_settings_parent_item.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@
1111
android:textSize="20sp"
1212
android:textStyle="bold" />
1313

14-
<Switch
14+
<androidx.appcompat.widget.SwitchCompat
1515
android:id="@+id/laundry_building_favorite_switch"
1616
android:layout_width="wrap_content"
1717
android:layout_height="wrap_content"
18-
android:layout_alignParentRight="true"
18+
android:layout_alignParentEnd="true"
1919
android:visibility="gone" />
2020

2121
<ImageView

0 commit comments

Comments
 (0)