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

Refresh package view on install/uninstall #6

Merged
merged 1 commit into from
Oct 5, 2012
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 4 additions & 0 deletions usr/lib/linuxmint/mintInstall/mintinstall.py
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,10 @@ def _on_transactions_changed(self, current, queued):
for package in self.packages:
if package.pkg.name == pkg_name:
package.pkg = new_pkg
# If the user is currently viewing this package in the browser,
# refresh the view to show that the package has been installed or uninstalled.
if self.application.navigation_bar.get_active().get_label() == pkg_name:
self.application.show_package(package, None)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

show_package will run navigation_bar.add_with_id with the same package name again,
but an additional navigation tab will not be created: as the documentation for add_with_id explains,
"If there is the same id already, replace the existing one with the new one".


# Update apps tree
model_apps = self.wTree.get_widget("tree_applications").get_model()
Expand Down