Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Back to waypoints list after watching waypoint details #620

Open
scls19fr opened this issue May 10, 2021 · 6 comments · May be fixed by #749
Open

Back to waypoints list after watching waypoint details #620

scls19fr opened this issue May 10, 2021 · 6 comments · May be fixed by #749
Assignees
Labels
beginner friendly Perfect for jumping in enhancement

Comments

@scls19fr
Copy link
Contributor

scls19fr commented May 10, 2021

Hello,

XCSoar version

I'm using XCSoar 7.6

What should XCSoar do differently, what functionality should be added?

After seeing waypoints list to watch distance of several waypoints, I want to have more information about some specific waypoints (such as required glide ratio).
So I can select one and look for data such as required glide ratio or Alt diff MC safety.

Unfortunately when clicking on "close" button... it's getting back to map page... not waypoint lists which is not very convenient.... especially when considering several waypoints options.

Similar problem also occurs when using Nav / Alternates window

Changing (in such a context "Close" button to a "Back" button... which turn back to waypoints list will be a nice feature to have

What are you trying to do, what is the use case for the suggestion?

Waypoint details page should store the context of the "previous" page which was used to display waypoint details.
If it's waypoints list or alternates, close button should be turned to a back button to get back to either waypoints list or alternates list.

@scls19fr scls19fr changed the title Back to waypoints list after watching waypoint detail Back to waypoints list after watching waypoint details May 10, 2021
@lordfolken lordfolken added enhancement beginner friendly Perfect for jumping in labels May 11, 2021
@lordfolken
Copy link
Contributor

Please provide a PR.

@scls19fr
Copy link
Contributor Author

Sorry @lordfolken but it doesn't seems simple enough to me (or at least some guidance will be required)

I noticed the close_button at

close_button.Create(parent, look.button, _("Close"), layout.close_button,
button_style, dialog.MakeModalResultCallback(mrOK));

but I'm pretty sure some changes are also required on the "caller" side

AddButton(_("Select"), [this](){
list->OnWaypointListEnter();
});

@HeroicLemon
Copy link
Contributor

I've created a commit for this that...works, but feels like a bit of a hack. It is also perhaps incomplete because I think the Alternates dialog could benefit from having the same behavior. HeroicLemon@82fc215

I am also wondering if this could potentially break a user's existing .xci file somehow. I don't think changing the behavior like this would cause problems, but I also do not have a good feel for what sorts of things a user is able to do with the custom inputs yet. Should something like InputEvents::eventWaypointDetailsPersistent be created in order to ensure that past behavior is maintained?

@lordfolken
Copy link
Contributor

Please create a PR and set it to draft. Then it runs through our qa and testing stage, and we can have a discussion on the topic.

@MaxKellermann
Copy link
Contributor

It is debatable whether this is a good idea. I don't think it is. If you just want to look up a waypoint and inspect it, you then need an extra click to return to the map.
But in any case, the linked patch is bad because it creates a new list dialog every time. This loses all state.

@HeroicLemon
Copy link
Contributor

I have created the draft PR as requested #749

It is debatable whether this is a good idea. I don't think it is. If you just want to look up a waypoint and inspect it, you then need an extra click to return to the map.

A good point. On my last flight, I had actually been attempting to look at the details for multiple waypoints and found the current implementation a little annoying before I even saw this issue on GitHub, but if I did just want to look at the details for a single waypoint it could also be annoying to have to click twice to get back to my main view. Adding a separate InputEvent could allow a user to decide how their dialog behaved, but I would suspect many users don't make use of that feature?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
beginner friendly Perfect for jumping in enhancement
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants