Browse Source

More tweaks to add-jack dialog

Signed-off-by: falkTX <falktx@gmail.com>
pull/829/head
falkTX 7 years ago
parent
commit
4b4aeedc32
Signed by: falkTX <falktx@gmail.com> GPG Key ID: 2D3445A829213837
2 changed files with 117 additions and 34 deletions
  1. +113
    -27
      resources/ui/carla_add_jack.ui
  2. +4
    -7
      source/frontend/carla_database.py

+ 113
- 27
resources/ui/carla_add_jack.ui View File

@@ -27,39 +27,23 @@
<string>Application</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="1" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Command:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="1" colspan="3">
<widget class="QLineEdit" name="le_command"/>
</item>
<item row="2" column="3">
<spacer name="horizontalSpacer_3">
<item row="0" column="0" rowspan="3">
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Ignored</enum>
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>87</width>
<height>1</height>
<width>20</width>
<height>60</height>
</size>
</property>
</spacer>
</item>
<item row="0" column="1" colspan="3">
<widget class="QLineEdit" name="le_name"/>
</item>
<item row="0" column="0">
<item row="0" column="1">
<widget class="QLabel" name="label_10">
<property name="text">
<string>Name:</string>
@@ -69,22 +53,124 @@
</property>
</widget>
</item>
<item row="3" column="0">
<spacer name="horizontalSpacer_4">
<item row="0" column="2" colspan="2">
<widget class="QLineEdit" name="le_name"/>
</item>
<item row="0" column="4" rowspan="3">
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Ignored</enum>
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>1</width>
<height>1</height>
<width>20</width>
<height>60</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="1">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Application:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="2">
<widget class="QRadioButton" name="rb_template">
<property name="enabled">
<bool>false</bool>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>From template</string>
</property>
</widget>
</item>
<item row="1" column="3">
<widget class="QRadioButton" name="rb_custom">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Custom</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="1" colspan="3">
<widget class="QStackedWidget" name="stackedWidget">
<property name="currentIndex">
<number>1</number>
</property>
<widget class="QWidget" name="page_template">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="l_template">
<property name="text">
<string>Template:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="cb_template">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="editable">
<bool>false</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="page_command">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<property name="margin">
<number>0</number>
</property>
<item>
<widget class="QLabel" name="l_command">
<property name="text">
<string>Command:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="le_command"/>
</item>
</layout>
</widget>
</widget>
</item>
</layout>
</widget>
</item>


+ 4
- 7
source/frontend/carla_database.py View File

@@ -1975,16 +1975,13 @@ class JackApplicationW(QDialog):
flags = 0x0

if not name:
name = os.path.basename(command.split(" ",1)[0])
name = os.path.basename(command.split(" ",1)[0]).title()

# TODO finalize flag definitions
uiSessionMgrIndex = self.ui.cb_session_mgr.currentIndex()
if uiSessionMgrIndex == 1:
smgr = self.SESSION_MGR_AUTO
elif uiSessionMgrIndex == 2:
if uiSessionMgrIndex == self.UI_SESSION_LADISH:
smgr = self.SESSION_MGR_LADISH
#elif uiSessionMgrIndex == 2:
#smgr = self.SESSION_MGR_NSM
elif uiSessionMgrIndex == self.UI_SESSION_NSM:
smgr = self.SESSION_MGR_NSM

if self.ui.cb_manage_window.isChecked():
flags |= self.FLAG_CONTROL_WINDOW


Loading…
Cancel
Save