diff --git a/Source/MainComponent.cpp b/Source/MainComponent.cpp index b6a5a3f..b1fcba5 100644 --- a/Source/MainComponent.cpp +++ b/Source/MainComponent.cpp @@ -420,8 +420,8 @@ void MainContentComponent::resized() resizeLabelWithHeight(lblAppVersion.get(), roundToInt(lblAppName->getHeight() * 0.75f)); lblAppVersion->setTopLeftPosition(lblAppName->getRight(), lblAppName->getBottom() - lblAppVersion->getHeight()); - // resizeLabelWithHeight(lblFirmwareVersion.get(), btnHeight * 0.6f); - lblFirmwareVersion->setBounds(allKeysOverview->getX(), allKeysOverview->getBottom(), btnHeight * 0.6f, contentWidth); + juce::Rectangle lumatoneBounds = allKeysOverview->getLocalGraphicBounds().translated(allKeysOverview->getX(), allKeysOverview->getY()); + lblFirmwareVersion->setBounds(lumatoneBounds.getX(), lumatoneBounds.getBottom(), contentWidth, btnHeight * 0.7f); } void MainContentComponent::resizeEditSectionTabs() @@ -455,5 +455,7 @@ void MainContentComponent::handleStatePropertyChange(juce::ValueTree stateIn, co { auto string = juce::String("Firmware version: " + getFirmwareVersion().toDisplayString()); lblFirmwareVersion->setText(string, juce::NotificationType::sendNotification); + + requestDeviceGlobalSettings(); } } diff --git a/Source/lumatone_editor_library/ui/keyboard_component.cpp b/Source/lumatone_editor_library/ui/keyboard_component.cpp index cf4e1f3..68b3f16 100644 --- a/Source/lumatone_editor_library/ui/keyboard_component.cpp +++ b/Source/lumatone_editor_library/ui/keyboard_component.cpp @@ -187,6 +187,11 @@ void LumatoneKeyboardComponent::setUiMode(LumatoneKeyboardComponent::UiMode mode uiMode = modeIn; } +juce::Rectangle LumatoneKeyboardComponent::getLocalGraphicBounds() const +{ + return lumatoneBounds; +} + void LumatoneKeyboardComponent::layoutChanged(const LumatoneLayout& mappingData) { for (int boardIndex = 0; boardIndex < octaveBoards.size(); boardIndex++) diff --git a/Source/lumatone_editor_library/ui/keyboard_component.h b/Source/lumatone_editor_library/ui/keyboard_component.h index 33a2979..e4ba7b4 100644 --- a/Source/lumatone_editor_library/ui/keyboard_component.h +++ b/Source/lumatone_editor_library/ui/keyboard_component.h @@ -78,6 +78,10 @@ class LumatoneKeyboardComponent : public juce::Component, LumatoneKeyboardComponent::UiMode getUiMode() const { return uiMode; } void setUiMode(LumatoneKeyboardComponent::UiMode modeIn); +public: + + juce::Rectangle getLocalGraphicBounds() const; + public: // LumatoneEditor::EditorListener Implementation void layoutChanged(const LumatoneLayout& mappingData) override;