Exemplo n.º 1
0
    def setupUi(self, UnlinkDialog):
        UnlinkDialog.setObjectName("UnlinkDialog")
        UnlinkDialog.resize(387, 134)
        UnlinkDialog.setModal(True)
        self.gridLayout = QtWidgets.QGridLayout(UnlinkDialog)
        self.gridLayout.setHorizontalSpacing(20)
        self.gridLayout.setObjectName("gridLayout")
        self.infoLabel = QtWidgets.QLabel(UnlinkDialog)
        self.infoLabel.setWordWrap(True)
        self.infoLabel.setObjectName("infoLabel")
        self.gridLayout.addWidget(self.infoLabel, 1, 1, 1, 2)
        self.iconLabel = QtWidgets.QLabel(UnlinkDialog)
        self.iconLabel.setMinimumSize(QtCore.QSize(60, 60))
        self.iconLabel.setMaximumSize(QtCore.QSize(60, 60))
        self.iconLabel.setText("")
        self.iconLabel.setObjectName("iconLabel")
        self.gridLayout.addWidget(self.iconLabel, 0, 0, 2, 1)
        self.buttonBox = QtWidgets.QDialogButtonBox(UnlinkDialog)
        self.buttonBox.setOrientation(QtCore.Qt.Orientation.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.StandardButton.Cancel|QtWidgets.QDialogButtonBox.StandardButton.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.gridLayout.addWidget(self.buttonBox, 2, 2, 1, 1)
        self.titleLabel = QtWidgets.QLabel(UnlinkDialog)
        font = QtGui.QFont()
        font.setBold(True)
        font.setWeight(75)
        self.titleLabel.setFont(font)
        self.titleLabel.setObjectName("titleLabel")
        self.gridLayout.addWidget(self.titleLabel, 0, 1, 1, 2)
        self.progressIndicator = QProgressIndicator(UnlinkDialog)
        self.progressIndicator.setMinimumSize(QtCore.QSize(16, 16))
        self.progressIndicator.setMaximumSize(QtCore.QSize(16, 16))
        self.progressIndicator.setObjectName("progressIndicator")
        self.gridLayout.addWidget(self.progressIndicator, 2, 1, 1, 1, QtCore.Qt.AlignmentFlag.AlignVCenter)

        self.retranslateUi(UnlinkDialog)
        self.buttonBox.accepted.connect(UnlinkDialog.accept)
        self.buttonBox.rejected.connect(UnlinkDialog.reject)
        QtCore.QMetaObject.connectSlotsByName(UnlinkDialog)
Exemplo n.º 2
0
class Ui_UnlinkDialog(object):
    def setupUi(self, UnlinkDialog):
        UnlinkDialog.setObjectName("UnlinkDialog")
        UnlinkDialog.resize(387, 134)
        UnlinkDialog.setModal(True)
        self.gridLayout = QtWidgets.QGridLayout(UnlinkDialog)
        self.gridLayout.setHorizontalSpacing(20)
        self.gridLayout.setObjectName("gridLayout")
        self.infoLabel = QtWidgets.QLabel(UnlinkDialog)
        self.infoLabel.setWordWrap(True)
        self.infoLabel.setObjectName("infoLabel")
        self.gridLayout.addWidget(self.infoLabel, 1, 1, 1, 2)
        self.iconLabel = QtWidgets.QLabel(UnlinkDialog)
        self.iconLabel.setMinimumSize(QtCore.QSize(60, 60))
        self.iconLabel.setMaximumSize(QtCore.QSize(60, 60))
        self.iconLabel.setText("")
        self.iconLabel.setObjectName("iconLabel")
        self.gridLayout.addWidget(self.iconLabel, 0, 0, 2, 1)
        self.buttonBox = QtWidgets.QDialogButtonBox(UnlinkDialog)
        self.buttonBox.setOrientation(QtCore.Qt.Orientation.Horizontal)
        self.buttonBox.setStandardButtons(QtWidgets.QDialogButtonBox.StandardButton.Cancel|QtWidgets.QDialogButtonBox.StandardButton.Ok)
        self.buttonBox.setObjectName("buttonBox")
        self.gridLayout.addWidget(self.buttonBox, 2, 2, 1, 1)
        self.titleLabel = QtWidgets.QLabel(UnlinkDialog)
        font = QtGui.QFont()
        font.setBold(True)
        font.setWeight(75)
        self.titleLabel.setFont(font)
        self.titleLabel.setObjectName("titleLabel")
        self.gridLayout.addWidget(self.titleLabel, 0, 1, 1, 2)
        self.progressIndicator = QProgressIndicator(UnlinkDialog)
        self.progressIndicator.setMinimumSize(QtCore.QSize(16, 16))
        self.progressIndicator.setMaximumSize(QtCore.QSize(16, 16))
        self.progressIndicator.setObjectName("progressIndicator")
        self.gridLayout.addWidget(self.progressIndicator, 2, 1, 1, 1, QtCore.Qt.AlignmentFlag.AlignVCenter)

        self.retranslateUi(UnlinkDialog)
        self.buttonBox.accepted.connect(UnlinkDialog.accept)
        self.buttonBox.rejected.connect(UnlinkDialog.reject)
        QtCore.QMetaObject.connectSlotsByName(UnlinkDialog)

    def retranslateUi(self, UnlinkDialog):
        _translate = QtCore.QCoreApplication.translate
        UnlinkDialog.setWindowTitle(_translate("UnlinkDialog", "Dialog"))
        self.infoLabel.setText(_translate("UnlinkDialog", "You\'ll still keep your Dropbox folder on this computer, but your files will stop syncing."))
        self.titleLabel.setText(_translate("UnlinkDialog", "Unlink your Dropbox account?"))
Exemplo n.º 3
0
    def setupUi(self, SetupDialog):
        SetupDialog.setObjectName("SetupDialog")
        SetupDialog.resize(555, 400)
        self.verticalLayout = QtWidgets.QVBoxLayout(SetupDialog)
        self.verticalLayout.setContentsMargins(-1, 15, 15, 24)
        self.verticalLayout.setSpacing(5)
        self.verticalLayout.setObjectName("verticalLayout")
        self.stackedWidget = AnimatedStackedWidget(SetupDialog)
        self.stackedWidget.setObjectName("stackedWidget")
        self.welcomePage = QtWidgets.QWidget()
        self.welcomePage.setObjectName("welcomePage")
        self.gridLayout = QtWidgets.QGridLayout(self.welcomePage)
        self.gridLayout.setContentsMargins(0, 0, 0, 0)
        self.gridLayout.setObjectName("gridLayout")
        self.pushButtonLink = QtWidgets.QPushButton(self.welcomePage)
        self.pushButtonLink.setObjectName("pushButtonLink")
        self.gridLayout.addWidget(self.pushButtonLink, 4, 0, 1, 3,
                                  QtCore.Qt.AlignmentFlag.AlignHCenter)
        self.labelWelcome = QtWidgets.QLabel(self.welcomePage)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.labelWelcome.sizePolicy().hasHeightForWidth())
        self.labelWelcome.setSizePolicy(sizePolicy)
        self.labelWelcome.setMinimumSize(QtCore.QSize(0, 50))
        self.labelWelcome.setAlignment(QtCore.Qt.AlignmentFlag.AlignCenter)
        self.labelWelcome.setObjectName("labelWelcome")
        self.gridLayout.addWidget(self.labelWelcome, 3, 0, 1, 3)
        self.labelIcon_0 = QtWidgets.QLabel(self.welcomePage)
        self.labelIcon_0.setMinimumSize(QtCore.QSize(150, 150))
        self.labelIcon_0.setMaximumSize(QtCore.QSize(150, 150))
        self.labelIcon_0.setText("")
        self.labelIcon_0.setScaledContents(True)
        self.labelIcon_0.setWordWrap(False)
        self.labelIcon_0.setObjectName("labelIcon_0")
        self.gridLayout.addWidget(self.labelIcon_0, 1, 1, 1, 1,
                                  QtCore.Qt.AlignmentFlag.AlignHCenter)
        spacerItem = QtWidgets.QSpacerItem(
            20, 20, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout.addItem(spacerItem, 5, 0, 1, 3)
        spacerItem1 = QtWidgets.QSpacerItem(
            20, 20, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout.addItem(spacerItem1, 0, 0, 1, 3)
        spacerItem2 = QtWidgets.QSpacerItem(
            20, 0, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout.addItem(spacerItem2, 2, 0, 1, 3)
        self.stackedWidget.addWidget(self.welcomePage)
        self.authPage = QtWidgets.QWidget()
        self.authPage.setObjectName("authPage")
        self.gridLayout_5 = QtWidgets.QGridLayout(self.authPage)
        self.gridLayout_5.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_5.setObjectName("gridLayout_5")
        self.progressIndicator = QProgressIndicator(self.authPage)
        self.progressIndicator.setMinimumSize(QtCore.QSize(32, 32))
        self.progressIndicator.setMaximumSize(QtCore.QSize(32, 32))
        self.progressIndicator.setObjectName("progressIndicator")
        self.gridLayout_5.addWidget(
            self.progressIndicator, 5, 0, 1, 1,
            QtCore.Qt.AlignmentFlag.AlignHCenter
            | QtCore.Qt.AlignmentFlag.AlignVCenter)
        spacerItem3 = QtWidgets.QSpacerItem(
            20, 20, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Preferred)
        self.gridLayout_5.addItem(spacerItem3, 2, 0, 1, 1)
        self.labelAuthLink = QtWidgets.QLabel(self.authPage)
        self.labelAuthLink.setAlignment(QtCore.Qt.AlignmentFlag.AlignCenter)
        self.labelAuthLink.setWordWrap(True)
        self.labelAuthLink.setOpenExternalLinks(True)
        self.labelAuthLink.setObjectName("labelAuthLink")
        self.gridLayout_5.addWidget(self.labelAuthLink, 3, 0, 1, 1)
        self.lineEditAuthCode = QtWidgets.QLineEdit(self.authPage)
        self.lineEditAuthCode.setMinimumSize(QtCore.QSize(500, 0))
        self.lineEditAuthCode.setMaximumSize(QtCore.QSize(500, 16777215))
        self.lineEditAuthCode.setAlignment(QtCore.Qt.AlignmentFlag.AlignCenter)
        self.lineEditAuthCode.setObjectName("lineEditAuthCode")
        self.gridLayout_5.addWidget(self.lineEditAuthCode, 4, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        self.labelIcon_1 = QtWidgets.QLabel(self.authPage)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.labelIcon_1.sizePolicy().hasHeightForWidth())
        self.labelIcon_1.setSizePolicy(sizePolicy)
        self.labelIcon_1.setMinimumSize(QtCore.QSize(70, 70))
        self.labelIcon_1.setMaximumSize(QtCore.QSize(70, 70))
        self.labelIcon_1.setText("")
        self.labelIcon_1.setObjectName("labelIcon_1")
        self.gridLayout_5.addWidget(self.labelIcon_1, 1, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        spacerItem4 = QtWidgets.QSpacerItem(
            20, 20, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Fixed)
        self.gridLayout_5.addItem(spacerItem4, 0, 0, 1, 1)
        self.stackedWidget.addWidget(self.authPage)
        self.dropboxPathPage = QtWidgets.QWidget()
        self.dropboxPathPage.setObjectName("dropboxPathPage")
        self.gridLayout_7 = QtWidgets.QGridLayout(self.dropboxPathPage)
        self.gridLayout_7.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_7.setObjectName("gridLayout_7")
        spacerItem5 = QtWidgets.QSpacerItem(
            20, 15, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Fixed)
        self.gridLayout_7.addItem(spacerItem5, 0, 0, 1, 1)
        self.labelIcon_2 = QtWidgets.QLabel(self.dropboxPathPage)
        self.labelIcon_2.setMinimumSize(QtCore.QSize(70, 70))
        self.labelIcon_2.setMaximumSize(QtCore.QSize(70, 70))
        self.labelIcon_2.setText("")
        self.labelIcon_2.setObjectName("labelIcon_2")
        self.gridLayout_7.addWidget(self.labelIcon_2, 1, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        self.labelDropboxPath = QtWidgets.QLabel(self.dropboxPathPage)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.labelDropboxPath.sizePolicy().hasHeightForWidth())
        self.labelDropboxPath.setSizePolicy(sizePolicy)
        self.labelDropboxPath.setMinimumSize(QtCore.QSize(0, 20))
        self.labelDropboxPath.setAlignment(QtCore.Qt.AlignmentFlag.AlignCenter)
        self.labelDropboxPath.setWordWrap(True)
        self.labelDropboxPath.setObjectName("labelDropboxPath")
        self.gridLayout_7.addWidget(self.labelDropboxPath, 3, 0, 1, 1)
        spacerItem6 = QtWidgets.QSpacerItem(
            20, 15, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Fixed)
        self.gridLayout_7.addItem(spacerItem6, 2, 0, 1, 1)
        spacerItem7 = QtWidgets.QSpacerItem(
            20, 50, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout_7.addItem(spacerItem7, 5, 0, 1, 1)
        self.comboBoxDropboxPath = QtWidgets.QComboBox(self.dropboxPathPage)
        self.comboBoxDropboxPath.setObjectName("comboBoxDropboxPath")
        self.gridLayout_7.addWidget(self.comboBoxDropboxPath, 4, 0, 1, 1)
        self.stackedWidget.addWidget(self.dropboxPathPage)
        self.excludedFoldersPage = QtWidgets.QWidget()
        self.excludedFoldersPage.setObjectName("excludedFoldersPage")
        self.gridLayout_9 = QtWidgets.QGridLayout(self.excludedFoldersPage)
        self.gridLayout_9.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_9.setObjectName("gridLayout_9")
        self.labelFolderSelection = QtWidgets.QLabel(self.excludedFoldersPage)
        self.labelFolderSelection.setAlignment(
            QtCore.Qt.AlignmentFlag.AlignLeading
            | QtCore.Qt.AlignmentFlag.AlignLeft
            | QtCore.Qt.AlignmentFlag.AlignVCenter)
        self.labelFolderSelection.setWordWrap(True)
        self.labelFolderSelection.setObjectName("labelFolderSelection")
        self.gridLayout_9.addWidget(self.labelFolderSelection, 0, 0, 1, 1)
        self.selectAllCheckBox = QtWidgets.QCheckBox(self.excludedFoldersPage)
        self.selectAllCheckBox.setEnabled(False)
        self.selectAllCheckBox.setObjectName("selectAllCheckBox")
        self.gridLayout_9.addWidget(self.selectAllCheckBox, 2, 0, 1, 1)
        self.treeViewFolders = QtWidgets.QTreeView(self.excludedFoldersPage)
        self.treeViewFolders.setEditTriggers(
            QtWidgets.QAbstractItemView.EditTrigger.NoEditTriggers)
        self.treeViewFolders.setAlternatingRowColors(True)
        self.treeViewFolders.setSelectionMode(
            QtWidgets.QAbstractItemView.SelectionMode.NoSelection)
        self.treeViewFolders.setUniformRowHeights(True)
        self.treeViewFolders.setSortingEnabled(True)
        self.treeViewFolders.setHeaderHidden(True)
        self.treeViewFolders.setObjectName("treeViewFolders")
        self.treeViewFolders.header().setVisible(False)
        self.treeViewFolders.header().setMinimumSectionSize(50)
        self.gridLayout_9.addWidget(self.treeViewFolders, 1, 0, 1, 1)
        self.stackedWidget.addWidget(self.excludedFoldersPage)
        self.donePage = QtWidgets.QWidget()
        self.donePage.setObjectName("donePage")
        self.gridLayout_3 = QtWidgets.QGridLayout(self.donePage)
        self.gridLayout_3.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_3.setObjectName("gridLayout_3")
        spacerItem8 = QtWidgets.QSpacerItem(
            20, 30, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Preferred)
        self.gridLayout_3.addItem(spacerItem8, 5, 0, 1, 1)
        spacerItem9 = QtWidgets.QSpacerItem(
            20, 0, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout_3.addItem(spacerItem9, 2, 0, 1, 1)
        self.labelIcon_3 = QtWidgets.QLabel(self.donePage)
        self.labelIcon_3.setMinimumSize(QtCore.QSize(120, 120))
        self.labelIcon_3.setMaximumSize(QtCore.QSize(120, 120))
        self.labelIcon_3.setText("")
        self.labelIcon_3.setObjectName("labelIcon_3")
        self.gridLayout_3.addWidget(self.labelIcon_3, 1, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        self.labelSetupComplete = QtWidgets.QLabel(self.donePage)
        self.labelSetupComplete.setAlignment(
            QtCore.Qt.AlignmentFlag.AlignCenter)
        self.labelSetupComplete.setWordWrap(True)
        self.labelSetupComplete.setObjectName("labelSetupComplete")
        self.gridLayout_3.addWidget(self.labelSetupComplete, 3, 0, 1, 1)
        self.pushButtonClose = QtWidgets.QPushButton(self.donePage)
        icon = QtGui.QIcon.fromTheme("dialog-apply")
        self.pushButtonClose.setIcon(icon)
        self.pushButtonClose.setObjectName("pushButtonClose")
        self.gridLayout_3.addWidget(self.pushButtonClose, 4, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        spacerItem10 = QtWidgets.QSpacerItem(
            20, 0, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout_3.addItem(spacerItem10, 0, 0, 1, 1)
        self.stackedWidget.addWidget(self.donePage)
        self.verticalLayout.addWidget(self.stackedWidget)
        self.stackedWidgetButtons = QtWidgets.QStackedWidget(SetupDialog)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.stackedWidgetButtons.sizePolicy().hasHeightForWidth())
        self.stackedWidgetButtons.setSizePolicy(sizePolicy)
        self.stackedWidgetButtons.setObjectName("stackedWidgetButtons")
        self.welcomePageButtons = QtWidgets.QWidget()
        self.welcomePageButtons.setObjectName("welcomePageButtons")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.welcomePageButtons)
        self.gridLayout_2.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_2.setObjectName("gridLayout_2")
        spacerItem11 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_2.addItem(spacerItem11, 0, 0, 1, 1)
        self.stackedWidgetButtons.addWidget(self.welcomePageButtons)
        self.authPageButtons = QtWidgets.QWidget()
        self.authPageButtons.setObjectName("authPageButtons")
        self.gridLayout_4 = QtWidgets.QGridLayout(self.authPageButtons)
        self.gridLayout_4.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_4.setObjectName("gridLayout_4")
        self.pushButtonAuthPageLink = QtWidgets.QPushButton(
            self.authPageButtons)
        self.pushButtonAuthPageLink.setEnabled(True)
        icon = QtGui.QIcon.fromTheme("dialog-ok")
        self.pushButtonAuthPageLink.setIcon(icon)
        self.pushButtonAuthPageLink.setObjectName("pushButtonAuthPageLink")
        self.gridLayout_4.addWidget(self.pushButtonAuthPageLink, 0, 2, 1, 1)
        self.pushButtonAuthPageCancel = QtWidgets.QPushButton(
            self.authPageButtons)
        icon = QtGui.QIcon.fromTheme("dialog-close")
        self.pushButtonAuthPageCancel.setIcon(icon)
        self.pushButtonAuthPageCancel.setObjectName("pushButtonAuthPageCancel")
        self.gridLayout_4.addWidget(self.pushButtonAuthPageCancel, 0, 1, 1, 1)
        spacerItem12 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_4.addItem(spacerItem12, 0, 0, 1, 1)
        self.stackedWidgetButtons.addWidget(self.authPageButtons)
        self.dropboxPathPageButtons = QtWidgets.QWidget()
        self.dropboxPathPageButtons.setObjectName("dropboxPathPageButtons")
        self.gridLayout_8 = QtWidgets.QGridLayout(self.dropboxPathPageButtons)
        self.gridLayout_8.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_8.setObjectName("gridLayout_8")
        self.pushButtonDropboxPathCancel = QtWidgets.QPushButton(
            self.dropboxPathPageButtons)
        icon = QtGui.QIcon.fromTheme("dialog-close")
        self.pushButtonDropboxPathCancel.setIcon(icon)
        self.pushButtonDropboxPathCancel.setObjectName(
            "pushButtonDropboxPathCancel")
        self.gridLayout_8.addWidget(self.pushButtonDropboxPathCancel, 0, 3, 1,
                                    1)
        self.pushButtonDropboxPathUnlink = QtWidgets.QPushButton(
            self.dropboxPathPageButtons)
        icon = QtGui.QIcon.fromTheme("edit-clear")
        self.pushButtonDropboxPathUnlink.setIcon(icon)
        self.pushButtonDropboxPathUnlink.setObjectName(
            "pushButtonDropboxPathUnlink")
        self.gridLayout_8.addWidget(self.pushButtonDropboxPathUnlink, 0, 1, 1,
                                    1)
        self.pushButtonDropboxPathSelect = QtWidgets.QPushButton(
            self.dropboxPathPageButtons)
        icon = QtGui.QIcon.fromTheme("dialog-ok")
        self.pushButtonDropboxPathSelect.setIcon(icon)
        self.pushButtonDropboxPathSelect.setObjectName(
            "pushButtonDropboxPathSelect")
        self.gridLayout_8.addWidget(self.pushButtonDropboxPathSelect, 0, 4, 1,
                                    1)
        spacerItem13 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_8.addItem(spacerItem13, 0, 2, 1, 1)
        self.stackedWidgetButtons.addWidget(self.dropboxPathPageButtons)
        self.excludedFoldersPageButtons = QtWidgets.QWidget()
        self.excludedFoldersPageButtons.setObjectName(
            "excludedFoldersPageButtons")
        self.gridLayout_6 = QtWidgets.QGridLayout(
            self.excludedFoldersPageButtons)
        self.gridLayout_6.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_6.setObjectName("gridLayout_6")
        self.pushButtonFolderSelectionBack = QtWidgets.QPushButton(
            self.excludedFoldersPageButtons)
        self.pushButtonFolderSelectionBack.setObjectName(
            "pushButtonFolderSelectionBack")
        self.gridLayout_6.addWidget(self.pushButtonFolderSelectionBack, 0, 1,
                                    1, 1)
        self.pushButtonFolderSelectionSelect = QtWidgets.QPushButton(
            self.excludedFoldersPageButtons)
        icon = QtGui.QIcon.fromTheme("dialog-ok")
        self.pushButtonFolderSelectionSelect.setIcon(icon)
        self.pushButtonFolderSelectionSelect.setObjectName(
            "pushButtonFolderSelectionSelect")
        self.gridLayout_6.addWidget(self.pushButtonFolderSelectionSelect, 0, 2,
                                    1, 1)
        spacerItem14 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_6.addItem(spacerItem14, 0, 0, 1, 1)
        self.stackedWidgetButtons.addWidget(self.excludedFoldersPageButtons)
        self.donePageButtons = QtWidgets.QWidget()
        self.donePageButtons.setObjectName("donePageButtons")
        self.gridLayout_10 = QtWidgets.QGridLayout(self.donePageButtons)
        self.gridLayout_10.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_10.setObjectName("gridLayout_10")
        spacerItem15 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_10.addItem(spacerItem15, 0, 0, 1, 1)
        self.stackedWidgetButtons.addWidget(self.donePageButtons)
        self.verticalLayout.addWidget(self.stackedWidgetButtons)
        self.verticalLayout.setStretch(0, 1)

        self.retranslateUi(SetupDialog)
        self.stackedWidget.setCurrentIndex(0)
        self.stackedWidgetButtons.setCurrentIndex(0)
        self.stackedWidget.currentChanged['int'].connect(
            self.stackedWidgetButtons.setCurrentIndex)
        QtCore.QMetaObject.connectSlotsByName(SetupDialog)
        SetupDialog.setTabOrder(self.pushButtonLink,
                                self.pushButtonAuthPageLink)
        SetupDialog.setTabOrder(self.pushButtonAuthPageLink,
                                self.pushButtonAuthPageCancel)
        SetupDialog.setTabOrder(self.pushButtonAuthPageCancel,
                                self.lineEditAuthCode)
        SetupDialog.setTabOrder(self.lineEditAuthCode,
                                self.pushButtonDropboxPathSelect)
        SetupDialog.setTabOrder(self.pushButtonDropboxPathSelect,
                                self.pushButtonDropboxPathCancel)
        SetupDialog.setTabOrder(self.pushButtonDropboxPathCancel,
                                self.pushButtonDropboxPathUnlink)
        SetupDialog.setTabOrder(self.pushButtonDropboxPathUnlink,
                                self.comboBoxDropboxPath)
        SetupDialog.setTabOrder(self.comboBoxDropboxPath,
                                self.pushButtonFolderSelectionSelect)
        SetupDialog.setTabOrder(self.pushButtonFolderSelectionSelect,
                                self.pushButtonFolderSelectionBack)
        SetupDialog.setTabOrder(self.pushButtonFolderSelectionBack,
                                self.treeViewFolders)
        SetupDialog.setTabOrder(self.treeViewFolders, self.selectAllCheckBox)
        SetupDialog.setTabOrder(self.selectAllCheckBox, self.pushButtonClose)
Exemplo n.º 4
0
class Ui_SetupDialog(object):
    def setupUi(self, SetupDialog):
        SetupDialog.setObjectName("SetupDialog")
        SetupDialog.resize(555, 400)
        self.verticalLayout = QtWidgets.QVBoxLayout(SetupDialog)
        self.verticalLayout.setContentsMargins(-1, 15, 15, 24)
        self.verticalLayout.setSpacing(5)
        self.verticalLayout.setObjectName("verticalLayout")
        self.stackedWidget = AnimatedStackedWidget(SetupDialog)
        self.stackedWidget.setObjectName("stackedWidget")
        self.welcomePage = QtWidgets.QWidget()
        self.welcomePage.setObjectName("welcomePage")
        self.gridLayout = QtWidgets.QGridLayout(self.welcomePage)
        self.gridLayout.setContentsMargins(0, 0, 0, 0)
        self.gridLayout.setObjectName("gridLayout")
        self.pushButtonLink = QtWidgets.QPushButton(self.welcomePage)
        self.pushButtonLink.setObjectName("pushButtonLink")
        self.gridLayout.addWidget(self.pushButtonLink, 4, 0, 1, 3,
                                  QtCore.Qt.AlignmentFlag.AlignHCenter)
        self.labelWelcome = QtWidgets.QLabel(self.welcomePage)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.labelWelcome.sizePolicy().hasHeightForWidth())
        self.labelWelcome.setSizePolicy(sizePolicy)
        self.labelWelcome.setMinimumSize(QtCore.QSize(0, 50))
        self.labelWelcome.setAlignment(QtCore.Qt.AlignmentFlag.AlignCenter)
        self.labelWelcome.setObjectName("labelWelcome")
        self.gridLayout.addWidget(self.labelWelcome, 3, 0, 1, 3)
        self.labelIcon_0 = QtWidgets.QLabel(self.welcomePage)
        self.labelIcon_0.setMinimumSize(QtCore.QSize(150, 150))
        self.labelIcon_0.setMaximumSize(QtCore.QSize(150, 150))
        self.labelIcon_0.setText("")
        self.labelIcon_0.setScaledContents(True)
        self.labelIcon_0.setWordWrap(False)
        self.labelIcon_0.setObjectName("labelIcon_0")
        self.gridLayout.addWidget(self.labelIcon_0, 1, 1, 1, 1,
                                  QtCore.Qt.AlignmentFlag.AlignHCenter)
        spacerItem = QtWidgets.QSpacerItem(
            20, 20, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout.addItem(spacerItem, 5, 0, 1, 3)
        spacerItem1 = QtWidgets.QSpacerItem(
            20, 20, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout.addItem(spacerItem1, 0, 0, 1, 3)
        spacerItem2 = QtWidgets.QSpacerItem(
            20, 0, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout.addItem(spacerItem2, 2, 0, 1, 3)
        self.stackedWidget.addWidget(self.welcomePage)
        self.authPage = QtWidgets.QWidget()
        self.authPage.setObjectName("authPage")
        self.gridLayout_5 = QtWidgets.QGridLayout(self.authPage)
        self.gridLayout_5.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_5.setObjectName("gridLayout_5")
        self.progressIndicator = QProgressIndicator(self.authPage)
        self.progressIndicator.setMinimumSize(QtCore.QSize(32, 32))
        self.progressIndicator.setMaximumSize(QtCore.QSize(32, 32))
        self.progressIndicator.setObjectName("progressIndicator")
        self.gridLayout_5.addWidget(
            self.progressIndicator, 5, 0, 1, 1,
            QtCore.Qt.AlignmentFlag.AlignHCenter
            | QtCore.Qt.AlignmentFlag.AlignVCenter)
        spacerItem3 = QtWidgets.QSpacerItem(
            20, 20, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Preferred)
        self.gridLayout_5.addItem(spacerItem3, 2, 0, 1, 1)
        self.labelAuthLink = QtWidgets.QLabel(self.authPage)
        self.labelAuthLink.setAlignment(QtCore.Qt.AlignmentFlag.AlignCenter)
        self.labelAuthLink.setWordWrap(True)
        self.labelAuthLink.setOpenExternalLinks(True)
        self.labelAuthLink.setObjectName("labelAuthLink")
        self.gridLayout_5.addWidget(self.labelAuthLink, 3, 0, 1, 1)
        self.lineEditAuthCode = QtWidgets.QLineEdit(self.authPage)
        self.lineEditAuthCode.setMinimumSize(QtCore.QSize(500, 0))
        self.lineEditAuthCode.setMaximumSize(QtCore.QSize(500, 16777215))
        self.lineEditAuthCode.setAlignment(QtCore.Qt.AlignmentFlag.AlignCenter)
        self.lineEditAuthCode.setObjectName("lineEditAuthCode")
        self.gridLayout_5.addWidget(self.lineEditAuthCode, 4, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        self.labelIcon_1 = QtWidgets.QLabel(self.authPage)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.labelIcon_1.sizePolicy().hasHeightForWidth())
        self.labelIcon_1.setSizePolicy(sizePolicy)
        self.labelIcon_1.setMinimumSize(QtCore.QSize(70, 70))
        self.labelIcon_1.setMaximumSize(QtCore.QSize(70, 70))
        self.labelIcon_1.setText("")
        self.labelIcon_1.setObjectName("labelIcon_1")
        self.gridLayout_5.addWidget(self.labelIcon_1, 1, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        spacerItem4 = QtWidgets.QSpacerItem(
            20, 20, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Fixed)
        self.gridLayout_5.addItem(spacerItem4, 0, 0, 1, 1)
        self.stackedWidget.addWidget(self.authPage)
        self.dropboxPathPage = QtWidgets.QWidget()
        self.dropboxPathPage.setObjectName("dropboxPathPage")
        self.gridLayout_7 = QtWidgets.QGridLayout(self.dropboxPathPage)
        self.gridLayout_7.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_7.setObjectName("gridLayout_7")
        spacerItem5 = QtWidgets.QSpacerItem(
            20, 15, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Fixed)
        self.gridLayout_7.addItem(spacerItem5, 0, 0, 1, 1)
        self.labelIcon_2 = QtWidgets.QLabel(self.dropboxPathPage)
        self.labelIcon_2.setMinimumSize(QtCore.QSize(70, 70))
        self.labelIcon_2.setMaximumSize(QtCore.QSize(70, 70))
        self.labelIcon_2.setText("")
        self.labelIcon_2.setObjectName("labelIcon_2")
        self.gridLayout_7.addWidget(self.labelIcon_2, 1, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        self.labelDropboxPath = QtWidgets.QLabel(self.dropboxPathPage)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.labelDropboxPath.sizePolicy().hasHeightForWidth())
        self.labelDropboxPath.setSizePolicy(sizePolicy)
        self.labelDropboxPath.setMinimumSize(QtCore.QSize(0, 20))
        self.labelDropboxPath.setAlignment(QtCore.Qt.AlignmentFlag.AlignCenter)
        self.labelDropboxPath.setWordWrap(True)
        self.labelDropboxPath.setObjectName("labelDropboxPath")
        self.gridLayout_7.addWidget(self.labelDropboxPath, 3, 0, 1, 1)
        spacerItem6 = QtWidgets.QSpacerItem(
            20, 15, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Fixed)
        self.gridLayout_7.addItem(spacerItem6, 2, 0, 1, 1)
        spacerItem7 = QtWidgets.QSpacerItem(
            20, 50, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout_7.addItem(spacerItem7, 5, 0, 1, 1)
        self.comboBoxDropboxPath = QtWidgets.QComboBox(self.dropboxPathPage)
        self.comboBoxDropboxPath.setObjectName("comboBoxDropboxPath")
        self.gridLayout_7.addWidget(self.comboBoxDropboxPath, 4, 0, 1, 1)
        self.stackedWidget.addWidget(self.dropboxPathPage)
        self.excludedFoldersPage = QtWidgets.QWidget()
        self.excludedFoldersPage.setObjectName("excludedFoldersPage")
        self.gridLayout_9 = QtWidgets.QGridLayout(self.excludedFoldersPage)
        self.gridLayout_9.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_9.setObjectName("gridLayout_9")
        self.labelFolderSelection = QtWidgets.QLabel(self.excludedFoldersPage)
        self.labelFolderSelection.setAlignment(
            QtCore.Qt.AlignmentFlag.AlignLeading
            | QtCore.Qt.AlignmentFlag.AlignLeft
            | QtCore.Qt.AlignmentFlag.AlignVCenter)
        self.labelFolderSelection.setWordWrap(True)
        self.labelFolderSelection.setObjectName("labelFolderSelection")
        self.gridLayout_9.addWidget(self.labelFolderSelection, 0, 0, 1, 1)
        self.selectAllCheckBox = QtWidgets.QCheckBox(self.excludedFoldersPage)
        self.selectAllCheckBox.setEnabled(False)
        self.selectAllCheckBox.setObjectName("selectAllCheckBox")
        self.gridLayout_9.addWidget(self.selectAllCheckBox, 2, 0, 1, 1)
        self.treeViewFolders = QtWidgets.QTreeView(self.excludedFoldersPage)
        self.treeViewFolders.setEditTriggers(
            QtWidgets.QAbstractItemView.EditTrigger.NoEditTriggers)
        self.treeViewFolders.setAlternatingRowColors(True)
        self.treeViewFolders.setSelectionMode(
            QtWidgets.QAbstractItemView.SelectionMode.NoSelection)
        self.treeViewFolders.setUniformRowHeights(True)
        self.treeViewFolders.setSortingEnabled(True)
        self.treeViewFolders.setHeaderHidden(True)
        self.treeViewFolders.setObjectName("treeViewFolders")
        self.treeViewFolders.header().setVisible(False)
        self.treeViewFolders.header().setMinimumSectionSize(50)
        self.gridLayout_9.addWidget(self.treeViewFolders, 1, 0, 1, 1)
        self.stackedWidget.addWidget(self.excludedFoldersPage)
        self.donePage = QtWidgets.QWidget()
        self.donePage.setObjectName("donePage")
        self.gridLayout_3 = QtWidgets.QGridLayout(self.donePage)
        self.gridLayout_3.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_3.setObjectName("gridLayout_3")
        spacerItem8 = QtWidgets.QSpacerItem(
            20, 30, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Preferred)
        self.gridLayout_3.addItem(spacerItem8, 5, 0, 1, 1)
        spacerItem9 = QtWidgets.QSpacerItem(
            20, 0, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout_3.addItem(spacerItem9, 2, 0, 1, 1)
        self.labelIcon_3 = QtWidgets.QLabel(self.donePage)
        self.labelIcon_3.setMinimumSize(QtCore.QSize(120, 120))
        self.labelIcon_3.setMaximumSize(QtCore.QSize(120, 120))
        self.labelIcon_3.setText("")
        self.labelIcon_3.setObjectName("labelIcon_3")
        self.gridLayout_3.addWidget(self.labelIcon_3, 1, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        self.labelSetupComplete = QtWidgets.QLabel(self.donePage)
        self.labelSetupComplete.setAlignment(
            QtCore.Qt.AlignmentFlag.AlignCenter)
        self.labelSetupComplete.setWordWrap(True)
        self.labelSetupComplete.setObjectName("labelSetupComplete")
        self.gridLayout_3.addWidget(self.labelSetupComplete, 3, 0, 1, 1)
        self.pushButtonClose = QtWidgets.QPushButton(self.donePage)
        icon = QtGui.QIcon.fromTheme("dialog-apply")
        self.pushButtonClose.setIcon(icon)
        self.pushButtonClose.setObjectName("pushButtonClose")
        self.gridLayout_3.addWidget(self.pushButtonClose, 4, 0, 1, 1,
                                    QtCore.Qt.AlignmentFlag.AlignHCenter)
        spacerItem10 = QtWidgets.QSpacerItem(
            20, 0, QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Expanding)
        self.gridLayout_3.addItem(spacerItem10, 0, 0, 1, 1)
        self.stackedWidget.addWidget(self.donePage)
        self.verticalLayout.addWidget(self.stackedWidget)
        self.stackedWidgetButtons = QtWidgets.QStackedWidget(SetupDialog)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Minimum,
            QtWidgets.QSizePolicy.Policy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.stackedWidgetButtons.sizePolicy().hasHeightForWidth())
        self.stackedWidgetButtons.setSizePolicy(sizePolicy)
        self.stackedWidgetButtons.setObjectName("stackedWidgetButtons")
        self.welcomePageButtons = QtWidgets.QWidget()
        self.welcomePageButtons.setObjectName("welcomePageButtons")
        self.gridLayout_2 = QtWidgets.QGridLayout(self.welcomePageButtons)
        self.gridLayout_2.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_2.setObjectName("gridLayout_2")
        spacerItem11 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_2.addItem(spacerItem11, 0, 0, 1, 1)
        self.stackedWidgetButtons.addWidget(self.welcomePageButtons)
        self.authPageButtons = QtWidgets.QWidget()
        self.authPageButtons.setObjectName("authPageButtons")
        self.gridLayout_4 = QtWidgets.QGridLayout(self.authPageButtons)
        self.gridLayout_4.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_4.setObjectName("gridLayout_4")
        self.pushButtonAuthPageLink = QtWidgets.QPushButton(
            self.authPageButtons)
        self.pushButtonAuthPageLink.setEnabled(True)
        icon = QtGui.QIcon.fromTheme("dialog-ok")
        self.pushButtonAuthPageLink.setIcon(icon)
        self.pushButtonAuthPageLink.setObjectName("pushButtonAuthPageLink")
        self.gridLayout_4.addWidget(self.pushButtonAuthPageLink, 0, 2, 1, 1)
        self.pushButtonAuthPageCancel = QtWidgets.QPushButton(
            self.authPageButtons)
        icon = QtGui.QIcon.fromTheme("dialog-close")
        self.pushButtonAuthPageCancel.setIcon(icon)
        self.pushButtonAuthPageCancel.setObjectName("pushButtonAuthPageCancel")
        self.gridLayout_4.addWidget(self.pushButtonAuthPageCancel, 0, 1, 1, 1)
        spacerItem12 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_4.addItem(spacerItem12, 0, 0, 1, 1)
        self.stackedWidgetButtons.addWidget(self.authPageButtons)
        self.dropboxPathPageButtons = QtWidgets.QWidget()
        self.dropboxPathPageButtons.setObjectName("dropboxPathPageButtons")
        self.gridLayout_8 = QtWidgets.QGridLayout(self.dropboxPathPageButtons)
        self.gridLayout_8.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_8.setObjectName("gridLayout_8")
        self.pushButtonDropboxPathCancel = QtWidgets.QPushButton(
            self.dropboxPathPageButtons)
        icon = QtGui.QIcon.fromTheme("dialog-close")
        self.pushButtonDropboxPathCancel.setIcon(icon)
        self.pushButtonDropboxPathCancel.setObjectName(
            "pushButtonDropboxPathCancel")
        self.gridLayout_8.addWidget(self.pushButtonDropboxPathCancel, 0, 3, 1,
                                    1)
        self.pushButtonDropboxPathUnlink = QtWidgets.QPushButton(
            self.dropboxPathPageButtons)
        icon = QtGui.QIcon.fromTheme("edit-clear")
        self.pushButtonDropboxPathUnlink.setIcon(icon)
        self.pushButtonDropboxPathUnlink.setObjectName(
            "pushButtonDropboxPathUnlink")
        self.gridLayout_8.addWidget(self.pushButtonDropboxPathUnlink, 0, 1, 1,
                                    1)
        self.pushButtonDropboxPathSelect = QtWidgets.QPushButton(
            self.dropboxPathPageButtons)
        icon = QtGui.QIcon.fromTheme("dialog-ok")
        self.pushButtonDropboxPathSelect.setIcon(icon)
        self.pushButtonDropboxPathSelect.setObjectName(
            "pushButtonDropboxPathSelect")
        self.gridLayout_8.addWidget(self.pushButtonDropboxPathSelect, 0, 4, 1,
                                    1)
        spacerItem13 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_8.addItem(spacerItem13, 0, 2, 1, 1)
        self.stackedWidgetButtons.addWidget(self.dropboxPathPageButtons)
        self.excludedFoldersPageButtons = QtWidgets.QWidget()
        self.excludedFoldersPageButtons.setObjectName(
            "excludedFoldersPageButtons")
        self.gridLayout_6 = QtWidgets.QGridLayout(
            self.excludedFoldersPageButtons)
        self.gridLayout_6.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_6.setObjectName("gridLayout_6")
        self.pushButtonFolderSelectionBack = QtWidgets.QPushButton(
            self.excludedFoldersPageButtons)
        self.pushButtonFolderSelectionBack.setObjectName(
            "pushButtonFolderSelectionBack")
        self.gridLayout_6.addWidget(self.pushButtonFolderSelectionBack, 0, 1,
                                    1, 1)
        self.pushButtonFolderSelectionSelect = QtWidgets.QPushButton(
            self.excludedFoldersPageButtons)
        icon = QtGui.QIcon.fromTheme("dialog-ok")
        self.pushButtonFolderSelectionSelect.setIcon(icon)
        self.pushButtonFolderSelectionSelect.setObjectName(
            "pushButtonFolderSelectionSelect")
        self.gridLayout_6.addWidget(self.pushButtonFolderSelectionSelect, 0, 2,
                                    1, 1)
        spacerItem14 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_6.addItem(spacerItem14, 0, 0, 1, 1)
        self.stackedWidgetButtons.addWidget(self.excludedFoldersPageButtons)
        self.donePageButtons = QtWidgets.QWidget()
        self.donePageButtons.setObjectName("donePageButtons")
        self.gridLayout_10 = QtWidgets.QGridLayout(self.donePageButtons)
        self.gridLayout_10.setContentsMargins(0, 0, 0, 0)
        self.gridLayout_10.setObjectName("gridLayout_10")
        spacerItem15 = QtWidgets.QSpacerItem(
            50, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_10.addItem(spacerItem15, 0, 0, 1, 1)
        self.stackedWidgetButtons.addWidget(self.donePageButtons)
        self.verticalLayout.addWidget(self.stackedWidgetButtons)
        self.verticalLayout.setStretch(0, 1)

        self.retranslateUi(SetupDialog)
        self.stackedWidget.setCurrentIndex(0)
        self.stackedWidgetButtons.setCurrentIndex(0)
        self.stackedWidget.currentChanged['int'].connect(
            self.stackedWidgetButtons.setCurrentIndex)
        QtCore.QMetaObject.connectSlotsByName(SetupDialog)
        SetupDialog.setTabOrder(self.pushButtonLink,
                                self.pushButtonAuthPageLink)
        SetupDialog.setTabOrder(self.pushButtonAuthPageLink,
                                self.pushButtonAuthPageCancel)
        SetupDialog.setTabOrder(self.pushButtonAuthPageCancel,
                                self.lineEditAuthCode)
        SetupDialog.setTabOrder(self.lineEditAuthCode,
                                self.pushButtonDropboxPathSelect)
        SetupDialog.setTabOrder(self.pushButtonDropboxPathSelect,
                                self.pushButtonDropboxPathCancel)
        SetupDialog.setTabOrder(self.pushButtonDropboxPathCancel,
                                self.pushButtonDropboxPathUnlink)
        SetupDialog.setTabOrder(self.pushButtonDropboxPathUnlink,
                                self.comboBoxDropboxPath)
        SetupDialog.setTabOrder(self.comboBoxDropboxPath,
                                self.pushButtonFolderSelectionSelect)
        SetupDialog.setTabOrder(self.pushButtonFolderSelectionSelect,
                                self.pushButtonFolderSelectionBack)
        SetupDialog.setTabOrder(self.pushButtonFolderSelectionBack,
                                self.treeViewFolders)
        SetupDialog.setTabOrder(self.treeViewFolders, self.selectAllCheckBox)
        SetupDialog.setTabOrder(self.selectAllCheckBox, self.pushButtonClose)

    def retranslateUi(self, SetupDialog):
        _translate = QtCore.QCoreApplication.translate
        SetupDialog.setWindowTitle(_translate("SetupDialog", "Maestral Setup"))
        self.pushButtonLink.setText(
            _translate("SetupDialog", "Link Dropbox Account"))
        self.labelWelcome.setText(
            _translate(
                "SetupDialog",
                "Welcome to Maestral, an open source Dropbox client for Linux and macOS."
            ))
        self.labelAuthLink.setText(
            _translate(
                "SetupDialog",
                "<html><head/><body><p align=\"center\">To link Maestral to your Dropbox account, please click <a href=\"{0}\">here</a> to retrieve an authorization token from Dropbox and enter it below.</p></body></html>"
            ))
        self.lineEditAuthCode.setPlaceholderText(
            _translate("SetupDialog", "Authorization token"))
        self.labelDropboxPath.setText(
            _translate(
                "SetupDialog",
                "<html><head/><body><p align=\"center\">Maestral has been successfully linked with your Dropbox account.</p><p align=\"center\">Please select a local folder for your Dropbox. If the folder is not empty, you will be given the option to merge its content with your remote Dropbox. Merging will not transfer or duplicate any identical files.</p><p align=\"center\">In the next step, you will be asked to choose which folders to sync.</p></body></html>"
            ))
        self.labelFolderSelection.setText(
            _translate(
                "SetupDialog",
                "Please select which files and folders to sync below. The inital download may take some time, depending on the size of your Dropbox."
            ))
        self.selectAllCheckBox.setText(_translate("SetupDialog", "Select all"))
        self.labelSetupComplete.setText(
            _translate(
                "SetupDialog",
                "<html><head/><body><p align=\"center\">You have successfully set up Maestral. </p><p align=\"center\">Please allow some time for the initial indexing and download of your Dropbox before Maestral will commence syncing.</p></body></html>"
            ))
        self.pushButtonClose.setText(_translate("SetupDialog", "Close"))
        self.pushButtonAuthPageLink.setText(_translate("SetupDialog", "Link"))
        self.pushButtonAuthPageCancel.setText(
            _translate("SetupDialog", "Cancel"))
        self.pushButtonDropboxPathCancel.setText(
            _translate("SetupDialog", "Cancel"))
        self.pushButtonDropboxPathUnlink.setText(
            _translate("SetupDialog", "Unlink"))
        self.pushButtonDropboxPathSelect.setText(
            _translate("SetupDialog", "Select"))
        self.pushButtonFolderSelectionBack.setText(
            _translate("SetupDialog", "Back"))
        self.pushButtonFolderSelectionSelect.setText(
            _translate("SetupDialog", "Select"))
    def setupUi(self, Dialog):
        Dialog.setObjectName("Dialog")
        Dialog.resize(688, 273)
        self.gridLayout = QtWidgets.QGridLayout(Dialog)
        self.gridLayout.setObjectName("gridLayout")
        self.gridLayout_2 = QtWidgets.QGridLayout()
        self.gridLayout_2.setContentsMargins(-1, -1, -1, 0)
        self.gridLayout_2.setSpacing(20)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.pushButtonUnlink = QtWidgets.QPushButton(Dialog)
        self.pushButtonUnlink.setObjectName("pushButtonUnlink")
        self.gridLayout_2.addWidget(self.pushButtonUnlink, 3, 4, 1, 1)
        self.comboBoxPath = QtWidgets.QComboBox(Dialog)
        self.comboBoxPath.setObjectName("comboBoxPath")
        self.gridLayout_2.addWidget(self.comboBoxPath, 2, 1, 1, 6)
        self.pushButtonQuit = QtWidgets.QPushButton(Dialog)
        self.pushButtonQuit.setObjectName("pushButtonQuit")
        self.gridLayout_2.addWidget(self.pushButtonQuit, 3, 5, 1, 1)
        self.labelTitle = QtWidgets.QLabel(Dialog)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Maximum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.labelTitle.sizePolicy().hasHeightForWidth())
        self.labelTitle.setSizePolicy(sizePolicy)
        font = QtGui.QFont()
        font.setBold(True)
        font.setWeight(75)
        self.labelTitle.setFont(font)
        self.labelTitle.setObjectName("labelTitle")
        self.gridLayout_2.addWidget(self.labelTitle, 0, 1, 1, 6)
        spacerItem = QtWidgets.QSpacerItem(
            40, 20, QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_2.addItem(spacerItem, 3, 0, 1, 1)
        self.pushButtonSelect = QtWidgets.QPushButton(Dialog)
        self.pushButtonSelect.setObjectName("pushButtonSelect")
        self.gridLayout_2.addWidget(self.pushButtonSelect, 3, 6, 1, 1)
        self.labelMessage = QtWidgets.QLabel(Dialog)
        self.labelMessage.setWordWrap(True)
        self.labelMessage.setObjectName("labelMessage")
        self.gridLayout_2.addWidget(self.labelMessage, 1, 1, 1, 6)
        self.labelIcon = QtWidgets.QLabel(Dialog)
        self.labelIcon.setMinimumSize(QtCore.QSize(60, 60))
        self.labelIcon.setMaximumSize(QtCore.QSize(60, 60))
        self.labelIcon.setText("")
        self.labelIcon.setObjectName("labelIcon")
        self.gridLayout_2.addWidget(self.labelIcon, 0, 0, 2, 1,
                                    QtCore.Qt.AlignmentFlag.AlignTop)
        self.spinner = QProgressIndicator(Dialog)
        self.spinner.setMinimumSize(QtCore.QSize(20, 20))
        self.spinner.setMaximumSize(QtCore.QSize(20, 20))
        self.spinner.setObjectName("spinner")
        self.gridLayout_2.addWidget(self.spinner, 3, 1, 1, 1)
        spacerItem1 = QtWidgets.QSpacerItem(
            40, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_2.addItem(spacerItem1, 3, 2, 1, 2)
        self.gridLayout.addLayout(self.gridLayout_2, 0, 1, 1, 6)

        self.retranslateUi(Dialog)
        QtCore.QMetaObject.connectSlotsByName(Dialog)
        Dialog.setTabOrder(self.comboBoxPath, self.pushButtonUnlink)
        Dialog.setTabOrder(self.pushButtonUnlink, self.pushButtonQuit)
        Dialog.setTabOrder(self.pushButtonQuit, self.pushButtonSelect)
class Ui_Dialog(object):
    def setupUi(self, Dialog):
        Dialog.setObjectName("Dialog")
        Dialog.resize(688, 273)
        self.gridLayout = QtWidgets.QGridLayout(Dialog)
        self.gridLayout.setObjectName("gridLayout")
        self.gridLayout_2 = QtWidgets.QGridLayout()
        self.gridLayout_2.setContentsMargins(-1, -1, -1, 0)
        self.gridLayout_2.setSpacing(20)
        self.gridLayout_2.setObjectName("gridLayout_2")
        self.pushButtonUnlink = QtWidgets.QPushButton(Dialog)
        self.pushButtonUnlink.setObjectName("pushButtonUnlink")
        self.gridLayout_2.addWidget(self.pushButtonUnlink, 3, 4, 1, 1)
        self.comboBoxPath = QtWidgets.QComboBox(Dialog)
        self.comboBoxPath.setObjectName("comboBoxPath")
        self.gridLayout_2.addWidget(self.comboBoxPath, 2, 1, 1, 6)
        self.pushButtonQuit = QtWidgets.QPushButton(Dialog)
        self.pushButtonQuit.setObjectName("pushButtonQuit")
        self.gridLayout_2.addWidget(self.pushButtonQuit, 3, 5, 1, 1)
        self.labelTitle = QtWidgets.QLabel(Dialog)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Maximum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            self.labelTitle.sizePolicy().hasHeightForWidth())
        self.labelTitle.setSizePolicy(sizePolicy)
        font = QtGui.QFont()
        font.setBold(True)
        font.setWeight(75)
        self.labelTitle.setFont(font)
        self.labelTitle.setObjectName("labelTitle")
        self.gridLayout_2.addWidget(self.labelTitle, 0, 1, 1, 6)
        spacerItem = QtWidgets.QSpacerItem(
            40, 20, QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_2.addItem(spacerItem, 3, 0, 1, 1)
        self.pushButtonSelect = QtWidgets.QPushButton(Dialog)
        self.pushButtonSelect.setObjectName("pushButtonSelect")
        self.gridLayout_2.addWidget(self.pushButtonSelect, 3, 6, 1, 1)
        self.labelMessage = QtWidgets.QLabel(Dialog)
        self.labelMessage.setWordWrap(True)
        self.labelMessage.setObjectName("labelMessage")
        self.gridLayout_2.addWidget(self.labelMessage, 1, 1, 1, 6)
        self.labelIcon = QtWidgets.QLabel(Dialog)
        self.labelIcon.setMinimumSize(QtCore.QSize(60, 60))
        self.labelIcon.setMaximumSize(QtCore.QSize(60, 60))
        self.labelIcon.setText("")
        self.labelIcon.setObjectName("labelIcon")
        self.gridLayout_2.addWidget(self.labelIcon, 0, 0, 2, 1,
                                    QtCore.Qt.AlignmentFlag.AlignTop)
        self.spinner = QProgressIndicator(Dialog)
        self.spinner.setMinimumSize(QtCore.QSize(20, 20))
        self.spinner.setMaximumSize(QtCore.QSize(20, 20))
        self.spinner.setObjectName("spinner")
        self.gridLayout_2.addWidget(self.spinner, 3, 1, 1, 1)
        spacerItem1 = QtWidgets.QSpacerItem(
            40, 20, QtWidgets.QSizePolicy.Policy.Expanding,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout_2.addItem(spacerItem1, 3, 2, 1, 2)
        self.gridLayout.addLayout(self.gridLayout_2, 0, 1, 1, 6)

        self.retranslateUi(Dialog)
        QtCore.QMetaObject.connectSlotsByName(Dialog)
        Dialog.setTabOrder(self.comboBoxPath, self.pushButtonUnlink)
        Dialog.setTabOrder(self.pushButtonUnlink, self.pushButtonQuit)
        Dialog.setTabOrder(self.pushButtonQuit, self.pushButtonSelect)

    def retranslateUi(self, Dialog):
        _translate = QtCore.QCoreApplication.translate
        self.pushButtonUnlink.setText(_translate("Dialog", "Unlink"))
        self.pushButtonQuit.setText(_translate("Dialog", "Quit"))
        self.labelTitle.setText(
            _translate("Dialog", "Cannot find Dropbox folder"))
        self.pushButtonSelect.setText(_translate("Dialog", "Select"))
        self.labelMessage.setText(
            _translate(
                "Dialog",
                "<html><head/><body><p>Your Dropbox folder has been moved or deleted from its original location. Syncing will not work until you move it back.</p><p>To move it back, click &quot;Quit&quot; below, move the Dropbox folder back to its original location, and launch Maestral again. To re-download your Dropbox, please select a new folder below.</p><p>Select &quot;Unlink&quot; to unlink your Dropbox account from Maestral.</p></body></html>"
            ))
Exemplo n.º 7
0
    def setupUi(self, RelinkDialog):
        RelinkDialog.setObjectName("RelinkDialog")
        RelinkDialog.resize(470, 157)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            RelinkDialog.sizePolicy().hasHeightForWidth())
        RelinkDialog.setSizePolicy(sizePolicy)
        RelinkDialog.setMinimumSize(QtCore.QSize(470, 0))
        RelinkDialog.setMaximumSize(QtCore.QSize(470, 16777215))
        RelinkDialog.setWindowTitle("")
        self.gridLayout = QtWidgets.QGridLayout(RelinkDialog)
        self.gridLayout.setHorizontalSpacing(15)
        self.gridLayout.setObjectName("gridLayout")
        self.infoLabel = QtWidgets.QLabel(RelinkDialog)
        self.infoLabel.setMinimumSize(QtCore.QSize(0, 50))
        self.infoLabel.setWordWrap(True)
        self.infoLabel.setOpenExternalLinks(True)
        self.infoLabel.setObjectName("infoLabel")
        self.gridLayout.addWidget(self.infoLabel, 1, 1, 1, 6)
        self.iconLabel = QtWidgets.QLabel(RelinkDialog)
        self.iconLabel.setMinimumSize(QtCore.QSize(60, 60))
        self.iconLabel.setMaximumSize(QtCore.QSize(60, 60))
        self.iconLabel.setText("")
        self.iconLabel.setObjectName("iconLabel")
        self.gridLayout.addWidget(self.iconLabel, 0, 0, 2, 1,
                                  QtCore.Qt.AlignmentFlag.AlignTop)
        self.pushButtonUnlink = QtWidgets.QPushButton(RelinkDialog)
        self.pushButtonUnlink.setObjectName("pushButtonUnlink")
        self.gridLayout.addWidget(self.pushButtonUnlink, 3, 3, 1, 1)
        self.pushButtonLink = QtWidgets.QPushButton(RelinkDialog)
        self.pushButtonLink.setEnabled(False)
        self.pushButtonLink.setObjectName("pushButtonLink")
        self.gridLayout.addWidget(self.pushButtonLink, 3, 6, 1, 1)
        self.titleLabel = QtWidgets.QLabel(RelinkDialog)
        font = QtGui.QFont()
        font.setBold(True)
        font.setWeight(75)
        self.titleLabel.setFont(font)
        self.titleLabel.setObjectName("titleLabel")
        self.gridLayout.addWidget(self.titleLabel, 0, 1, 1, 6)
        self.lineEditAuthCode = QtWidgets.QLineEdit(RelinkDialog)
        self.lineEditAuthCode.setText("")
        self.lineEditAuthCode.setAlignment(
            QtCore.Qt.AlignmentFlag.AlignLeading
            | QtCore.Qt.AlignmentFlag.AlignLeft
            | QtCore.Qt.AlignmentFlag.AlignVCenter)
        self.lineEditAuthCode.setObjectName("lineEditAuthCode")
        self.gridLayout.addWidget(self.lineEditAuthCode, 2, 1, 1, 6)
        self.pushButtonCancel = QtWidgets.QPushButton(RelinkDialog)
        self.pushButtonCancel.setObjectName("pushButtonCancel")
        self.gridLayout.addWidget(self.pushButtonCancel, 3, 5, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(
            1, 20, QtWidgets.QSizePolicy.Policy.Fixed,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout.addItem(spacerItem, 3, 4, 1, 1)
        self.progressIndicator = QProgressIndicator(RelinkDialog)
        self.progressIndicator.setMinimumSize(QtCore.QSize(16, 16))
        self.progressIndicator.setMaximumSize(QtCore.QSize(16, 16))
        self.progressIndicator.setObjectName("progressIndicator")
        self.gridLayout.addWidget(self.progressIndicator, 3, 1, 1, 1,
                                  QtCore.Qt.AlignmentFlag.AlignVCenter)
        self.gridLayout.setRowStretch(1, 1)
        self.gridLayout.setRowStretch(2, 1)

        self.retranslateUi(RelinkDialog)
        QtCore.QMetaObject.connectSlotsByName(RelinkDialog)
        RelinkDialog.setTabOrder(self.lineEditAuthCode, self.pushButtonLink)
        RelinkDialog.setTabOrder(self.pushButtonLink, self.pushButtonCancel)
        RelinkDialog.setTabOrder(self.pushButtonCancel, self.pushButtonUnlink)
Exemplo n.º 8
0
class Ui_RelinkDialog(object):
    def setupUi(self, RelinkDialog):
        RelinkDialog.setObjectName("RelinkDialog")
        RelinkDialog.resize(470, 157)
        sizePolicy = QtWidgets.QSizePolicy(
            QtWidgets.QSizePolicy.Policy.Preferred,
            QtWidgets.QSizePolicy.Policy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(
            RelinkDialog.sizePolicy().hasHeightForWidth())
        RelinkDialog.setSizePolicy(sizePolicy)
        RelinkDialog.setMinimumSize(QtCore.QSize(470, 0))
        RelinkDialog.setMaximumSize(QtCore.QSize(470, 16777215))
        RelinkDialog.setWindowTitle("")
        self.gridLayout = QtWidgets.QGridLayout(RelinkDialog)
        self.gridLayout.setHorizontalSpacing(15)
        self.gridLayout.setObjectName("gridLayout")
        self.infoLabel = QtWidgets.QLabel(RelinkDialog)
        self.infoLabel.setMinimumSize(QtCore.QSize(0, 50))
        self.infoLabel.setWordWrap(True)
        self.infoLabel.setOpenExternalLinks(True)
        self.infoLabel.setObjectName("infoLabel")
        self.gridLayout.addWidget(self.infoLabel, 1, 1, 1, 6)
        self.iconLabel = QtWidgets.QLabel(RelinkDialog)
        self.iconLabel.setMinimumSize(QtCore.QSize(60, 60))
        self.iconLabel.setMaximumSize(QtCore.QSize(60, 60))
        self.iconLabel.setText("")
        self.iconLabel.setObjectName("iconLabel")
        self.gridLayout.addWidget(self.iconLabel, 0, 0, 2, 1,
                                  QtCore.Qt.AlignmentFlag.AlignTop)
        self.pushButtonUnlink = QtWidgets.QPushButton(RelinkDialog)
        self.pushButtonUnlink.setObjectName("pushButtonUnlink")
        self.gridLayout.addWidget(self.pushButtonUnlink, 3, 3, 1, 1)
        self.pushButtonLink = QtWidgets.QPushButton(RelinkDialog)
        self.pushButtonLink.setEnabled(False)
        self.pushButtonLink.setObjectName("pushButtonLink")
        self.gridLayout.addWidget(self.pushButtonLink, 3, 6, 1, 1)
        self.titleLabel = QtWidgets.QLabel(RelinkDialog)
        font = QtGui.QFont()
        font.setBold(True)
        font.setWeight(75)
        self.titleLabel.setFont(font)
        self.titleLabel.setObjectName("titleLabel")
        self.gridLayout.addWidget(self.titleLabel, 0, 1, 1, 6)
        self.lineEditAuthCode = QtWidgets.QLineEdit(RelinkDialog)
        self.lineEditAuthCode.setText("")
        self.lineEditAuthCode.setAlignment(
            QtCore.Qt.AlignmentFlag.AlignLeading
            | QtCore.Qt.AlignmentFlag.AlignLeft
            | QtCore.Qt.AlignmentFlag.AlignVCenter)
        self.lineEditAuthCode.setObjectName("lineEditAuthCode")
        self.gridLayout.addWidget(self.lineEditAuthCode, 2, 1, 1, 6)
        self.pushButtonCancel = QtWidgets.QPushButton(RelinkDialog)
        self.pushButtonCancel.setObjectName("pushButtonCancel")
        self.gridLayout.addWidget(self.pushButtonCancel, 3, 5, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(
            1, 20, QtWidgets.QSizePolicy.Policy.Fixed,
            QtWidgets.QSizePolicy.Policy.Minimum)
        self.gridLayout.addItem(spacerItem, 3, 4, 1, 1)
        self.progressIndicator = QProgressIndicator(RelinkDialog)
        self.progressIndicator.setMinimumSize(QtCore.QSize(16, 16))
        self.progressIndicator.setMaximumSize(QtCore.QSize(16, 16))
        self.progressIndicator.setObjectName("progressIndicator")
        self.gridLayout.addWidget(self.progressIndicator, 3, 1, 1, 1,
                                  QtCore.Qt.AlignmentFlag.AlignVCenter)
        self.gridLayout.setRowStretch(1, 1)
        self.gridLayout.setRowStretch(2, 1)

        self.retranslateUi(RelinkDialog)
        QtCore.QMetaObject.connectSlotsByName(RelinkDialog)
        RelinkDialog.setTabOrder(self.lineEditAuthCode, self.pushButtonLink)
        RelinkDialog.setTabOrder(self.pushButtonLink, self.pushButtonCancel)
        RelinkDialog.setTabOrder(self.pushButtonCancel, self.pushButtonUnlink)

    def retranslateUi(self, RelinkDialog):
        _translate = QtCore.QCoreApplication.translate
        self.infoLabel.setText(
            _translate(
                "RelinkDialog",
                "Your Dropbox access {0}. To continue syncing, please click <a href=\"{1}\">here</a> to retrieve a new authorization token from Dropbox and enter it below."
            ))
        self.pushButtonUnlink.setText(
            _translate("RelinkDialog", "Unlink and Quit"))
        self.pushButtonLink.setText(_translate("RelinkDialog", "Link"))
        self.titleLabel.setText(
            _translate("RelinkDialog", "Expired Dropbox access"))
        self.lineEditAuthCode.setPlaceholderText(
            _translate("RelinkDialog", "Authorization token"))
        self.pushButtonCancel.setText(_translate("RelinkDialog", "Quit"))