[android] set bottom map buttons max width to 300dp #3353

Merged
arnaudvergnet merged 1 commit from github/fork/arnaudvergnet/bottom-map-buttons into master 2022-09-11 05:34:14 +00:00
arnaudvergnet commented 2022-09-05 17:26:57 +00:00 (Migrated from github.com)

When the screen is larger than 300dp, bottom map buttons will align to the left as requested in #2905 (comment). This threshold can be edited in the map_buttons_bottom_max_width value.

To make code easier to maintain, bottom menu buttons have been extracted into their own layout file.

Pixel 5

Portrait Landscape
Screenshot_1662397632 Screenshot_1662397637

Nexus One

Portrait Landscape
Screenshot_1662397763 Screenshot_1662397768

Pixel C

Portrait Landscape
Screenshot_1662398474 Screenshot_1662398486
When the screen is larger than 300dp, bottom map buttons will align to the left as requested in https://git.omaps.dev/organicmaps/organicmaps/pulls/2905#issuecomment-1236192812. This threshold can be edited in the `map_buttons_bottom_max_width` value. To make code easier to maintain, bottom menu buttons have been extracted into their own layout file. ## Pixel 5 | Portrait | Landscape | |-|-| | ![Screenshot_1662397632](/uploads/bf032708b7fd59fd4d392044f037e89f/188494950-76f89560-267e-42e8-9e46-45994298906a.png) | ![Screenshot_1662397637](/uploads/a977a5cee4f8173efb95921320deb492/188494958-d486d2e5-f110-4b3b-a0ae-a9c21dac81ec.png) | ## Nexus One | Portrait | Landscape | |-|-| | ![Screenshot_1662397763](/uploads/1b9fbc189f41d25a104f7e853b90f1cc/188494967-56a0301a-3926-4682-b126-d553798650c4.png) | ![Screenshot_1662397768](/uploads/741d5b75cf9663ccfc47709d90ea8063/188494972-830e7406-b6a0-4131-b2db-6806a359a467.png) | ## Pixel C | Portrait | Landscape | |-|-| | ![Screenshot_1662398474](/uploads/83dd3f00c326deb6b4306fcec4d724b4/188494981-761eb91d-d656-4225-8d76-c5e90d1e9ba7.png) | ![Screenshot_1662398486](/uploads/a6e477bef49f84ff11ced75d2f4821ec/188494986-a9329434-ff32-4051-88fd-f072e90a5e97.png) |
biodranik commented 2022-09-05 21:07:44 +00:00 (Migrated from github.com)

Thanks, Arnaud! Now as we started to test it and get feedback, there are several different ideas:

  1. Group buttons in the center in portrait mode, so it's easier to tap for left and right-handed people.
  2. As landscape mode is usually operated with two hands, it could be more logical to either split buttons to both edges, or move them to the right (so when we add "left-handed interface" option they will mirror to the left).

It would be interesting to use different layouts on different devices, by different people, and get some preliminary feedback.

Thanks, Arnaud! Now as we started to test it and get feedback, there are several different ideas: 1. Group buttons in the center in portrait mode, so it's easier to tap for left and right-handed people. 2. As landscape mode is usually operated with two hands, it could be more logical to either split buttons to both edges, or move them to the right (so when we add "left-handed interface" option they will mirror to the left). It would be interesting to use different layouts on different devices, by different people, and get some preliminary feedback.
arnaudvergnet commented 2022-09-05 21:22:51 +00:00 (Migrated from github.com)

Group buttons in the center in portrait mode, so it's easier to tap for left and right-handed people

Do you want to have less spacing between buttons, or are you only talking about portrait on tablets?

As landscape mode is usually operated with two hands, it could be more logical to either split buttons to both edges, or move them to the right (so when we add "left-handed interface" option they will mirror to the left).

Moving them to the right might be easier to implement so we may stick with this first and get feedback.

