[PR #59] [MERGED] fix: back button android, return home on tap #229

Closed
opened 2025-10-31 17:07:51 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/pd4d10/git-touch/pull/59
Author: @shreyas1599
Created: 4/15/2020
Status: Merged
Merged: 4/16/2020
Merged by: @pd4d10

Base: masterHead: back-options


📝 Commits (2)

  • 47344ba fix: back button android, return home on tap
  • 18c9dc6 fix: reuse logic for platforms

📊 Changes

1 file changed (+49 additions, -6 deletions)

View changed files

📝 lib/home.dart (+49 -6)

📄 Description

Fixes #57 and #54

  • I could not use a list as for some reason indexing with a list did not work. The state was always at null. Instead had to use five variables and reused them for all the platforms.
  • Added a controller for the CupertinoTabScaffold as I need to get the value of index in onWillPop. I initially used a temporary variable and updated its value each time a tab bar item was clicked but because of using await in onWillPop it created trouble. And a controller inherently seems like a better option.

Let me know if there are any changes to be made. Thanks!


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/pd4d10/git-touch/pull/59 **Author:** [@shreyas1599](https://github.com/shreyas1599) **Created:** 4/15/2020 **Status:** ✅ Merged **Merged:** 4/16/2020 **Merged by:** [@pd4d10](https://github.com/pd4d10) **Base:** `master` ← **Head:** `back-options` --- ### 📝 Commits (2) - [`47344ba`](https://github.com/pd4d10/git-touch/commit/47344bad656b0e05da77447e76c43796a368e72a) fix: back button android, return home on tap - [`18c9dc6`](https://github.com/pd4d10/git-touch/commit/18c9dc6d9dee641d648eee50ac808845dd805b16) fix: reuse logic for platforms ### 📊 Changes **1 file changed** (+49 additions, -6 deletions) <details> <summary>View changed files</summary> 📝 `lib/home.dart` (+49 -6) </details> ### 📄 Description Fixes #57 and #54 - I could not use a list as for some reason indexing with a list did not work. The state was always at `null`. Instead had to use five variables and reused them for all the platforms. - Added a controller for the `CupertinoTabScaffold` as I need to get the value of `index` in `onWillPop`. I initially used a temporary variable and updated its value each time a tab bar item was clicked but because of using `await` in `onWillPop` it created trouble. And a controller inherently seems like a better option. Let me know if there are any changes to be made. Thanks! --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-10-31 17:07:51 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/git-touch#229