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

'Show in external file explorer' on editor menu more than once for split panels #5475

Closed
csabella opened this issue Oct 15, 2017 · 0 comments

Comments

@csabella
Copy link
Contributor

When in the editor, every time the panel is split, the gears menu adds an additional option for 'Show in external file explorer'.

What steps will reproduce the problem?

  1. Open the editor.
  2. Click on the gears and see 'Show in external file explorer' is listed once.
  3. Split the panel.
  4. Check the gears on the new panel. 'Show in external file explorer' is now listed twice.
  5. Rinse and repeat. It's added one more time for each split.

What is the expected output? What do you see instead?
I expect the menu option to only be listed once.

Please provide any additional information below
I believe this was introduced with PR #4337. In the EditorStack class in widgets editor.py, the incoming argument of actions is appened to(actions.append(external_fileexp_action)). Since this is a list, the append causes it to be changed in the calling routine (EditorSplitter class). When a new EditorStack is created, the new list with the appended action is sent instead of the original list being sent.

Versions and main components

  • Spyder Version: 3.x and 4.0
  • Python Version: 3.6.3
  • Qt Version:
  • PyQt Version:
  • Operating system: Ubuntu 16.04

Dependencies

Please go to the menu entry Help > Optional Dependencies (or
Help > Dependencies), press the button Copy to clipboard
and paste the contents below:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants