mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-09 20:29:10 +02:00
Move generic logger on the Wine side to common.h
We'll also need this for VST2 plugins when we start caching the time info.
This commit is contained in:
@@ -19,7 +19,7 @@
|
|||||||
#include "../editor.h"
|
#include "../editor.h"
|
||||||
|
|
||||||
HostBridge::HostBridge(boost::filesystem::path plugin_path)
|
HostBridge::HostBridge(boost::filesystem::path plugin_path)
|
||||||
: plugin_path(plugin_path) {}
|
: plugin_path(plugin_path), generic_logger(Logger::create_wine_stderr()) {}
|
||||||
|
|
||||||
void HostBridge::handle_win32_events() {
|
void HostBridge::handle_win32_events() {
|
||||||
MSG msg;
|
MSG msg;
|
||||||
|
|||||||
@@ -20,6 +20,8 @@
|
|||||||
|
|
||||||
#include <boost/filesystem.hpp>
|
#include <boost/filesystem.hpp>
|
||||||
|
|
||||||
|
#include "../../common/logging/common.h"
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The base for the Wine plugin host bridge interface for all plugin types. This
|
* The base for the Wine plugin host bridge interface for all plugin types. This
|
||||||
* only has to be able to handle Win32 and X11 events. Implementations of this
|
* only has to be able to handle Win32 and X11 events. Implementations of this
|
||||||
@@ -87,4 +89,14 @@ class HostBridge {
|
|||||||
* The path to the .dll being loaded in the Wine plugin host.
|
* The path to the .dll being loaded in the Wine plugin host.
|
||||||
*/
|
*/
|
||||||
const boost::filesystem::path plugin_path;
|
const boost::filesystem::path plugin_path;
|
||||||
|
|
||||||
|
protected:
|
||||||
|
/**
|
||||||
|
* A logger, just like we have on the plugin side. This is normally not
|
||||||
|
* needed because we can just print to STDERR, but this way we can
|
||||||
|
* conditionally hide output based on the verbosity level.
|
||||||
|
*
|
||||||
|
* @see Logger::create_wine_stderr
|
||||||
|
*/
|
||||||
|
Logger generic_logger;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -91,7 +91,6 @@ Vst3Bridge::Vst3Bridge(MainContext& main_context,
|
|||||||
std::string plugin_dll_path,
|
std::string plugin_dll_path,
|
||||||
std::string endpoint_base_dir)
|
std::string endpoint_base_dir)
|
||||||
: HostBridge(plugin_dll_path),
|
: HostBridge(plugin_dll_path),
|
||||||
generic_logger(Logger::create_wine_stderr()),
|
|
||||||
logger(generic_logger),
|
logger(generic_logger),
|
||||||
main_context(main_context),
|
main_context(main_context),
|
||||||
sockets(main_context.context, endpoint_base_dir, false) {
|
sockets(main_context.context, endpoint_base_dir, false) {
|
||||||
|
|||||||
@@ -361,9 +361,6 @@ class Vst3Bridge : public HostBridge {
|
|||||||
void unregister_context_menu(size_t object_instance_id,
|
void unregister_context_menu(size_t object_instance_id,
|
||||||
size_t context_menu_id);
|
size_t context_menu_id);
|
||||||
|
|
||||||
private:
|
|
||||||
Logger generic_logger;
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
/**
|
/**
|
||||||
* A logger instance we'll use to log about failed
|
* A logger instance we'll use to log about failed
|
||||||
|
|||||||
Reference in New Issue
Block a user