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

Bug: Open With is incorrectly displayed when multiple files are selected #16342

Open
FieryRMS opened this issue Oct 15, 2024 · 17 comments
Open
Labels
area - context menu Features or bug reports relating to the context menu

Comments

@FieryRMS
Copy link
Contributor

Description

Clicking Open With after selecting multiple files might be useful for a small amount of files but it is really annoying when you select a bunch of files and either mistakenly or intentionally click it thinking it will ask only once.

Steps To Reproduce

  1. select a bunch of files, maybe ctrl-a
  2. right click -> open with
  3. Dialogue keeps opening one after another, making pc unusable until closing all dialogs

Requirements

maybe we can remove this option like in base explorer? or improve it so that after choosing app we pass the files instead of requesting dialog for each of them?

Files Version

3.7.7.0

Windows Version

10.0.22631.4317

User ID

No response

Log File

not required

@Josh65-2201
Copy link
Member

Thanks for the feedback

@yaira2
Copy link
Member

yaira2 commented Oct 15, 2024

The expected behavior is for "Open With" to only be shown when a single file is selected.

@yaira2 yaira2 changed the title Bug: Open With on multiple files opens multiple dialogs Bug: Open With is incorrectly displayed when multiple files are selected Oct 15, 2024
@yaira2 yaira2 moved this from 🆕 New to 🔖 Ready to build in Files task board Oct 15, 2024
@yaira2 yaira2 added the good first issue Good issue for new contributors to get started with label Oct 15, 2024
@Lamparter
Copy link
Contributor

The expected behavior is for "Open With" to only be shown when a single file is selected.

@yaira2 I'm not sure I understand, the current behaviour doesn't seem to cause this issue.

@yaira2
Copy link
Member

yaira2 commented Oct 27, 2024

I mean that the option to "Open with" is incorrectly shown when multiple files are selected. The correct behavior is to only display the option for a single file.

@thelistenersfury
Copy link

If this option goes away I would prefer it to be on a setting toggle, as I very highly prefer open with remaining an option for multiple files and would like to keep it on.

@FieryRMS
Copy link
Contributor Author

I am just curious, what would you use it for? Imho this "feature" is really annoying for most use cases, since it practically soft-locks your pc with how its implemented. Even for small number of files the dialog doesnt tell you which file its for so even then is useless.

@thelistenersfury
Copy link

thelistenersfury commented Oct 28, 2024

I am just curious, what would you use it for? Imho this "feature" is really annoying for most use cases, since it practically soft-locks your pc with how its implemented. Even for small number of files the dialog doesn't tell you which file its for so even then is useless.

I spend a lot of time modding video games, and very often I have a whole lot of small images I want specific image editors (photoshop, pant.net, csp, blender, etc depending on file type or use case) to open all at once. same kind of thing with various text file extensions for all kinds of games. There are also a lot of less common file extensions I end up working with and change programs for them frequently enough that even having a set open and set edit for each file type is not really enough.

For example, games in the elder scrolls and falllout series (for example morrowind, oblivion, and skyrim) all use file formats like .esp or bsa and the tool I'd want to open them with depends on which game a esp is for.

And yes I could open photoshop or whatever and drag them over but its much faster with the context menu and I don't have to already have the program open and for me it's one of the huge selling points of the files app.

This isn't saying that I don't think you should be allowed to disable it, or cancel the operation if you accidently hit it, in my opinion more customization and options is always better. But I adore having open with always active and really don't want it to go.

Sorry that got kinda long

@yaira2
Copy link
Member

yaira2 commented Oct 28, 2024

If that's a common enough use case, I don't mind keeping the existing behavior. And for everyone else, they don't have to use it if they don't want.

@yaira2 yaira2 moved this from 🔖 Ready to build to 📋 Planning stage in Files task board Oct 28, 2024
@FieryRMS
Copy link
Contributor Author

And yes I could open photoshop or whatever and drag them over but its much faster with the context menu and I don't have to already have the program open and for me it's one of the huge selling points of the files app.

If I understand correctly, you select a bunch of files to open in the same program? I don't suppose you choose to open it with a different program after having selected all the files, right? (Eg. you select a few image files to open in photoshop, then select a few more to open in paint, but not select a few files to open in both PS and paint)

I think if we implement a way to show only one dialog after selecting all the files, we can avoid the softlocking issue while also satisfying the mentioned use case, which will speed up the mentioned workflow even more.

@FieryRMS
Copy link
Contributor Author

FieryRMS commented Oct 28, 2024

If that's a common enough use case, I don't mind keeping the existing behavior.

I wouldn't know how many people use this "feature", maybe we can host a vote?

@thelistenersfury
Copy link

I think if we implement a way to show only one dialog after selecting all the files, we can avoid the softlocking issue while also satisfying the mentioned use case, which will speed up the mentioned workflow even more.

I would definitely appreciate that honestly, would be even better than what we got now

@yaira2
Copy link
Member

yaira2 commented Oct 28, 2024

Since @thelistenersfury provided a valid use case, I'm happy to keep things as they are. For those who don't need it, they don't have to use it.

@sirwilliamthefirst
Copy link

So, I am taking a look. If we wanted to stop "open with" with multiple files, all that is needed is to add an additional check in IsExecutable() for OpenItemWithAPplicationPickerAction class. However, if we want to choose a bunch of files to open in the same program, then we would either have to return the option that was chosen in the windows application picker. That, or not use the windows application picker, and instead have the user to pick from this drop down menu posted below (currently does not show if multiple files are selected)

Image

Thoughts?

@yaira2
Copy link
Member

yaira2 commented Nov 5, 2024

So, I am taking a look. If we wanted to stop "open with" with multiple files, all that is needed is to add an additional check in IsExecutable() for OpenItemWithAPplicationPickerAction class.

This is correct, and doing so would match the behavior found in File Explorer.

However, if we want to choose a bunch of files to open in the same program, then we would either have to return the option that was chosen in the windows application picker. That, or not use the windows application picker, and instead have the user to pick from this drop down menu posted below (currently does not show if multiple files are selected)

If we decide to keep the option available, we will likely need to go with the first approach, as not every file type displays options in the submenu.

@sirwilliamthefirst
Copy link

sirwilliamthefirst commented Nov 5, 2024

After further research it doest seem that the Launcher.LaunchFileAsync Method exposes the user's choice when DisplayApplicationPicker is set to true. (NavigationHelper.cs Line 574)

I think if we want to go with the first approach of returning the users choice, then I believe a custom applocation picker would have to be implemented that exposes user's choice to the application

@0x5bfa
Copy link
Member

0x5bfa commented Nov 6, 2024

Could you update the requirements.

@yaira2
Copy link
Member

yaira2 commented Nov 6, 2024

@0x5bfa we're still in the planning stage.

@yaira2 yaira2 removed the good first issue Good issue for new contributors to get started with label Dec 24, 2024
@Josh65-2201 Josh65-2201 added the area - context menu Features or bug reports relating to the context menu label Jan 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area - context menu Features or bug reports relating to the context menu
Projects
Status: 📋 Planning stage
Development

No branches or pull requests

7 participants