Welcome to mirror list, hosted at ThFree Co, Russian Federation.

DigitalFactoryOpenDialog.qml « qml « resources « DigitalLibrary « plugins - github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 11c5d687e8f725d7ffe6baa1f6e3c19a97099523 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
//Copyright (C) 2022 Ultimaker B.V.
//Cura is released under the terms of the LGPLv3 or higher.

import QtQuick 2.10
import QtQuick.Window 2.2
import QtQuick.Controls 2.3

import UM 1.2 as UM
import Cura 1.6 as Cura

import DigitalFactory 1.0 as DF

Window
{
    id: digitalFactoryOpenDialogBase
    title: "Open file from Library"

    modality: Qt.ApplicationModal
    width: 800 * screenScaleFactor
    height: 600 * screenScaleFactor
    minimumWidth: 800 * screenScaleFactor
    minimumHeight: 600 * screenScaleFactor

    Shortcut
    {
        sequence: "Esc"
        onActivated: digitalFactoryOpenDialogBase.close()
    }
    color: UM.Theme.getColor("main_background")

    SelectProjectPage
    {
        visible: manager.selectedProjectIndex == -1
        createNewProjectButtonVisible: false
    }

    OpenProjectFilesPage
    {
        visible: manager.selectedProjectIndex >= 0
        onOpenFilePressed: digitalFactoryOpenDialogBase.close()
    }


    BusyIndicator
    {
        // Shows up while Cura is waiting to receive the user's projects from the digital factory library
        id: retrievingProjectsBusyIndicator

        anchors {
            verticalCenter: parent.verticalCenter
            horizontalCenter: parent.horizontalCenter
        }

        width: parent.width / 4
        height: width
        visible: manager.retrievingProjectsStatus == DF.RetrievalStatus.InProgress
        running: visible
        palette.dark: UM.Theme.getColor("text")
    }
}