-
-
Notifications
You must be signed in to change notification settings - Fork 347
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 right-click context menu #2202
Conversation
Can Reinstall work for a mod that the user manually uninstalled? That's a large percentage of issue reports that come in, so it would be very helpful if we could simply say "right click ModX and choose Reinstall". |
I haven't actually tested that, but I need to work on reinstall anyway. But now time to go to bed. |
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.
This is great work, and it makes me soooo happy! if we can just exclude autodetected mods for this PR, I'd love to merge it.
GUI/Main.cs
Outdated
|
||
downloadContentsToolStripMenuItem.Enabled = !guiMod.IsCached; | ||
|
||
if (guiMod.IsInstalled || guiMod.IsAutodetected) |
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.
Properly handling AD mods is a whole can of worms, that I think would be better handled in a separate PR. There's a lot of different cases to consider. As this is, this throws a ModNotInstalledKraken for AD mods in ModuleInstaller.UninstallList that isn't being caught in the transaction below and thus crashes the client. Can we just make this if ( guiMod.IsInstalled )
? Then I can merge this and we can all work on extending the right-click functionality one menu item at a time.
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.
If you could make that one change, this should be fine to merge as a solid basis for future functionality. Converting AD mods to CKAN control would be better as a plugin, I think, thus maintaining our promise that CKAN won't touch files it didn't install.
Sorry for waiting, I had to do 12h weeks. Will make the changes |
GUI/Main.cs
Outdated
@@ -453,7 +427,7 @@ public void UpdateCKAN() | |||
SwitchEnabledState(); | |||
ClearLog(); | |||
tabController.RenameTab("WaitTabPage", "Updating CKAN"); | |||
SetDescription("Upgrading CKAN to " + AutoUpdate.Instance.LatestVersion); | |||
SetDescription("Upgrading CKAN to {AutoUpdate.Instance.LatestVersion}"); |
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.
Missing the dollar sign before the starting quote, I believe this will print the literal curly braces as text.
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.
How did VS screw that up?
GUI/Main.cs
Outdated
Repo.default_ckan_repo.ToString() | ||
); | ||
( | ||
Path.Combine(CurrentInstance.GameDir(), "CKAN/GUIConfig.xml"), |
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.
Let's use CurrentInstance.CkanDir()
.
PR should be good to go now. |
As said in #2180, here is a right click context menu. I already added a
Download Contents
and aReinstall
option.The
Reinstall
option is just a simple uninstall -> install process. I'll work on that a bit more to show the process in theWaitTabPage
and maybe a possibility to uninstall the mod whitout uninstalling its dependants.I also added a check for the left mouse button to double clicking.
Possible implementations:
Reinstall
option [Feature] Reinstall #2154Download contents
optionAdd to favourites
option Add a "favourite" column. #1677