Opened 2 years ago

Last modified 4 months ago

#13151 assigned bug

BFilePanel empty after pressing ESC

Reported by: humdinger Owned by: waddlesplash
Priority: normal Milestone: Unscheduled
Component: Kits/ Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: no Platform: All


This is hrev50808.

If a filepanel is used in B_DIRECTORY_NODE mode and the user presses ESC, all the contents in the panel disappears. I first saw it with BurnItNow, confirmed it in Ubertuber and can replicate with Expander's destination file panel. Are there other apps using B_DIRECTORY_NODE?

Weirdly, it shows also in Expander's source panel, which uses B_FILE_NODE mode. But it doesn't show with any other open file dialog I checked, not in StyledEdit, Pe, ShowImage...

Could this be related to the even more annoying "Missing shortcuts in file panels", #11979 ?

Attachments (2)

0001-Always-let-ESCAPE-key-close-file-panel.patch (995 bytes) - added by owenca 21 months ago.
0001-Make-Esc-and-Alt-Up-keys-work-for-file-panels.patch (1.2 KB) - added by owenca 21 months ago.

Download all attachments as: .zip

Change History (18)

comment:1 Changed 2 years ago by axeld

Owner: changed from axeld to nobody
Status: newassigned

comment:2 Changed 2 years ago by waddlesplash

Component: Kits/Storage KitKits/

comment:3 Changed 21 months ago by owenca

I don't think it's related to #11979. See the attached patch below.

comment:4 Changed 21 months ago by owenca

Has a Patch: set

comment:5 Changed 21 months ago by humdinger

Owner: changed from nobody to waddlesplash

comment:6 Changed 21 months ago by humdinger

I locally applied this patch and the one from #11979, build Tracker, put it and the into non-packaged and blacklisted the system Tracker and in the boot options.

For some reason, upon booting I'm greeted with an empty blue desktop and an empty title-less window...

comment:7 Changed 21 months ago by owenca

Please see the updated patch. I'm not sure if we still want to make Atl-W close the file panel because Esc will do the job.

Also, the Esc key still clears the file list view before closing the panel. It seems to be a bug in Tracker. I don't know if we want to not send Esc to Tracker before closing the panel so as to avoid the bug.

comment:8 Changed 21 months ago by humdinger

We should keep ALT+W, it's a system wide shortcut.
I think the ESC handling should be: if something's filtered with type-ahead-filtering, ESC clears that filter. Only if nothing is filtered, ESC closes the panel.

comment:9 Changed 21 months ago by pulkomandy

I would prefer if ESC did not close windows, especially if it depends on the context.

As a vim user, I tend to press ESC a lot as this is how you switch mdoes in vim. I find it very annoying when it closes a window without a warning. So we should restrict that to very few cases, and I'm not sure file panels are one of these, because closing them may lose some state (maybe you navigated to a specific directory, carefully searched for the right file in there, etc).

comment:10 Changed 21 months ago by humdinger

I'm pretty sure file panel always used to be closable with ESC. It just doesn't always work for all apps for some reason.

Personally, not being a vim user (shocker!), ESC is synonymous to "Cancel". I save about a hundred mouse miles with my finger hovering near ESC instead of aim and click a "Cancel" button or even tinyer close widget.

comment:11 Changed 21 months ago by diver

FWIW, I'm with humdinger here.

comment:12 Changed 21 months ago by pulkomandy

Depending on the context:

  • If you are renaming a file, ESC aborts that operation
  • If you are using filtering, ESC aborts that operation
  • If you are not doing either, ESC closes the whole window

I find it annoying that the same key can be used for the third case. I would allow this only in windows where ESC is not used for anything else. There's already Alt+W if you need to close the window from the keyboard, and this one always work no matter what you are doing (renaming a file, filtering, ...).

comment:13 Changed 21 months ago by humdinger

My opinion differs. I see your 3rd item as also "aborting that operation". The operation being open/save a file via file dialog. I agree that using ESC to close the main window of an app would be bad (in most cases). But the open/save dialog is only a sub-process, an operation, in your work flow within that app.

comment:14 Changed 20 months ago by humdinger

Please also see my comment at ticket:11979#comment:22

comment:15 Changed 20 months ago by owenca

Has a Patch: unset

comment:16 Changed 4 months ago by humdinger

Maybe related: pressing ESC in a query result window also clears away all items.

Note: See TracTickets for help on using tickets.