-
Notifications
You must be signed in to change notification settings - Fork 39
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
Retain file information when closing and reopening #176
base: master
Are you sure you want to change the base?
Conversation
I like the intent behind this, but I still would prefer something more like this: #121 The clear/reset change sounds good. As for the commits, if you rebase this branch on current main/master it should resolve the extra commits. |
the best system would be to make it document-based (like Bit Slicer for macOS) but i fear i don't know enough about qt to make that change, maybe some day though |
Just to be clear, so we don't break the flow of existing users I would want
Something like that in the PR that enables this behavior. |
Bumping. @cristian64 thoughts on just merging as is? I like the general idea even if I prefer optionally maintaining the old way. |
@@ -267,7 +267,7 @@ void MemWatchWidget::onMemWatchContextMenuRequested(const QPoint& pos) | |||
contextMenu->addSeparator(); | |||
} | |||
|
|||
if (!node || node->isGroup()) | |||
if (node == m_watchModel->getRootNode() || node->isGroup()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ideally, this change (which relates to #175) should land in its own PR.
@@ -853,6 +853,7 @@ void MemWatchWidget::clearWatchList() | |||
return; | |||
|
|||
m_watchModel->clearRoot(); | |||
m_watchListFile = ""; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To avoid constructing another object for the sake of clearing the member:
- m_watchListFile = "";
+ m_watchListFile.clear();
.DS_Store | ||
.cache |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Out of curiosity, what is .cache
?
And, as always, these unrelated changes should at the very least have their own commit and description. Perhaps it can even have a dedicated PR to avoid getting the change blocked by other potentially controversial changes.
I may be a bit out of the loop, but I'm not entirely sure what these are trying to accomplish. By looking at the diff, I can't see how the watch list file path is consumed on startup. |
@camila314 following up if you plan to make changes, I'm going to release another patch version soon |
Previously, closing and reopening the program meant having to re-save the opened file and overwrite the file. This retains the opened file so you no longer have to go through that process.
Also changed "Clear the watch list" to "Reset watch list" and made it discard the saved file information.