2021-01-12 17:03:39 +03:00
|
|
|
import QtQuick 2.9
|
2020-12-20 17:37:22 +03:00
|
|
|
import QtQuick.Controls 2.3
|
2021-01-12 17:03:39 +03:00
|
|
|
import QtQuick.Layouts 1.2
|
2020-12-20 17:37:22 +03:00
|
|
|
import im.nheko 1.0
|
|
|
|
|
2020-12-30 23:03:07 +03:00
|
|
|
Popup {
|
|
|
|
modal: true
|
|
|
|
anchors.centerIn: parent
|
2021-01-07 01:15:43 +03:00
|
|
|
palette: colors
|
2020-12-20 17:37:22 +03:00
|
|
|
|
|
|
|
ColumnLayout {
|
|
|
|
spacing: 16
|
|
|
|
|
|
|
|
ColumnLayout {
|
|
|
|
spacing: 8
|
2020-12-30 23:03:07 +03:00
|
|
|
Layout.topMargin: 8
|
|
|
|
Layout.leftMargin: 8
|
|
|
|
Layout.rightMargin: 8
|
2020-12-20 17:37:22 +03:00
|
|
|
|
2020-12-30 23:03:07 +03:00
|
|
|
RowLayout {
|
2020-12-20 17:37:22 +03:00
|
|
|
Image {
|
|
|
|
Layout.preferredWidth: 22
|
|
|
|
Layout.preferredHeight: 22
|
2021-01-07 01:15:43 +03:00
|
|
|
source: "image://colorimage/:/icons/icons/ui/microphone-unmute.png?" + colors.windowText
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
ComboBox {
|
|
|
|
id: micCombo
|
2021-01-12 01:51:39 +03:00
|
|
|
|
2020-12-20 17:37:22 +03:00
|
|
|
Layout.fillWidth: true
|
|
|
|
model: CallManager.mics
|
|
|
|
}
|
2021-01-12 01:51:39 +03:00
|
|
|
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
RowLayout {
|
2020-12-30 23:03:07 +03:00
|
|
|
visible: CallManager.isVideo && CallManager.cameras.length > 0
|
2020-12-20 17:37:22 +03:00
|
|
|
|
|
|
|
Image {
|
|
|
|
Layout.preferredWidth: 22
|
|
|
|
Layout.preferredHeight: 22
|
2021-01-07 01:15:43 +03:00
|
|
|
source: "image://colorimage/:/icons/icons/ui/video-call.png?" + colors.windowText
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|
|
|
|
|
|
|
|
ComboBox {
|
|
|
|
id: cameraCombo
|
2021-01-12 01:51:39 +03:00
|
|
|
|
2020-12-20 17:37:22 +03:00
|
|
|
Layout.fillWidth: true
|
|
|
|
model: CallManager.cameras
|
|
|
|
}
|
2021-01-12 01:51:39 +03:00
|
|
|
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|
2021-01-12 01:51:39 +03:00
|
|
|
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|
|
|
|
|
2020-12-30 23:03:07 +03:00
|
|
|
DialogButtonBox {
|
|
|
|
Layout.leftMargin: 128
|
|
|
|
standardButtons: DialogButtonBox.Ok | DialogButtonBox.Cancel
|
2021-01-12 01:51:39 +03:00
|
|
|
onAccepted: {
|
|
|
|
Settings.microphone = micCombo.currentText;
|
|
|
|
if (cameraCombo.visible)
|
|
|
|
Settings.camera = cameraCombo.currentText;
|
2020-12-20 17:37:22 +03:00
|
|
|
|
2020-12-30 23:03:07 +03:00
|
|
|
close();
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|
2020-12-30 23:03:07 +03:00
|
|
|
onRejected: {
|
|
|
|
close();
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|
|
|
|
}
|
2021-01-12 01:51:39 +03:00
|
|
|
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|
2021-01-12 01:51:39 +03:00
|
|
|
|
|
|
|
background: Rectangle {
|
|
|
|
color: colors.window
|
|
|
|
border.color: colors.windowText
|
|
|
|
}
|
|
|
|
|
2020-12-20 17:37:22 +03:00
|
|
|
}
|