MDANSE icon indicating copy to clipboard operation
MDANSE copied to clipboard

Add recently used files option to g UI

Open IfyyAgu opened this issue 4 months ago • 3 comments

Description of work Add an option in the GUI to open recently used files. The File menu will have a new section. There will be a way to select a recently opened trajectory file, which will then be opened in the trajectory tab. There will be a way to select a recently opened results file (.mda), which will then be opened in the plot creator tab.

IfyyAgu avatar Nov 03 '25 10:11 IfyyAgu

I have two comments for now:

  1. Please rebase your branch to make sure that all the recent changes to protos branch have been included and merge conflicts resolved.
  2. Could you make the saving process more selective, so it stores the trajectory as recently used only if it had been loaded successfully?

MBartkowiakSTFC avatar Nov 03 '25 13:11 MBartkowiakSTFC

I have included the changes you suggested including rebase.

IfyyAgu avatar Nov 24 '25 15:11 IfyyAgu

Sorry for not writing it explicitly before: do you think you could also make the .mda files appear on the list only if they were loaded successfully?

MBartkowiakSTFC avatar Nov 26 '25 10:11 MBartkowiakSTFC

On my computer, if the list of recently used files was empty on GUI startup, the items in the recently used file menu would not appear, even though new file names had been added to the JSON files. The second time I ran the GUI everything was fine and the list of recently used files would be updated every time I loaded a file. I did not find the reason for it, so I just added an placeholder item to make sure that the list is never empty, and this worked around the problem.

MBartkowiakSTFC avatar Dec 09 '25 11:12 MBartkowiakSTFC