Enable grouping of macros

Based on OBS's source-tree model/view implementation
This commit is contained in:
WarmUpTill
2022-12-31 15:41:01 +01:00
committed by WarmUpTill
parent 2116bd7a78
commit a80af327d7
14 changed files with 1653 additions and 332 deletions

View File

@@ -634,49 +634,26 @@
</widget>
</item>
<item>
<layout class="QGridLayout" name="gridLayout_26">
<item row="0" column="0">
<widget class="QListWidget" name="macros">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="dragEnabled">
<bool>true</bool>
</property>
<property name="dragDropMode">
<enum>QAbstractItemView::InternalMove</enum>
</property>
<property name="defaultDropAction">
<enum>Qt::MoveAction</enum>
</property>
<property name="spacing">
<number>0</number>
</property>
<property name="sortingEnabled">
<bool>false</bool>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="macroHelp">
<property name="enabled">
<bool>false</bool>
</property>
<property name="text">
<string>AdvSceneSwitcher.macroTab.help</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
<widget class="MacroTree" name="macros">
<property name="showDropIndicator" stdset="0">
<bool>true</bool>
</property>
<property name="dragEnabled">
<bool>true</bool>
</property>
<property name="dragDropMode">
<enum>QAbstractItemView::InternalMove</enum>
</property>
<property name="defaultDropAction">
<enum>Qt::TargetMoveAction</enum>
</property>
<property name="selectionMode">
<enum>QAbstractItemView::ExtendedSelection</enum>
</property>
<property name="spacing">
<number>0</number>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_61">
@@ -4560,6 +4537,13 @@
</item>
</layout>
</widget>
<customwidgets>
<customwidget>
<class>MacroTree</class>
<extends>QListView</extends>
<header>macro-tree.hpp</header>
</customwidget>
</customwidgets>
<resources/>
<connections/>
</ui>