Browse Source

Associate .vcv file type on Mac

tags/v1.0.0
Andrew Belt 5 years ago
parent
commit
bc85e959fd
4 changed files with 29 additions and 2 deletions
  1. +2
    -1
      .gitmodules
  2. +20
    -0
      Info.plist
  3. +1
    -1
      dep/glfw
  4. +6
    -0
      src/main.cpp

+ 2
- 1
.gitmodules View File

@@ -12,7 +12,8 @@
url = https://github.com/AndrewBelt/oui-blendish.git url = https://github.com/AndrewBelt/oui-blendish.git
[submodule "dep/glfw"] [submodule "dep/glfw"]
path = dep/glfw path = dep/glfw
url = https://github.com/glfw/glfw.git
url = https://github.com/AndrewBelt/glfw.git
branch = openedFilename
[submodule "dep/rtaudio"] [submodule "dep/rtaudio"]
path = dep/rtaudio path = dep/rtaudio
url = https://github.com/thestk/rtaudio.git url = https://github.com/thestk/rtaudio.git

+ 20
- 0
Info.plist View File

@@ -28,5 +28,25 @@
<string>NSApplication</string> <string>NSApplication</string>
<key>NSHighResolutionCapable</key> <key>NSHighResolutionCapable</key>
<string>YES</string> <string>YES</string>

<key>CFBundleDocumentTypes</key>
<array>
<dict>
<key>CFBundleTypeExtensions</key>
<array>
<string>vcv</string>
</array>
<key>CFBundleTypeIconFile</key>
<string>icon.icns</string>
<key>CFBundleTypeName</key>
<string>VCV Rack Patch</string>
<key>CFBundleTypeOSTypes</key>
<array>
<string>RACK</string>
</array>
<key>CFBundleTypeRole</key>
<string>Editor</string>
</dict>
</array>
</dict> </dict>
</plist> </plist>

+ 1
- 1
dep/glfw

@@ -1 +1 @@
Subproject commit 29d8ca4ce4aef8e0afca62b8ace9ee18a24a9ffd
Subproject commit 7ba23eb03854dfe6ce36cc6d61cb913f76cad774

+ 6
- 0
src/main.cpp View File

@@ -124,6 +124,12 @@ int main(int argc, char *argv[]) {
INFO("Initializing app"); INFO("Initializing app");
settings.load(asset::user("settings.json")); settings.load(asset::user("settings.json"));
appInit(headless); appInit(headless);

const char *openedFilename = glfwGetOpenedFilename();
if (openedFilename) {
patchPath = openedFilename;
}

if (!headless) { if (!headless) {
APP->scene->devMode = devMode; APP->scene->devMode = devMode;
APP->patch->init(patchPath); APP->patch->init(patchPath);


Loading…
Cancel
Save