forked from Sepanta/console-emulator
pouya
10 months ago
2 changed files with 67 additions and 7 deletions
@ -1,28 +1,87 @@ |
|||||
import QtQuick 2.0 |
import QtQuick 2.0 |
||||
import QtQuick.Layouts 1.13 |
import QtQuick.Layouts 1.13 |
||||
|
import QtQuick.Controls 2.12 |
||||
|
import de.skycoder42.QtMvvm.Core 1.0 |
||||
|
import de.skycoder42.QtMvvm.Quick 1.0 |
||||
|
import com.example.consoleemulator 1.0 |
||||
|
|
||||
import "qrc:/emulator/elements" |
import "qrc:/emulator/elements" |
||||
import "qrc:/emulator/components" |
import "qrc:/emulator/components" |
||||
import "qrc:/const" |
import "qrc:/const" |
||||
|
import "qrc:/qtmvvm/views" |
||||
|
|
||||
RowLayout { |
GridLayout { |
||||
x: 70 |
x: 70 |
||||
y: 50 |
y: 50 |
||||
spacing: 36 |
rowSpacing: 36 |
||||
|
columns: 4 |
||||
|
|
||||
ProbeButton { |
ProbeButton { |
||||
name: "probe" |
name: "probe1" |
||||
image: "qrc:/icons/topLeft/probe.png" |
image: "qrc:/icons/topLeft/probe.png" |
||||
} |
} |
||||
ProbeButton { |
ProbeButton { |
||||
name: "probe" |
name: "probe2" |
||||
image: "qrc:/icons/topLeft/probe.png" |
image: "qrc:/icons/topLeft/probe.png" |
||||
} |
} |
||||
ProbeButton { |
ProbeButton { |
||||
name: "probe" |
name: "probe3" |
||||
image: "qrc:/icons/topLeft/probe.png" |
image: "qrc:/icons/topLeft/probe.png" |
||||
} |
} |
||||
ProbeButton { |
ProbeButton { |
||||
name: "probe" |
name: "probe4" |
||||
image: "qrc:/icons/topLeft/probe.png" |
image: "qrc:/icons/topLeft/probe.png" |
||||
} |
} |
||||
|
property var widthOfBtns: 130 |
||||
|
property var probeList: [] |
||||
|
|
||||
|
MvvmBinding { |
||||
|
viewModel: mainView.viewModel |
||||
|
viewProperty: "probeList" |
||||
|
viewModelProperty: "probeList" |
||||
|
} |
||||
|
ComboBox { |
||||
|
model: probeList |
||||
|
width: widthOfBtns |
||||
|
implicitWidth: width |
||||
|
implicitHeight: 25 |
||||
|
MvvmBinding { |
||||
|
viewModel: mainView.viewModel |
||||
|
viewProperty: "currentIndex" |
||||
|
viewModelProperty: "currentSelectedProbe1" |
||||
|
} |
||||
|
} |
||||
|
ComboBox { |
||||
|
model: probeList |
||||
|
width: widthOfBtns |
||||
|
implicitWidth: width |
||||
|
implicitHeight: 25 |
||||
|
MvvmBinding { |
||||
|
viewModel: mainView.viewModel |
||||
|
viewProperty: "currentIndex" |
||||
|
viewModelProperty: "currentSelectedProbe2" |
||||
|
} |
||||
|
} |
||||
|
ComboBox { |
||||
|
model: probeList |
||||
|
width: widthOfBtns |
||||
|
implicitWidth: width |
||||
|
implicitHeight: 25 |
||||
|
MvvmBinding { |
||||
|
viewModel: mainView.viewModel |
||||
|
viewProperty: "currentIndex" |
||||
|
viewModelProperty: "currentSelectedProbe3" |
||||
|
} |
||||
|
} |
||||
|
ComboBox { |
||||
|
model: probeList |
||||
|
width: widthOfBtns |
||||
|
implicitWidth: width |
||||
|
implicitHeight: 25 |
||||
|
MvvmBinding { |
||||
|
viewModel: mainView.viewModel |
||||
|
viewProperty: "currentIndex" |
||||
|
viewModelProperty: "currentSelectedProbe4" |
||||
|
} |
||||
|
} |
||||
} |
} |
||||
|
Loading…
Reference in new issue