Hi, I just found out something odd about Introjucer. When I try to delete the following code in the Introjucer, it always freezes (not responding) and I need to force-end-process it.
It is slightly modified text from the plugin demo (and commented out) which I have pasted to a new project, but that doesn't matter. I don't know whether it is because of it being to long or commented or whatever. I just needed to do it like 7 times until I found out that it this action that makes it crash.
//I would also expect that the "Save all" option saves ALL, but apparently it doesn't. Introjucer project has to be saved independently.
//StringArray exampleJUCEApplication::MainWindow::getMenuBarNames() //{ // const char* const names[] = { "File", "Plugins", "Options", nullptr }; // // return StringArray(names); //} // //PopupMenu exampleJUCEApplication::MainWindow::getMenuForIndex(int topLevelMenuIndex, const String& /*menuName*/) //{ // PopupMenu menu; // // if (topLevelMenuIndex == 0) // { // "File" menu // menu.addCommandItem(&getCommandManager(), CommandIDs::open); // // RecentlyOpenedFilesList recentFiles; // recentFiles.restoreFromString(getAppProperties().getUserSettings() // ->getValue("recentFilterGraphFiles")); // // PopupMenu recentFilesMenu; // recentFiles.createPopupMenuItems(recentFilesMenu, 100, true, true); // menu.addSubMenu("Open recent file", recentFilesMenu); // // menu.addCommandItem(&getCommandManager(), CommandIDs::save); // menu.addCommandItem(&getCommandManager(), CommandIDs::saveAs); // menu.addSeparator(); // menu.addCommandItem(&getCommandManager(), StandardApplicationCommandIDs::quit); // } // else if (topLevelMenuIndex == 1) // { // "Plugins" menu // PopupMenu pluginsMenu; // addPluginsToMenu(pluginsMenu); // menu.addSubMenu("Create plugin", pluginsMenu); // menu.addSeparator(); // menu.addItem(250, "Delete all plugins"); // } // else if (topLevelMenuIndex == 2) // { // "Options" menu // // menu.addCommandItem(&getCommandManager(), CommandIDs::showPluginListEditor); // // PopupMenu sortTypeMenu; // sortTypeMenu.addItem(200, "List plugins in default order", true, pluginSortMethod == KnownPluginList::defaultOrder); // sortTypeMenu.addItem(201, "List plugins in alphabetical order", true, pluginSortMethod == KnownPluginList::sortAlphabetically); // sortTypeMenu.addItem(202, "List plugins by category", true, pluginSortMethod == KnownPluginList::sortByCategory); // sortTypeMenu.addItem(203, "List plugins by manufacturer", true, pluginSortMethod == KnownPluginList::sortByManufacturer); // sortTypeMenu.addItem(204, "List plugins based on the directory structure", true, pluginSortMethod == KnownPluginList::sortByFileSystemLocation); // menu.addSubMenu("Plugin menu type", sortTypeMenu); // // menu.addSeparator(); // menu.addCommandItem(&getCommandManager(), CommandIDs::showAudioSettings); // // menu.addSeparator(); // menu.addCommandItem(&getCommandManager(), CommandIDs::aboutBox); // } // // return menu; //} // //void exampleJUCEApplication::MainWindow::menuItemSelected(int menuItemID, int /*topLevelMenuIndex*/) //{ // GraphDocumentComponent* const graphEditor = getGraphEditor(); // // if (menuItemID == 250) // { // if (graphEditor != nullptr) // graphEditor->graph.clear(); // } // else if (menuItemID >= 100 && menuItemID < 200) // { // RecentlyOpenedFilesList recentFiles; // recentFiles.restoreFromString(getAppProperties().getUserSettings() // ->getValue("recentFilterGraphFiles")); // // if (graphEditor != nullptr && graphEditor->graph.saveIfNeededAndUserAgrees() == FileBasedDocument::savedOk) // graphEditor->graph.loadFrom(recentFiles.getFile(menuItemID - 100), true); // } // else if (menuItemID >= 200 && menuItemID < 210) // { // if (menuItemID == 200) pluginSortMethod = KnownPluginList::defaultOrder; // else if (menuItemID == 201) pluginSortMethod = KnownPluginList::sortAlphabetically; // else if (menuItemID == 202) pluginSortMethod = KnownPluginList::sortByCategory; // else if (menuItemID == 203) pluginSortMethod = KnownPluginList::sortByManufacturer; // else if (menuItemID == 204) pluginSortMethod = KnownPluginList::sortByFileSystemLocation; // // getAppProperties().getUserSettings()->setValue("pluginSortMethod", (int)pluginSortMethod); // // menuItemsChanged(); // } // else // { // createPlugin(getChosenType(menuItemID), // proportionOfWidth(0.3f + Random::getSystemRandom().nextFloat() * 0.6f), // proportionOfHeight(0.3f + Random::getSystemRandom().nextFloat() * 0.6f)); // } //}