5import QGroundControl.Controls
9 color: qgcPal.windowTransparent
10 width: ScreenTools.defaultFontPixelWidth * 7
11 height: Math.min(maxHeight, toolStripColumn.height + (flickable.anchors.margins * 2))
12 radius: ScreenTools.defaultFontPixelWidth / 2
14 property alias model: repeater.model
15 property real maxHeight ///< Maximum height for control, determines whether text is hidden to make control shorter
16 property var fontSize: ScreenTools.smallFontPointSize
18 property var _dropPanel: dropPanel
20 function simulateClick(buttonIndex) {
21 var button = toolStripColumn.children[buttonIndex]
22 if (button.checkable) {
23 button.checked = !button.checked
28 signal dropped(int index)
36 anchors.margins: ScreenTools.defaultFontPixelWidth * 0.4
38 contentHeight: toolStripColumn.height
39 flickableDirection: Flickable.VerticalFlick
44 anchors.left: parent.left
45 anchors.right: parent.right
46 spacing: ScreenTools.defaultFontPixelWidth * 0.25
51 ToolStripHoverButton {
53 anchors.left: toolStripColumn.left
54 anchors.right: toolStripColumn.right
56 radius: ScreenTools.defaultFontPixelWidth / 2
57 fontPointSize: _root.fontSize
58 toolStripAction: modelData
60 onDropped: (index) => _root.dropped(index)
63 // We deal with exclusive check state manually since usinug autoExclusive caused all sorts of crazt problems
65 for (var i=0; i<repeater.count; i++) {
67 var button = repeater.itemAt(i)
69 button.checked = false