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

Add Recent Files Menu and Improve Recent Sessions #1616

Merged
merged 5 commits into from
Nov 19, 2024
Merged

Conversation

lbergelson
Copy link
Contributor

This primarily does 2 things:

  1. It adds a new Recent Files pop up menu which keeps track of the most recently opened files and URLs and allows reopening them quickly. This was asked for here: (Feature Request: Recently opened files #1547). It doesn't include the asked for feature of tracking the genome associated with each file to make it easier to reload that genome, that could be added in the future if necessary.

  2. It makes the recent sessions list update dynamically instead of only on file load. Previously saving or opening a session doesn't update the list, now it will update as expected.

It adds a new collection type which I called "StackSet" which is basically a stack that only allows unique entries. Adding an element that already exists moves it to the top of the stack. It's implemented twice (RecentFilesSet, RecentUrlsSet) since the serialization of recent session files has to be handled differently than the serialization of files which might have an associated index.

I've refactored the code around saving recent sessions to make it a bit cleaner.

In the future, it might make sense to move the list of recent sessions to a pop up as well.

# Conflicts:
#	src/main/java/org/broad/igv/ui/action/LoadFromURLMenuAction.java
…reate/loaded

* previously it only updated once when IGV was loaded
* This dynamically tracks the most recently loaded files/urls and allows reopening them
* Fixes ##1547
@jrobinso jrobinso merged commit 5a9d821 into main Nov 19, 2024
2 checks passed
@jrobinso jrobinso deleted the lb_recent_files branch November 19, 2024 23:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants