Browse Source

Only show real LV2 instruments as synths; Cleanup

tags/1.9.5
falkTX 10 years ago
parent
commit
b8ed819c52
4 changed files with 9 additions and 8 deletions
  1. +5
    -5
      source/carla_host.py
  2. +1
    -1
      source/discovery/carla-discovery.cpp
  3. +1
    -0
      source/modules/lv2_rdf.hpp
  4. +2
    -2
      source/widgets/racklistwidget.py

+ 5
- 5
source/carla_host.py View File

@@ -68,7 +68,7 @@ NSM_URL = os.getenv("NSM_URL")
# ------------------------------------------------------------------------------------------------------------
# Host Window

class HostWindow(QMainWindow, PluginEditParentMeta):
class HostWindow(QMainWindow):
#class HostWindow(QMainWindow, PluginEditParentMeta, metaclass=PyQtMetaClass):
# signals
SIGTERM = pyqtSignal()
@@ -1578,7 +1578,7 @@ class HostWindow(QMainWindow, PluginEditParentMeta):
if pitem is None:
return None
#if False:
#pitem = CarlaRackItem(self, 0, False)
#return CarlaRackItem(self, 0, False)

return pitem

@@ -1589,8 +1589,8 @@ class HostWindow(QMainWindow, PluginEditParentMeta):
pitem = self.fPluginList[pluginId]
if pitem is None:
return None
#if False:
#pitem = CarlaRackItem(self, 0, False)
if False:
return PluginEdit(self, self.host, 0)

return pitem.getEditDialog()

@@ -1602,7 +1602,7 @@ class HostWindow(QMainWindow, PluginEditParentMeta):
if pitem is None:
return None
#if False:
#pitem = CarlaRackItem(self, 0, False)
#return AbstractPluginSlot()

return pitem.getWidget()



+ 1
- 1
source/discovery/carla-discovery.cpp View File

@@ -1112,7 +1112,7 @@ static void do_lv2_check(const char* const bundle, const bool doInit)
}
}

if (LV2_IS_GENERATOR(rdfDescriptor->Type[0], rdfDescriptor->Type[1]))
if (LV2_IS_INSTRUMENT(rdfDescriptor->Type[0], rdfDescriptor->Type[1]))
hints |= PLUGIN_IS_SYNTH;

if (rdfDescriptor->UICount > 0)


+ 1
- 0
source/modules/lv2_rdf.hpp View File

@@ -291,6 +291,7 @@ typedef uint32_t LV2_Property;
#define LV2_IS_EQ(x, y) ((x) & LV2_GROUP_EQ)
#define LV2_IS_FILTER(x, y) ((x) & LV2_GROUP_FILTER)
#define LV2_IS_GENERATOR(x, y) ((y) & LV2_GROUP_GENERATOR)
#define LV2_IS_INSTRUMENT(x, y) ((y) & LV2_PLUGIN_INSTRUMENT)
#define LV2_IS_MODULATOR(x, y) ((y) & LV2_GROUP_MODULATOR)
#define LV2_IS_REVERB(x, y) ((x) & LV2_GROUP_REVERB)
#define LV2_IS_SIMULATOR(x, y) ((x) & LV2_GROUP_SIMULATOR)


+ 2
- 2
source/widgets/racklistwidget.py View File

@@ -49,10 +49,10 @@ class RackListItem(QListWidgetItem):

if False:
# kdevelop likes this :)
from carla_backend import CarlaHostMeta
parent = RackListWidget()
host = CarlaHostMeta()
self.host = host
self.fWidget = AbstractPluginSlot()

# ----------------------------------------------------------------------------------------------------
# Internal stuff
@@ -103,7 +103,7 @@ class RackListItem(QListWidgetItem):
self.fWidget = createPluginSlot(self.fParent, self.host, self.fPluginId, self.fUseSkins)
self.fWidget.setFixedHeight(self.fWidget.getFixedHeight())

self.setSizeHint(QSize(640, self.fWidget.getFixedHeight()))
self.setSizeHint(QSize(700, self.fWidget.getFixedHeight()))

self.fParent.setItemWidget(self, self.fWidget)



Loading…
Cancel
Save