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

PR: Add Help Spyder entry to the Help menu (Application) #22699

Merged
merged 2 commits into from
Oct 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 8 additions & 5 deletions bootstrap.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,11 +101,14 @@
REPOS[DEVPATH.name]["editable"] = False

for name in REPOS.keys():
if not REPOS[name]['editable']:
install_repo(name)
installed_dev_repo = True
else:
logger.info("%s installed in editable mode", name)
# Don't install the spyder-remote-services subrepo because it's not
# necessary on the Spyder side.
if name != "spyder-remote-services":
if not REPOS[name]['editable']:
install_repo(name)
installed_dev_repo = True
else:
logger.info("%s installed in editable mode", name)

if installed_dev_repo:
logger.info("Restarting bootstrap to pick up installed subrepos")
Expand Down
8 changes: 8 additions & 0 deletions spyder/plugins/application/container.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ class ApplicationActions:
SpyderTroubleshootingAction = "spyder_troubleshooting_action"
SpyderDependenciesAction = "spyder_dependencies_action"
SpyderSupportAction = "spyder_support_action"
HelpSpyderAction = "help_spyder_action"
SpyderAbout = "spyder_about_action"

# Tools
Expand Down Expand Up @@ -137,6 +138,13 @@ def setup(self):
_("Spyder support..."),
triggered=lambda: start_file(__forum_url__))

self.create_action(
ApplicationActions.HelpSpyderAction,
_("Help Spyder..."),
icon=self.create_icon("inapp_appeal"),
triggered=self.inapp_appeal_status.show_appeal
)

# About action
self.about_action = self.create_action(
ApplicationActions.SpyderAbout,
Expand Down
11 changes: 8 additions & 3 deletions spyder/plugins/application/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,13 +223,18 @@ def _populate_help_menu_support_section(self):
"""Add Spyder base support actions to the Help main menu."""
mainmenu = self.get_plugin(Plugins.MainMenu)
for support_action in [
self.trouble_action, self.report_action,
self.dependencies_action, self.support_group_action]:
self.trouble_action,
self.report_action,
self.dependencies_action,
self.support_group_action,
self.get_action(ApplicationActions.HelpSpyderAction),
]:
mainmenu.add_item_to_application_menu(
support_action,
menu_id=ApplicationMenus.Help,
section=HelpMenuSections.Support,
before_section=HelpMenuSections.ExternalDocumentation)
before_section=HelpMenuSections.ExternalDocumentation
)

def _populate_help_menu_about_section(self):
"""Create Spyder base about actions."""
Expand Down
2 changes: 2 additions & 0 deletions spyder/plugins/application/widgets/status.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,8 @@ def _on_click(self):
def show_appeal(self):
if self._appeal_dialog is None:
self._appeal_dialog = InAppAppealDialog(self)

if not self._appeal_dialog.isVisible():
self._appeal_dialog.show()

# ---- StatusBarWidget API
Expand Down
Loading