Make entire peers page scrollable #290

Manually merged
jarolrod merged 2 commits from peers-scroll-correction into main 2023-07-12 10:08:07 +00:00 AGit
jarolrod commented 2023-03-15 07:42:28 +00:00 (Migrated from github.com)

Makes the entire peers page scrollable by moving in the top elements of the page into the header property of the ListView itself.

master pr
Screen Shot 2023-03-15 at 3 45 03 AM Screen Shot 2023-04-17 at 9 26 57 PM

Windows
Intel macOS
Apple Silicon macOS
ARM64 Android
ARM32 Android

Makes the entire peers page scrollable by moving in the top elements of the page into the header property of the ListView itself. | master | pr | | ------ | -- | | <img width="708" alt="Screen Shot 2023-03-15 at 3 45 03 AM" src="https://user-images.githubusercontent.com/23396902/225241131-239b3189-c9cc-4a32-afb4-c80e48b0be8d.png"> |<img width="752" alt="Screen Shot 2023-04-17 at 9 26 57 PM" src="https://user-images.githubusercontent.com/23396902/232649633-dfc3a34b-61bc-4c00-8984-a33af71228e5.png"> | [![Windows](https://img.shields.io/badge/OS-Windows-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/win64/unsecure_win_gui.zip?branch=pull/290) [![Intel macOS](https://img.shields.io/badge/OS-Intel%20macOS-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/macos/unsecure_mac_gui.zip?branch=pull/290) [![Apple Silicon macOS](https://img.shields.io/badge/OS-Apple%20Silicon%20macOS-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/macos_arm64/unsecure_mac_arm64_gui.zip?branch=pull/290) [![ARM64 Android](https://img.shields.io/badge/OS-Android-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/android/unsecure_android_apk.zip?branch=pull/290) [![ARM32 Android](https://img.shields.io/badge/OS-Android%2032bit-green)](https://api.cirrus-ci.com/v1/artifact/github/bitcoin-core/gui-qml/android32/unsecure_android_32bit_apk.zip?branch=pull/290)
johnny9 (Migrated from github.com) requested changes 2023-03-15 15:09:21 +00:00
johnny9 (Migrated from github.com) left a comment

Would like to still prevent the toggle buttons from being flickable if there is enough width for the view.

Would like to still prevent the toggle buttons from being flickable if there is enough width for the view.
johnny9 (Migrated from github.com) commented 2023-03-15 15:08:51 +00:00

This line is designed to prevent being able to flick the toggle buttons when the view is wide enough. I'm not sure why it doesn't work with these changes. Possibly need a >= but not sure.

This line is designed to prevent being able to flick the toggle buttons when the view is wide enough. I'm not sure why it doesn't work with these changes. Possibly need a >= but not sure.
johnny9 commented 2023-03-15 15:09:46 +00:00 (Migrated from github.com)

Concept ACK

Concept ACK
jarolrod (Migrated from github.com) reviewed 2023-03-15 20:53:01 +00:00
jarolrod (Migrated from github.com) commented 2023-03-15 20:53:01 +00:00

leave for a follow-up? really there's nothing wrong with the current behavior except that it's not 100% visually what we want in the case that the user decides to flick when all buttons are visible.

leave for a follow-up? really there's nothing wrong with the current behavior except that it's not 100% visually what we want in the case that the user decides to flick when all buttons are visible.
GBKS commented 2023-04-12 12:16:30 +00:00 (Migrated from github.com)

It looks like the page title disappeared on this screen? Could we add that back in? The description also still has placeholder text, how about we replace it with "Peers are nodes you exchange transaction data with."?

It looks like the page title disappeared on this screen? Could we add that back in? The description also still has placeholder text, how about we replace it with "Peers are nodes you exchange transaction data with."?
jarolrod commented 2023-04-18 01:54:14 +00:00 (Migrated from github.com)

@GBKS Which of the two should the page title be:

a b
Screen Shot 2023-04-17 at 9 26 57 PM Screen Shot 2023-04-17 at 9 52 50 PM
@GBKS Which of the two should the page title be: | a | b | | - | - | | <img width="752" alt="Screen Shot 2023-04-17 at 9 26 57 PM" src="https://user-images.githubusercontent.com/23396902/232649633-dfc3a34b-61bc-4c00-8984-a33af71228e5.png"> | <img width="752" alt="Screen Shot 2023-04-17 at 9 52 50 PM" src="https://user-images.githubusercontent.com/23396902/232649658-e1d4dc77-5004-42cc-a344-8a9a71f0df17.png"> |
GBKS commented 2023-04-18 05:48:58 +00:00 (Migrated from github.com)

Left one, please.

Left one, please.
jarolrod commented 2023-04-20 23:53:10 +00:00 (Migrated from github.com)

Updated from 023e638b37c40418fdd2033899a5d1f311868200 to a87fa639592a501388412457aa94ccb538e5ea45

changes: addressed review feedback on description and page title

Updated from [023e638b37c40418fdd2033899a5d1f311868200](https://github.com/bitcoin-core/gui-qml/pull/290/commits/023e638b37c40418fdd2033899a5d1f311868200) to [a87fa639592a501388412457aa94ccb538e5ea45](https://github.com/bitcoin-core/gui-qml/pull/290/commits/a87fa639592a501388412457aa94ccb538e5ea45) changes: addressed review feedback on description and page title
johnny9 (Migrated from github.com) approved these changes 2023-04-21 05:15:23 +00:00
johnny9 (Migrated from github.com) left a comment

ACK a87fa639592a501388412457aa94ccb538e5ea45

ACK a87fa639592a501388412457aa94ccb538e5ea45
GBKS commented 2023-04-21 08:01:58 +00:00 (Migrated from github.com)

I downloaded the latest MacOS version above and don't see the new title and description in the Peers page. Scrolling works well though.

I downloaded the latest MacOS version above and don't see the new title and description in the Peers page. Scrolling works well though.
jarolrod commented 2023-04-22 01:32:03 +00:00 (Migrated from github.com)

Updated from a87fa63 to 9870271, compare

Changes: addressed conflicts with master

Updated from [a87fa63 ](https://github.com/bitcoin-core/gui-qml/commit/a87fa639592a501388412457aa94ccb538e5ea45)to [9870271](https://github.com/bitcoin-core/gui-qml/commit/9870271648964352b35675d3eee9d0f34178dea2), [compare](https://github.com/bitcoin-core/gui-qml/compare/a87fa639592a501388412457aa94ccb538e5ea45..9870271648964352b35675d3eee9d0f34178dea2) Changes: addressed conflicts with master
GBKS commented 2023-04-28 07:00:00 +00:00 (Migrated from github.com)

Looks like it still doesn't build properly. Not seeing the latest changes.

Looks like it still doesn't build properly. Not seeing the latest changes.
jarolrod commented 2023-05-10 00:59:23 +00:00 (Migrated from github.com)

Updated from 9870271 to 1e5477e

Changes: rebased over main

Updated from [9870271 ](https://github.com/bitcoin-core/gui-qml/commit/9870271648964352b35675d3eee9d0f34178dea2)to [1e5477e](https://github.com/bitcoin-core/gui-qml/commit/1e5477e579dc7d97ad74ae32d5a9c4122b534e13) Changes: rebased over main
jarolrod commented 2023-05-29 03:35:31 +00:00 (Migrated from github.com)

Updated from 1e5477e to 478d59a

changes: rebased over main

Updated from[ 1e5477e ](https://github.com/bitcoin-core/gui-qml/commit/1e5477e579dc7d97ad74ae32d5a9c4122b534e13)to 478d59a changes: rebased over main
johnny9 commented 2023-06-02 21:30:59 +00:00 (Migrated from github.com)
ACK 478d59a6b668c432ff83335dce23f70581245d53
promag (Migrated from github.com) reviewed 2023-06-05 22:08:18 +00:00
promag (Migrated from github.com) commented 2023-06-05 22:08:18 +00:00

I think this can be

contentItem: ListView {
}

note that width, height, anchors.* are gone, since Page will resize the content item accordingly.

If the maximum width (450 in this case) is something to keep then:

contentItem: RowLayout {
    ListView {
        Layout.maximumWidth: 450
        Layout.fillWidth: true
        Layout.alignment: Qt.AlignHCenter
    }
}

Left and right padding can be set on the root item Page.

I think this can be ```qml contentItem: ListView { } ``` note that `width`, `height`, `anchors.*` are gone, since `Page` will resize the content item accordingly. If the maximum width (450 in this case) is something to keep then: ```qml contentItem: RowLayout { ListView { Layout.maximumWidth: 450 Layout.fillWidth: true Layout.alignment: Qt.AlignHCenter } } ``` Left and right padding can be set on the root item `Page`.
jarolrod (Migrated from github.com) reviewed 2023-06-07 00:05:13 +00:00
jarolrod (Migrated from github.com) commented 2023-06-07 00:05:13 +00:00

Going to leave this as is, as more changes are actually required to accomplish this refactor. A follow-up can change the pattern for all pages.

Going to leave this as is, as more changes are actually required to accomplish this refactor. A follow-up can change the pattern for all pages.
D33r-Gee (Migrated from github.com) reviewed 2023-06-26 22:37:43 +00:00
D33r-Gee (Migrated from github.com) left a comment

tested Ack. Built on WSL Ubuntu 22.04 for android armv7a.
On android device, before building this PR the "ID, Directions, etc..." buttons would stay anchored at the top with this PR they scroll up. Is that the desired behavior @jarolrod ?

tested Ack. Built on WSL Ubuntu 22.04 for android armv7a. On android device, before building this PR the "ID, Directions, etc..." buttons would stay anchored at the top with this PR they scroll up. Is that the desired behavior @jarolrod ?
GBKS commented 2023-07-06 08:57:10 +00:00 (Migrated from github.com)

Wanted to test, but the download links are☠️. This is a simple issue and several others have tested and confirmed, so I'm cool with merging (unless of course the dead links are a reason for concern and something is off with this PR).

Wanted to test, but the download links are☠️. This is a simple issue and several others have tested and confirmed, so I'm cool with merging (unless of course the dead links are a reason for concern and something is off with this PR).
jarolrod commented 2023-07-08 04:53:27 +00:00 (Migrated from github.com)

@GBKS updated PR description CI links

@D33r-Gee yep! that would be the desired behavior

@GBKS updated PR description CI links @D33r-Gee yep! that would be the desired behavior
GBKS commented 2023-07-12 06:25:07 +00:00 (Migrated from github.com)
ACK https://github.com/bitcoin-core/gui-qml/pull/290/commits/478d59a6b668c432ff83335dce23f70581245d53 Tested. Look good.
Sign in to join this conversation.
No description provided.