1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-02-05 03:50:07 +00:00

Introjucer: minor refactoring.

This commit is contained in:
jules 2013-08-04 17:53:56 +01:00
parent 711764103e
commit 127342e147
15 changed files with 55 additions and 34 deletions

View file

@ -57,14 +57,16 @@ public:
tree.getRootItem()->setSelected (true, true);
#if JUCE_MAC || JUCE_WINDOWS
ApplicationCommandManager& commandManager = IntrojucerApp::getCommandManager();
addAndMakeVisible (&openProjectButton);
openProjectButton.setCommandToTrigger (commandManager, CommandIDs::openInIDE, true);
openProjectButton.setButtonText (commandManager->getNameOfCommand (CommandIDs::openInIDE));
openProjectButton.setCommandToTrigger (&commandManager, CommandIDs::openInIDE, true);
openProjectButton.setButtonText (commandManager.getNameOfCommand (CommandIDs::openInIDE));
openProjectButton.setColour (TextButton::buttonColourId, Colours::white.withAlpha (0.5f));
addAndMakeVisible (&saveAndOpenButton);
saveAndOpenButton.setCommandToTrigger (commandManager, CommandIDs::saveAndOpenInIDE, true);
saveAndOpenButton.setButtonText (commandManager->getNameOfCommand (CommandIDs::saveAndOpenInIDE));
saveAndOpenButton.setCommandToTrigger (&commandManager, CommandIDs::saveAndOpenInIDE, true);
saveAndOpenButton.setButtonText (commandManager.getNameOfCommand (CommandIDs::saveAndOpenInIDE));
saveAndOpenButton.setColour (TextButton::buttonColourId, Colours::white.withAlpha (0.5f));
#endif
}
@ -374,7 +376,7 @@ void ProjectContentComponent::hideEditor()
currentDocument = nullptr;
contentView = nullptr;
updateMainWindowTitle();
commandManager->commandStatusChanged();
IntrojucerApp::getCommandManager().commandStatusChanged();
resized();
}
@ -401,7 +403,7 @@ bool ProjectContentComponent::setEditorComponent (Component* editor,
resized();
updateMainWindowTitle();
commandManager->commandStatusChanged();
IntrojucerApp::getCommandManager().commandStatusChanged();
return true;
}