Skip to content

Commit

Permalink
added button in more maybe
Browse files Browse the repository at this point in the history
  • Loading branch information
trinif committed Dec 1, 2023
1 parent 6b34705 commit 3f165d4
Show file tree
Hide file tree
Showing 17 changed files with 50 additions and 0 deletions.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,16 @@ class PreferenceFragment : PreferenceFragmentCompat() {
return@setOnPreferenceClickListener true
}

val sublettingFeaturePref: Preference? = findPreference("pref_subletting_feature")
sublettingFeaturePref?.setOnPreferenceClickListener {
mActivity.supportFragmentManager.beginTransaction()
.replace(R.id.content_frame, SublettingFragment())
.addToBackStack(null)
.setTransition(FragmentTransaction.TRANSIT_FRAGMENT_OPEN)
.commit()
return@setOnPreferenceClickListener true
}


val pennLabsPref: Preference? = findPreference("pref_labs_link")
pennLabsPref?.setOnPreferenceClickListener {
Expand Down
18 changes: 18 additions & 0 deletions PennMobile/src/main/res/drawable/ic_subletting_test_foreground.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="108dp"
android:height="108dp"
android:viewportWidth="24"
android:viewportHeight="24"
android:tint="#FFFFFF">
<group android:scaleX="0.58"
android:scaleY="0.58"
android:translateX="5.04"
android:translateY="5.04">
<path
android:fillColor="@android:color/white"
android:pathData="M1,11l0,10l5,0l0,-6l4,0l0,6l5,0l0,-10l-7,-5z"/>
<path
android:fillColor="@android:color/white"
android:pathData="M10,3v1.97l7,5V11h2v2h-2v2h2v2h-2v4h6V3H10zM19,9h-2V7h2V9z"/>
</group>
</vector>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_subletting_test_background"/>
<foreground android:drawable="@drawable/ic_subletting_test_foreground"/>
</adaptive-icon>
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<adaptive-icon xmlns:android="http://schemas.android.com/apk/res/android">
<background android:drawable="@color/ic_subletting_test_background"/>
<foreground android:drawable="@drawable/ic_subletting_test_foreground"/>
</adaptive-icon>
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_subletting_test_background">#AB72F1</color>
</resources>
8 changes: 8 additions & 0 deletions PennMobile/src/main/res/xml/settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,14 @@
app:key="pref_fitness_feature"
app:title="Fitness" />

<Preference
android:id="@+id/pref_subletting_feature"
android:hapticFeedbackEnabled="true"
app:icon="@drawable/ic_subletting_test_foreground"
app:iconSpaceReserved="false"
app:key="pref_subletting_feature"
app:title="Subletting" />


</PreferenceCategory>

Expand Down

0 comments on commit 3f165d4

Please sign in to comment.