Browse Source

Add metadata to Core plugin

tags/v1.0.0
Andrew Belt 6 years ago
parent
commit
481ef40fa7
3 changed files with 37 additions and 2 deletions
  1. +35
    -0
      src/Core/Core.cpp
  2. +1
    -1
      src/app/ModuleWidget.cpp
  3. +1
    -1
      src/plugin.cpp

+ 35
- 0
src/Core/Core.cpp View File

@@ -4,12 +4,47 @@
void init(rack::Plugin *p) { void init(rack::Plugin *p) {
p->slug = "Core"; p->slug = "Core";
p->version = TOSTRING(VERSION); p->version = TOSTRING(VERSION);
p->name = "Core";
p->author = "VCV";
p->license = "LGPL-3.0-only and BSD-3-Clause";
p->authorEmail = "contact@vcvrack.com";
p->pluginUrl = "https://vcvrack.com/";
p->authorUrl = "https://vcvrack.com/";
p->manualUrl = "https://vcvrack.com/manual/Core.html";
p->sourceUrl = "https://github.com/VCVRack/Rack";


modelAudioInterface->name = "Audio";
modelAudioInterface->description = "";
modelAudioInterface->tags = {"External"};
p->addModel(modelAudioInterface); p->addModel(modelAudioInterface);

modelMIDIToCVInterface->name = "MIDI-1";
modelMIDIToCVInterface->description = "";
modelMIDIToCVInterface->tags = {"External", "MIDI"};
p->addModel(modelMIDIToCVInterface); p->addModel(modelMIDIToCVInterface);

modelQuadMIDIToCVInterface->name = "MIDI-4";
modelQuadMIDIToCVInterface->description = "";
modelQuadMIDIToCVInterface->tags = {"External", "MIDI", "Quad"};
p->addModel(modelQuadMIDIToCVInterface); p->addModel(modelQuadMIDIToCVInterface);

modelMIDICCToCVInterface->name = "MIDI-CC";
modelMIDICCToCVInterface->description = "";
modelMIDICCToCVInterface->tags = {"External", "MIDI"};
p->addModel(modelMIDICCToCVInterface); p->addModel(modelMIDICCToCVInterface);

modelMIDITriggerToCVInterface->name = "MIDI-Trig";
modelMIDITriggerToCVInterface->description = "";
modelMIDITriggerToCVInterface->tags = {"External", "MIDI"};
p->addModel(modelMIDITriggerToCVInterface); p->addModel(modelMIDITriggerToCVInterface);

modelBlank->name = "Blank";
modelBlank->description = "";
modelBlank->tags = {"Blank"};
p->addModel(modelBlank); p->addModel(modelBlank);

modelNotes->name = "Notes";
modelNotes->description = "";
modelNotes->tags = {"Blank"};
p->addModel(modelNotes); p->addModel(modelNotes);
} }

+ 1
- 1
src/app/ModuleWidget.cpp View File

@@ -500,7 +500,7 @@ Menu *ModuleWidget::createContextMenu() {
Menu *menu = createMenu(); Menu *menu = createMenu();


MenuLabel *menuLabel = new MenuLabel; MenuLabel *menuLabel = new MenuLabel;
menuLabel->text = model->plugin->author + " " + model->name + " " + model->plugin->version;
menuLabel->text = model->plugin->name + " " + model->name + " " + model->plugin->version;
menu->addChild(menuLabel); menu->addChild(menuLabel);


ModuleResetItem *resetItem = new ModuleResetItem; ModuleResetItem *resetItem = new ModuleResetItem;


+ 1
- 1
src/plugin.cpp View File

@@ -111,8 +111,8 @@ static bool loadPlugin(std::string path) {
Plugin *plugin = new Plugin; Plugin *plugin = new Plugin;
plugin->path = path; plugin->path = path;
plugin->handle = handle; plugin->handle = handle;
initCallback(plugin);
plugin->fromJson(rootJ); plugin->fromJson(rootJ);
initCallback(plugin);


// Reject plugin if slug already exists // Reject plugin if slug already exists
Plugin *oldPlugin = getPlugin(plugin->slug); Plugin *oldPlugin = getPlugin(plugin->slug);


Loading…
Cancel
Save