> Group buttons in the center in portrait mode, so it's easier to tap for left and right-handed people Do you want to have less spacing between buttons, or are you only talking about portrait on tablets? > As landscape mode is usually operated with two hands, it could be more logical to either split buttons to both edges, or move them to the right (so when we add "left-handed interface" option they will mirror to the left). Moving them to the right might be easier to implement so we may stick with this first and get feedback.
arnaudvergnet commented 2022-09-06 07:38:17 +00:00 (Migrated from github.com)

I made the maximum width 300dp instead of 450dp and forced the menu to align to the right on portrait. As I only check the orientation, the menu is centered in tablet as well. Do you prefer to align the menu to the right no matter the orientation in tablet (meaning checking the available width instead of orientation) ?

Pixel 5

Portrait Landscape
Screenshot_1662449633 Screenshot_1662449638

Pixel C

Portrait Landscape
Screenshot_1662449561 Screenshot_1662449566
I made the maximum width 300dp instead of 450dp and forced the menu to align to the right on portrait. As I only check the orientation, the menu is centered in tablet as well. Do you prefer to align the menu to the right no matter the orientation in tablet (meaning checking the available width instead of orientation) ? ## Pixel 5 | Portrait | Landscape | |-|-| | ![Screenshot_1662449633](/uploads/4a23e8b6063d7dfe7e5a9b1c6d9bc683/188574747-e976c827-2a11-4ad5-867a-9848ae88a789.png) | ![Screenshot_1662449638](/uploads/67abb27875b00842e7549b3647e30c31/188574760-49d1e39f-d755-456c-8c11-ec67e2d3beaa.png) | ## Pixel C | Portrait | Landscape | |-|-| | ![Screenshot_1662449561](/uploads/287813945cdac5e85f99aa464a7272c9/188574726-6b9b9dd6-c03c-4d2d-8670-addf6067bbc4.png) | ![Screenshot_1662449566](/uploads/776f224f61b0ecef60fda49e945e62da/188574739-afd190ba-21dc-4b8c-a46c-f1f4a7884608.png) |
vng commented 2022-09-07 21:22:10 +00:00 (Migrated from github.com)

"I made the maximum width 300dp instead of 450dp "
So what is a final value?

"I made the maximum width 300dp instead of 450dp " So what is a final value?
vng commented 2022-09-07 21:23:43 +00:00 (Migrated from github.com)

Review: Commented

I like last screenshots.
Center in portrait and right in landscape.
Does Android have some system settings for left-handed people?

**Review:** Commented I like last screenshots. Center in portrait and right in landscape. Does Android have some system settings for left-handed people?
arnaudvergnet commented 2022-09-07 22:54:45 +00:00 (Migrated from github.com)

I did not push yet, I wanted to have feedback first

I did not push yet, I wanted to have feedback first
arnaudvergnet commented 2022-09-07 22:57:04 +00:00 (Migrated from github.com)

Does Android have some system settings for left-handed people

I know you can force the RTL layout from the developers options but I haven't looked more into it.

> Does Android have some system settings for left-handed people I know you can force the RTL layout from the developers options but I haven't looked more into it.
vng commented 2022-09-09 08:49:55 +00:00 (Migrated from github.com)

approved this merge request

approved this merge request
vng (Migrated from github.com) merged commit into master 2022-09-11 05:34:14 +00:00
vng (Migrated from github.com) closed this pull request 2022-09-11 05:34:15 +00:00
arnaudvergnet commented 2022-09-11 10:41:43 +00:00 (Migrated from github.com)

changed title from [android] set bottom map buttons max width to {-45-}0dp to [android] set bottom map buttons max width to {+30+}0dp

changed title from **[android] set bottom map buttons max width to {-45-}0dp** to **[android] set bottom map buttons max width to {+30+}0dp**
arnaudvergnet commented 2022-09-11 10:43:14 +00:00 (Migrated from github.com)

mentioned in issue #3389

mentioned in issue #3389
vng (Migrated from github.com) approved these changes 2025-03-22 17:59:23 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: organicmaps/organicmaps#3353
No description provided.