| @@ -174,13 +174,13 @@ public: | |||||
| setApplicationCommandManagerToWatch (commandManager); | setApplicationCommandManagerToWatch (commandManager); | ||||
| } | } | ||||
| const StringArray getMenuBarNames() | |||||
| StringArray getMenuBarNames() | |||||
| { | { | ||||
| const char* const names[] = { "File", "Edit", "View", "Window", "Tools", 0 }; | const char* const names[] = { "File", "Edit", "View", "Window", "Tools", 0 }; | ||||
| return StringArray ((const char**) names); | return StringArray ((const char**) names); | ||||
| } | } | ||||
| const PopupMenu getMenuForIndex (int topLevelMenuIndex, const String& /*menuName*/) | |||||
| PopupMenu getMenuForIndex (int topLevelMenuIndex, const String& /*menuName*/) | |||||
| { | { | ||||
| PopupMenu menu; | PopupMenu menu; | ||||
| @@ -64,14 +64,14 @@ public: | |||||
| } | } | ||||
| //============================================================================== | //============================================================================== | ||||
| const StringArray getMenuBarNames() | |||||
| StringArray getMenuBarNames() | |||||
| { | { | ||||
| const char* const names[] = { "Demo", "Look-and-feel", nullptr }; | const char* const names[] = { "Demo", "Look-and-feel", nullptr }; | ||||
| return StringArray (names); | return StringArray (names); | ||||
| } | } | ||||
| const PopupMenu getMenuForIndex (int menuIndex, const String& /*menuName*/) | |||||
| PopupMenu getMenuForIndex (int menuIndex, const String& /*menuName*/) | |||||
| { | { | ||||
| ApplicationCommandManager* commandManager = &(mainWindow.commandManager); | ApplicationCommandManager* commandManager = &(mainWindow.commandManager); | ||||
| @@ -164,14 +164,14 @@ void MainHostWindow::changeListenerCallback (ChangeBroadcaster*) | |||||
| } | } | ||||
| } | } | ||||
| const StringArray MainHostWindow::getMenuBarNames() | |||||
| StringArray MainHostWindow::getMenuBarNames() | |||||
| { | { | ||||
| const char* const names[] = { "File", "Plugins", "Options", nullptr }; | const char* const names[] = { "File", "Plugins", "Options", nullptr }; | ||||
| return StringArray (names); | return StringArray (names); | ||||
| } | } | ||||
| const PopupMenu MainHostWindow::getMenuForIndex (int topLevelMenuIndex, const String& /*menuName*/) | |||||
| PopupMenu MainHostWindow::getMenuForIndex (int topLevelMenuIndex, const String& /*menuName*/) | |||||
| { | { | ||||
| PopupMenu menu; | PopupMenu menu; | ||||
| @@ -68,8 +68,8 @@ public: | |||||
| void fileDragExit (const StringArray& files); | void fileDragExit (const StringArray& files); | ||||
| void filesDropped (const StringArray& files, int, int); | void filesDropped (const StringArray& files, int, int); | ||||
| const StringArray getMenuBarNames(); | |||||
| const PopupMenu getMenuForIndex (int topLevelMenuIndex, const String& menuName); | |||||
| StringArray getMenuBarNames(); | |||||
| PopupMenu getMenuForIndex (int topLevelMenuIndex, const String& menuName); | |||||
| void menuItemSelected (int menuItemID, int topLevelMenuIndex); | void menuItemSelected (int menuItemID, int topLevelMenuIndex); | ||||
| ApplicationCommandTarget* getNextCommandTarget(); | ApplicationCommandTarget* getNextCommandTarget(); | ||||
| void getAllCommands (Array <CommandID>& commands); | void getAllCommands (Array <CommandID>& commands); | ||||
| @@ -183,7 +183,7 @@ private: | |||||
| .replaceCharacter ('\\', '/')); | .replaceCharacter ('\\', '/')); | ||||
| } | } | ||||
| const File getFile() const | |||||
| File getFile() const | |||||
| { | { | ||||
| return component->findFile(); | return component->findFile(); | ||||
| } | } | ||||
| @@ -987,7 +987,7 @@ private: | |||||
| "Change tab component file"); | "Change tab component file"); | ||||
| } | } | ||||
| const File getFile() const | |||||
| File getFile() const | |||||
| { | { | ||||
| return document.getFile().getSiblingFile (getTabJucerFile (component, tabIndex)); | return document.getFile().getSiblingFile (getTabJucerFile (component, tabIndex)); | ||||
| } | } | ||||
| @@ -507,12 +507,11 @@ private: | |||||
| { | { | ||||
| document.perform (new JucerCompFileChangeAction (component, *document.getComponentLayout(), | document.perform (new JucerCompFileChangeAction (component, *document.getComponentLayout(), | ||||
| newFile.getRelativePathFrom (document.getFile().getParentDirectory()) | newFile.getRelativePathFrom (document.getFile().getParentDirectory()) | ||||
| .replaceCharacter ('\\', '/') | |||||
| ), | |||||
| .replaceCharacter ('\\', '/')), | |||||
| "Change Jucer component file"); | "Change Jucer component file"); | ||||
| } | } | ||||
| const File getFile() const | |||||
| File getFile() const | |||||
| { | { | ||||
| const String filename (getViewportJucerComponentFile (component)); | const String filename (getViewportJucerComponentFile (component)); | ||||
| @@ -36,16 +36,16 @@ class FilePropertyComponent : public PropertyComponent, | |||||
| public: | public: | ||||
| //============================================================================== | //============================================================================== | ||||
| FilePropertyComponent (const String& name, | FilePropertyComponent (const String& name, | ||||
| const bool isDirectory, | |||||
| const bool allowEditingOfFilename, | |||||
| const String& fileBrowserWildcard = "*"); | |||||
| const bool isDirectory, | |||||
| const bool allowEditingOfFilename, | |||||
| const String& fileBrowserWildcard = "*"); | |||||
| ~FilePropertyComponent(); | ~FilePropertyComponent(); | ||||
| //============================================================================== | //============================================================================== | ||||
| virtual void setFile (const File& newFile) = 0; | virtual void setFile (const File& newFile) = 0; | ||||
| virtual const File getFile() const = 0; | |||||
| virtual File getFile() const = 0; | |||||
| //============================================================================== | //============================================================================== | ||||
| void refresh(); | void refresh(); | ||||
| @@ -223,15 +223,15 @@ void MainWindow::activeWindowStatusChanged() | |||||
| } | } | ||||
| //============================================================================== | //============================================================================== | ||||
| const StringArray MainWindow::getMenuBarNames() | |||||
| StringArray MainWindow::getMenuBarNames() | |||||
| { | { | ||||
| const char* const names[] = { "File", "Edit", "View", 0 }; | const char* const names[] = { "File", "Edit", "View", 0 }; | ||||
| return StringArray (names); | return StringArray (names); | ||||
| } | } | ||||
| const PopupMenu MainWindow::getMenuForIndex (int topLevelMenuIndex, | |||||
| const String& menuName) | |||||
| PopupMenu MainWindow::getMenuForIndex (int topLevelMenuIndex, | |||||
| const String& menuName) | |||||
| { | { | ||||
| PopupMenu menu; | PopupMenu menu; | ||||
| @@ -111,15 +111,15 @@ public: | |||||
| //============================================================================== | //============================================================================== | ||||
| /** This method must return a list of the names of the menus. */ | /** This method must return a list of the names of the menus. */ | ||||
| virtual const StringArray getMenuBarNames() = 0; | |||||
| virtual StringArray getMenuBarNames() = 0; | |||||
| /** This should return the popup menu to display for a given top-level menu. | /** This should return the popup menu to display for a given top-level menu. | ||||
| @param topLevelMenuIndex the index of the top-level menu to show | @param topLevelMenuIndex the index of the top-level menu to show | ||||
| @param menuName the name of the top-level menu item to show | @param menuName the name of the top-level menu item to show | ||||
| */ | */ | ||||
| virtual const PopupMenu getMenuForIndex (int topLevelMenuIndex, | |||||
| const String& menuName) = 0; | |||||
| virtual PopupMenu getMenuForIndex (int topLevelMenuIndex, | |||||
| const String& menuName) = 0; | |||||
| /** This is called when a menu item has been clicked on. | /** This is called when a menu item has been clicked on. | ||||