Skip to content

Commit 7f3ff75

Browse files
ADFA-2686: Add feedback FAB to about landscape/sw600dp variants
The land and sw600dp variants of activity_about.xml omitted the feedback FAB, which violates the invariant that every page must always offer feedback. Add the shared feedback_fab include to both variants (bottom|start, matching portrait). Now that fab_feedback is present in every activity_about variant, its View Binding field is non-null, so AboutActivity uses binding.fabFeedback.root (dropping the previous nullable ?.root) — consistent with the other screens.
1 parent 3835304 commit 7f3ff75

3 files changed

Lines changed: 17 additions & 1 deletion

File tree

‎app/src/main/java/com/itsaky/androidide/activities/AboutActivity.kt‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ class AboutActivity : EdgeToEdgeIDEActivity() {
7878
supportActionBar!!.setDisplayHomeAsUpEnabled(true)
7979
supportActionBar!!.setTitle(R.string.about)
8080
toolbar.setNavigationOnClickListener { onBackPressedDispatcher.onBackPressed() }
81-
feedbackButtonManager = FeedbackButtonManager(this@AboutActivity, fabFeedback?.root)
81+
feedbackButtonManager = FeedbackButtonManager(this@AboutActivity, fabFeedback.root)
8282
feedbackButtonManager?.setupDraggableFab()
8383

8484
aboutHeader.apply {

‎app/src/main/res/layout-land/activity_about.xml‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,4 +118,12 @@
118118

119119
</com.google.android.material.appbar.AppBarLayout>
120120

121+
<include
122+
android:id="@+id/fab_feedback"
123+
layout="@layout/feedback_fab"
124+
android:layout_width="wrap_content"
125+
android:layout_height="wrap_content"
126+
android:layout_margin="16dp"
127+
android:layout_gravity="bottom|start" />
128+
121129
</androidx.coordinatorlayout.widget.CoordinatorLayout>

‎app/src/main/res/layout-sw600dp/activity_about.xml‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,4 +118,12 @@
118118

119119
</com.google.android.material.appbar.AppBarLayout>
120120

121+
<include
122+
android:id="@+id/fab_feedback"
123+
layout="@layout/feedback_fab"
124+
android:layout_width="wrap_content"
125+
android:layout_height="wrap_content"
126+
android:layout_margin="16dp"
127+
android:layout_gravity="bottom|start" />
128+
121129
</androidx.coordinatorlayout.widget.CoordinatorLayout>

0 commit comments

Comments
 (0)