6import QGroundControl.Controls
8/// Toolbar used for things like Polygon editing tools
10 width: Math.min(toolsRowLayout.width + (_margins * 2), availableWidth)
11 height: toolsFlickable.y + toolsFlickable.height + _margins
12 z: QGroundControl.zOrderMapItems + 2
14 property real availableWidth
16 property real _radius: ScreenTools.defaultFontPixelWidth / 2
17 property real _margins: ScreenTools.defaultFontPixelWidth / 2
19 Component.onCompleted: {
20 // Move the child controls from consumer into the layout control
23 for (i = 2; i < children.length; i++) {
24 moveList.push(children[i])
26 for (i = 0; i < moveList.length; i++) {
27 moveList[i].parent = toolsRowLayout
29 instructionComponent.createObject(toolsRowLayout)
35 color: QGroundControl.globalPalette.toolbarBackground
40 anchors.margins: _margins
41 anchors.top: parent.top
42 anchors.left: parent.left
43 anchors.right: parent.right
44 height: toolsRowLayout.height
46 flickableDirection: Flickable.HorizontalFlick
47 contentWidth: toolsRowLayout.width
56 id: instructionComponent
60 text: _instructionText