@@ -25,8 +25,6 @@ ifeq ($(ARCH), win) | |||||
TARGET = plugin.dll | TARGET = plugin.dll | ||||
endif | endif | ||||
DISTRIBUTABLES += $(TARGET) | |||||
all: $(TARGET) | all: $(TARGET) | ||||
@@ -38,7 +36,12 @@ clean: | |||||
dist: all | dist: all | ||||
rm -rf dist | rm -rf dist | ||||
mkdir -p dist/$(SLUG) | mkdir -p dist/$(SLUG) | ||||
# Strip and copy plugin binary | |||||
cp $(TARGET) dist/$(SLUG)/ | |||||
strip -s dist/$(SLUG)/$(TARGET) | |||||
# Copy distributables | |||||
cp -R $(DISTRIBUTABLES) dist/$(SLUG)/ | cp -R $(DISTRIBUTABLES) dist/$(SLUG)/ | ||||
# Create ZIP package | |||||
cd dist && zip -5 -r $(SLUG)-$(VERSION)-$(ARCH).zip $(SLUG) | cd dist && zip -5 -r $(SLUG)-$(VERSION)-$(ARCH).zip $(SLUG) | ||||
.PHONY: clean dist | .PHONY: clean dist |
@@ -164,6 +164,8 @@ struct ModelItem : BrowserListItem { | |||||
void onAction(EventAction &e) override { | void onAction(EventAction &e) override { | ||||
ModuleWidget *moduleWidget = model->createModuleWidget(); | ModuleWidget *moduleWidget = model->createModuleWidget(); | ||||
if (!moduleWidget) | |||||
return; | |||||
gRackWidget->moduleContainer->addChild(moduleWidget); | gRackWidget->moduleContainer->addChild(moduleWidget); | ||||
// Move module nearest to the mouse position | // Move module nearest to the mouse position | ||||
moduleWidget->box.pos = gRackWidget->lastMousePos.minus(moduleWidget->box.size.div(2)); | moduleWidget->box.pos = gRackWidget->lastMousePos.minus(moduleWidget->box.size.div(2)); | ||||