Show plugin UIs in Route Property Box

This commit is contained in:
Robin Gareus 2024-11-19 17:20:57 +01:00
parent 49c7464b9c
commit 2a620c64e9
No known key found for this signature in database
GPG key ID: A090BCE02CF57F04
2 changed files with 130 additions and 39 deletions

View file

@ -1,6 +1,7 @@
/*
* Copyright (C) 2021 Paul Davis <paul@linuxaudiosystems.com>
* Copyright (C) 2024 Ben Loftis <ben@harrisonconsoles.com>
* Copyright (C) 2024 Robin Gareus <robin@gareus.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -19,44 +20,45 @@
#pragma once
#include <map>
#include <vector>
#include <gtkmm/box.h>
#include <gtkmm/label.h>
#include <gtkmm/table.h>
#include <gtkmm/scrolledwindow.h>
#include "ardour/ardour.h"
#include "ardour/session_handle.h"
#include "widgets/ardour_button.h"
#include "gtkmm2ext/cairo_packer.h"
#include "region_editor.h"
#include "audio_clock.h"
namespace ARDOUR
{
namespace ARDOUR {
class Route;
class Processor;
class Session;
class Location;
}
class GenericPluginUI;
class RoutePropertiesBox : public Gtk::HBox, public ARDOUR::SessionHandlePtr
{
public:
RoutePropertiesBox ();
~RoutePropertiesBox ();
virtual void set_route (std::shared_ptr<ARDOUR::Route>);
protected:
std::shared_ptr<ARDOUR::Region> _route;
Gtk::Label _header_label;
void set_route (std::shared_ptr<ARDOUR::Route>);
private:
void property_changed (const PBD::PropertyChange& what_changed);
void session_going_away ();
void drop_route ();
void drop_plugin_uis ();
void refill_processors ();
void add_processor_to_display (std::weak_ptr<ARDOUR::Processor> w);
PBD::ScopedConnection state_connection;
Gtk::ScrolledWindow _scroller;
Gtk::HBox _box;
std::shared_ptr<ARDOUR::Route> _route;
std::vector <GenericPluginUI*> _proc_uis;
PBD::ScopedConnectionList _processor_connections;
PBD::ScopedConnectionList _route_connections;
};