mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-21 05:37:50 -06:00
Monitor Tab - Use camera button on camera stream
- Fixes: Video feed close button is always out of sight - Makes improvement to camera icon Contributes to CL-1049
This commit is contained in:
parent
08d5e48407
commit
0b66bf0448
4 changed files with 47 additions and 33 deletions
|
@ -23,38 +23,50 @@ Item
|
|||
z: 0
|
||||
}
|
||||
|
||||
Button
|
||||
CameraButton
|
||||
{
|
||||
id: backButton
|
||||
anchors.bottom: cameraImage.top
|
||||
anchors.bottomMargin: UM.Theme.getSize("default_margin").width
|
||||
anchors.right: cameraImage.right
|
||||
|
||||
// TODO: Hardcoded sizes
|
||||
width: 20 * screenScaleFactor
|
||||
height: 20 * screenScaleFactor
|
||||
|
||||
onClicked: OutputDevice.setActiveCamera(null)
|
||||
|
||||
style: ButtonStyle
|
||||
id: closeCameraButton
|
||||
iconSource: UM.Theme.getIcon("cross1")
|
||||
anchors
|
||||
{
|
||||
label: Item
|
||||
{
|
||||
UM.RecolorImage
|
||||
{
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
width: control.width
|
||||
height: control.height
|
||||
sourceSize.width: width
|
||||
sourceSize.height: width
|
||||
source: UM.Theme.getIcon("cross1")
|
||||
}
|
||||
}
|
||||
background: Item {}
|
||||
top: cameraImage.top
|
||||
topMargin: UM.Theme.getSize("default_margin").height
|
||||
right: cameraImage.right
|
||||
rightMargin: UM.Theme.getSize("default_margin").width
|
||||
}
|
||||
z: 999
|
||||
}
|
||||
|
||||
// Button
|
||||
// {
|
||||
// id: backButton
|
||||
|
||||
|
||||
// // TODO: Hardcoded sizes
|
||||
// width: 20 * screenScaleFactor
|
||||
// height: 20 * screenScaleFactor
|
||||
|
||||
// onClicked: OutputDevice.setActiveCamera(null)
|
||||
|
||||
// style: ButtonStyle
|
||||
// {
|
||||
// label: Item
|
||||
// {
|
||||
// UM.RecolorImage
|
||||
// {
|
||||
// anchors.verticalCenter: parent.verticalCenter
|
||||
// anchors.horizontalCenter: parent.horizontalCenter
|
||||
// width: control.width
|
||||
// height: control.height
|
||||
// sourceSize.width: width
|
||||
// sourceSize.height: width
|
||||
// source: UM.Theme.getIcon("cross1")
|
||||
// }
|
||||
// }
|
||||
// background: Item {}
|
||||
// }
|
||||
// }
|
||||
|
||||
Image
|
||||
{
|
||||
id: cameraImage
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue