Ignore keyboard MIDI driver
This commit is contained in:
parent
27aa1e94d9
commit
9bc002577e
3 changed files with 3 additions and 19 deletions
|
|
@ -109,7 +109,6 @@ struct Initializer {
|
||||||
INFO("Initializing environment");
|
INFO("Initializing environment");
|
||||||
audio::init();
|
audio::init();
|
||||||
midi::init();
|
midi::init();
|
||||||
keyboard::init();
|
|
||||||
plugin::init();
|
plugin::init();
|
||||||
library::init();
|
library::init();
|
||||||
ui::init();
|
ui::init();
|
||||||
|
|
|
||||||
|
|
@ -47,7 +47,7 @@ endif
|
||||||
|
|
||||||
FILES_DSP += $(wildcard Rack/src/*.c)
|
FILES_DSP += $(wildcard Rack/src/*.c)
|
||||||
FILES_DSP += $(wildcard Rack/src/*/*.c)
|
FILES_DSP += $(wildcard Rack/src/*/*.c)
|
||||||
FILES_DSP += $(filter-out Rack/src/dep.cpp Rack/src/discord.cpp Rack/src/gamepad.cpp Rack/src/network.cpp Rack/src/rtaudio.cpp Rack/src/rtmidi.cpp, $(wildcard Rack/src/*.cpp))
|
FILES_DSP += $(filter-out Rack/src/dep.cpp Rack/src/discord.cpp Rack/src/gamepad.cpp Rack/src/keyboard.cpp Rack/src/network.cpp Rack/src/rtaudio.cpp Rack/src/rtmidi.cpp, $(wildcard Rack/src/*.cpp))
|
||||||
FILES_DSP += $(filter-out Rack/src/window/Window.cpp, $(wildcard Rack/src/*/*.cpp))
|
FILES_DSP += $(filter-out Rack/src/window/Window.cpp, $(wildcard Rack/src/*/*.cpp))
|
||||||
|
|
||||||
EXTRA_DEPENDENCIES += Rack/dep/lib/libjansson.a
|
EXTRA_DEPENDENCIES += Rack/dep/lib/libjansson.a
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,6 @@
|
||||||
#include <asset.hpp>
|
#include <asset.hpp>
|
||||||
#include <widget/Widget.hpp>
|
#include <widget/Widget.hpp>
|
||||||
#include <app/Scene.hpp>
|
#include <app/Scene.hpp>
|
||||||
#include <keyboard.hpp>
|
|
||||||
#include <context.hpp>
|
#include <context.hpp>
|
||||||
#include <patch.hpp>
|
#include <patch.hpp>
|
||||||
#include <settings.hpp>
|
#include <settings.hpp>
|
||||||
|
|
@ -395,10 +394,6 @@ void cursorPosCallback(Context* ctx, double xpos, double ypos) {
|
||||||
ctx->window->internal->lastMousePos = mousePos;
|
ctx->window->internal->lastMousePos = mousePos;
|
||||||
|
|
||||||
ctx->event->handleHover(mousePos, mouseDelta);
|
ctx->event->handleHover(mousePos, mouseDelta);
|
||||||
|
|
||||||
// Keyboard/mouse MIDI driver
|
|
||||||
math::Vec scaledPos(xpos / ctx->window->internal->ui->getWidth(), ypos / ctx->window->internal->ui->getHeight());
|
|
||||||
keyboard::mouseMove(scaledPos);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void cursorEnterCallback(Context* ctx, int entered) {
|
void cursorEnterCallback(Context* ctx, int entered) {
|
||||||
|
|
@ -419,21 +414,11 @@ void scrollCallback(Context* ctx, double x, double y) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void charCallback(Context* ctx, unsigned int codepoint) {
|
void charCallback(Context* ctx, unsigned int codepoint) {
|
||||||
if (ctx->event->handleText(ctx->window->internal->lastMousePos, codepoint))
|
ctx->event->handleText(ctx->window->internal->lastMousePos, codepoint);
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void keyCallback(Context* ctx, int key, int scancode, int action, int mods) {
|
void keyCallback(Context* ctx, int key, int scancode, int action, int mods) {
|
||||||
if (ctx->event->handleKey(ctx->window->internal->lastMousePos, key, scancode, action, mods))
|
ctx->event->handleKey(ctx->window->internal->lastMousePos, key, scancode, action, mods);
|
||||||
return;
|
|
||||||
|
|
||||||
// Keyboard/mouse MIDI driver
|
|
||||||
if (action == GLFW_PRESS && (mods & RACK_MOD_MASK) == 0) {
|
|
||||||
keyboard::press(key);
|
|
||||||
}
|
|
||||||
if (action == GLFW_RELEASE) {
|
|
||||||
keyboard::release(key);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue