mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-16 11:17:49 -06:00
Update AskOpenAsProjectOrModelsDialog
CURA 8687
This commit is contained in:
parent
f59a23fd82
commit
72c038a8b1
1 changed files with 9 additions and 24 deletions
|
@ -4,12 +4,9 @@
|
||||||
import QtQuick 2.2
|
import QtQuick 2.2
|
||||||
import QtQuick.Controls 2.1
|
import QtQuick.Controls 2.1
|
||||||
import QtQuick.Layouts 1.1
|
import QtQuick.Layouts 1.1
|
||||||
import QtQuick.Dialogs 1.1
|
|
||||||
import QtQuick.Window 2.1
|
|
||||||
|
|
||||||
import UM 1.3 as UM
|
import UM 1.3 as UM
|
||||||
import Cura 1.0 as Cura
|
import Cura 1.5 as Cura
|
||||||
|
|
||||||
|
|
||||||
UM.Dialog
|
UM.Dialog
|
||||||
{
|
{
|
||||||
|
@ -76,17 +73,13 @@ UM.Dialog
|
||||||
Column
|
Column
|
||||||
{
|
{
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: 20 * screenScaleFactor
|
spacing: UM.Theme.getSize("default_margin").height
|
||||||
anchors.rightMargin: 20 * screenScaleFactor
|
|
||||||
anchors.bottomMargin: 10 * screenScaleFactor
|
|
||||||
spacing: 10 * screenScaleFactor
|
|
||||||
|
|
||||||
Label
|
Label
|
||||||
{
|
{
|
||||||
id: questionText
|
id: questionText
|
||||||
|
width: parent.width
|
||||||
text: catalog.i18nc("@text:window", "This is a Cura project file. Would you like to open it as a project or import the models from it?")
|
text: catalog.i18nc("@text:window", "This is a Cura project file. Would you like to open it as a project or import the models from it?")
|
||||||
anchors.left: parent.left
|
|
||||||
anchors.right: parent.right
|
|
||||||
font: UM.Theme.getFont("default")
|
font: UM.Theme.getFont("default")
|
||||||
wrapMode: Text.WordWrap
|
wrapMode: Text.WordWrap
|
||||||
}
|
}
|
||||||
|
@ -99,28 +92,20 @@ UM.Dialog
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Item
|
|
||||||
{
|
|
||||||
ButtonGroup
|
|
||||||
{
|
|
||||||
buttons: [openAsProjectButton, importModelsButton]
|
|
||||||
checkedButton: openAsProjectButton
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
onAccepted: loadProjectFile()
|
onAccepted: loadProjectFile()
|
||||||
onRejected: loadModelFiles()
|
onRejected: loadModelFiles()
|
||||||
|
|
||||||
rightButtons: [
|
buttonSpacing: UM.Theme.getSize("thin_margin").width
|
||||||
Button
|
|
||||||
|
rightButtons:
|
||||||
|
[
|
||||||
|
Cura.PrimaryButton
|
||||||
{
|
{
|
||||||
id: openAsProjectButton
|
|
||||||
text: catalog.i18nc("@action:button", "Open as project")
|
text: catalog.i18nc("@action:button", "Open as project")
|
||||||
onClicked: loadProjectFile()
|
onClicked: loadProjectFile()
|
||||||
},
|
},
|
||||||
Button
|
Cura.SecondaryButton
|
||||||
{
|
{
|
||||||
id: importModelsButton
|
|
||||||
text: catalog.i18nc("@action:button", "Import models")
|
text: catalog.i18nc("@action:button", "Import models")
|
||||||
onClicked: loadModelFiles()
|
onClicked: loadModelFiles()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue