Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

Fix issue #5210: Adding Menus.removeMenu() and Menus.getAllMenus() #5217

Merged
merged 3 commits into from
Sep 17, 2013
Merged

Fix issue #5210: Adding Menus.removeMenu() and Menus.getAllMenus() #5217

merged 3 commits into from
Sep 17, 2013

Conversation

lkcampbell
Copy link
Contributor

Fix issue #5210: Adding Menus.removeMenu() and Menus.getAllMenus()

@lkcampbell
Copy link
Contributor Author

I ended up adding in another method, Menus.getAllMenus(), because I needed it to iterate though all menus for issue #5078.

In order to run the unit tests for the HTML version of removeMenu(), a couple of temporary changes need to be made.

In src/utils/Global.js, set global.brackets.nativeMenus = false. This forces the HTML menus to turn on.

In test/spec/Menu-test.js, find the following code and comment it out:

        if (!brackets.inBrowser) {
            return;
        }

Doing this assures that the HTML menu unit tests are run. Note that the last five unit tests, which look at context menus, will still fail. Regardless, you can confirm that there are no failures in any of the other tests, including the new removeMenu tests.

@JeffryBooher
Copy link
Contributor

I ran the unit tests for this with the dark shell and they all still passed. @lkcampbell you should build the dark shell and make sure it behaves as expected.

@lkcampbell
Copy link
Contributor Author

@JeffryBooher, agreed. I would like to test the functionality on the dark shell before we consider merging this PR. My schedule is a bit hectic this week so I'm not 100% sure I will have the time to do a build. If that is the case, I can test it on the next Sprint and we can merge this PR then.

@ghost ghost assigned JeffryBooher Sep 16, 2013
@lkcampbell
Copy link
Contributor Author

@JeffryBooher, I did a build of brackets-shell today and removeMenu() is working correctly with the dark shell.

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

Successfully merging this pull request may close these issues.

2 participants