| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
from PyQt5 import QtCore, QtGui, QtWidgets |
| 11 |
from breezy.plugins.qbrz.lib.i18n import gettext |
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
class Ui_NewWorkingTreeForm(object): |
| 16 |
def setupUi(self, NewWorkingTreeForm): |
| 17 |
NewWorkingTreeForm.setObjectName("NewWorkingTreeForm") |
| 18 |
NewWorkingTreeForm.resize(479, 385) |
| 19 |
self.verticalLayout = QtWidgets.QVBoxLayout(NewWorkingTreeForm) |
| 20 |
self.verticalLayout.setContentsMargins(9, 9, 9, 9) |
| 21 |
self.verticalLayout.setObjectName("verticalLayout") |
| 22 |
self.groupBox = QtWidgets.QGroupBox(NewWorkingTreeForm) |
| 23 |
self.groupBox.setObjectName("groupBox") |
| 24 |
self.gridLayout = QtWidgets.QGridLayout(self.groupBox) |
| 25 |
self.gridLayout.setObjectName("gridLayout") |
| 26 |
self.label_4 = QtWidgets.QLabel(self.groupBox) |
| 27 |
self.label_4.setObjectName("label_4") |
| 28 |
self.gridLayout.addWidget(self.label_4, 0, 0, 1, 2) |
| 29 |
self.from_location = QtWidgets.QComboBox(self.groupBox) |
| 30 |
self.from_location.setEditable(True) |
| 31 |
self.from_location.setSizeAdjustPolicy(QtWidgets.QComboBox.AdjustToMinimumContentsLength) |
| 32 |
self.from_location.setObjectName("from_location") |
| 33 |
self.gridLayout.addWidget(self.from_location, 1, 0, 1, 1) |
| 34 |
self.from_picker = QtWidgets.QPushButton(self.groupBox) |
| 35 |
self.from_picker.setObjectName("from_picker") |
| 36 |
self.gridLayout.addWidget(self.from_picker, 1, 1, 1, 1) |
| 37 |
self.label = QtWidgets.QLabel(self.groupBox) |
| 38 |
font = QtGui.QFont() |
| 39 |
font.setUnderline(False) |
| 40 |
self.label.setFont(font) |
| 41 |
self.label.setOpenExternalLinks(False) |
| 42 |
self.label.setObjectName("label") |
| 43 |
self.gridLayout.addWidget(self.label, 2, 0, 1, 2) |
| 44 |
self.to_location = QtWidgets.QLineEdit(self.groupBox) |
| 45 |
self.to_location.setObjectName("to_location") |
| 46 |
self.gridLayout.addWidget(self.to_location, 3, 0, 1, 1) |
| 47 |
self.to_picker = QtWidgets.QPushButton(self.groupBox) |
| 48 |
self.to_picker.setObjectName("to_picker") |
| 49 |
self.gridLayout.addWidget(self.to_picker, 3, 1, 1, 1) |
| 50 |
self.verticalLayout.addWidget(self.groupBox) |
| 51 |
self.groupBox_3 = QtWidgets.QGroupBox(NewWorkingTreeForm) |
| 52 |
self.groupBox_3.setObjectName("groupBox_3") |
| 53 |
self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox_3) |
| 54 |
self.gridLayout_2.setObjectName("gridLayout_2") |
| 55 |
self.but_checkout = QtWidgets.QRadioButton(self.groupBox_3) |
| 56 |
self.but_checkout.setChecked(True) |
| 57 |
self.but_checkout.setObjectName("but_checkout") |
| 58 |
self.gridLayout_2.addWidget(self.but_checkout, 0, 0, 1, 2) |
| 59 |
spacerItem = QtWidgets.QSpacerItem(18, 20, QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Minimum) |
| 60 |
self.gridLayout_2.addItem(spacerItem, 1, 0, 1, 1) |
| 61 |
self.but_lightweight = QtWidgets.QCheckBox(self.groupBox_3) |
| 62 |
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Fixed) |
| 63 |
sizePolicy.setHorizontalStretch(1) |
| 64 |
sizePolicy.setVerticalStretch(0) |
| 65 |
sizePolicy.setHeightForWidth(self.but_lightweight.sizePolicy().hasHeightForWidth()) |
| 66 |
self.but_lightweight.setSizePolicy(sizePolicy) |
| 67 |
self.but_lightweight.setObjectName("but_lightweight") |
| 68 |
self.gridLayout_2.addWidget(self.but_lightweight, 1, 1, 1, 1) |
| 69 |
self.but_branch = QtWidgets.QRadioButton(self.groupBox_3) |
| 70 |
self.but_branch.setObjectName("but_branch") |
| 71 |
self.gridLayout_2.addWidget(self.but_branch, 2, 0, 1, 2) |
| 72 |
spacerItem1 = QtWidgets.QSpacerItem(18, 20, QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Minimum) |
| 73 |
self.gridLayout_2.addItem(spacerItem1, 3, 0, 1, 1) |
| 74 |
self.but_stacked = QtWidgets.QCheckBox(self.groupBox_3) |
| 75 |
self.but_stacked.setEnabled(False) |
| 76 |
self.but_stacked.setObjectName("but_stacked") |
| 77 |
self.gridLayout_2.addWidget(self.but_stacked, 3, 1, 1, 1) |
| 78 |
self.link_help = QtWidgets.QLabel(self.groupBox_3) |
| 79 |
font = QtGui.QFont() |
| 80 |
font.setUnderline(True) |
| 81 |
self.link_help.setFont(font) |
| 82 |
self.link_help.setCursor(QtGui.QCursor(QtCore.Qt.ArrowCursor)) |
| 83 |
self.link_help.setTextFormat(QtCore.Qt.RichText) |
| 84 |
self.link_help.setOpenExternalLinks(False) |
| 85 |
self.link_help.setTextInteractionFlags(QtCore.Qt.TextBrowserInteraction) |
| 86 |
self.link_help.setObjectName("link_help") |
| 87 |
self.gridLayout_2.addWidget(self.link_help, 4, 0, 1, 2) |
| 88 |
self.verticalLayout.addWidget(self.groupBox_3) |
| 89 |
self.groupBox_2 = QtWidgets.QGroupBox(NewWorkingTreeForm) |
| 90 |
self.groupBox_2.setObjectName("groupBox_2") |
| 91 |
self.gridLayout_3 = QtWidgets.QGridLayout(self.groupBox_2) |
| 92 |
self.gridLayout_3.setObjectName("gridLayout_3") |
| 93 |
self.but_rev_tip = QtWidgets.QRadioButton(self.groupBox_2) |
| 94 |
self.but_rev_tip.setChecked(True) |
| 95 |
self.but_rev_tip.setObjectName("but_rev_tip") |
| 96 |
self.gridLayout_3.addWidget(self.but_rev_tip, 0, 0, 1, 2) |
| 97 |
self.but_rev_specific = QtWidgets.QRadioButton(self.groupBox_2) |
| 98 |
self.but_rev_specific.setObjectName("but_rev_specific") |
| 99 |
self.gridLayout_3.addWidget(self.but_rev_specific, 1, 0, 1, 1) |
| 100 |
self.revision = QtWidgets.QLineEdit(self.groupBox_2) |
| 101 |
self.revision.setEnabled(False) |
| 102 |
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) |
| 103 |
sizePolicy.setHorizontalStretch(1) |
| 104 |
sizePolicy.setVerticalStretch(0) |
| 105 |
sizePolicy.setHeightForWidth(self.revision.sizePolicy().hasHeightForWidth()) |
| 106 |
self.revision.setSizePolicy(sizePolicy) |
| 107 |
self.revision.setObjectName("revision") |
| 108 |
self.gridLayout_3.addWidget(self.revision, 1, 1, 1, 1) |
| 109 |
self.but_show_log = QtWidgets.QPushButton(self.groupBox_2) |
| 110 |
self.but_show_log.setEnabled(False) |
| 111 |
self.but_show_log.setObjectName("but_show_log") |
| 112 |
self.gridLayout_3.addWidget(self.but_show_log, 1, 3, 1, 1) |
| 113 |
self.link_help_revisions = QtWidgets.QLabel(self.groupBox_2) |
| 114 |
self.link_help_revisions.setObjectName("link_help_revisions") |
| 115 |
self.gridLayout_3.addWidget(self.link_help_revisions, 1, 2, 1, 1) |
| 116 |
self.verticalLayout.addWidget(self.groupBox_2) |
| 117 |
|
| 118 |
self.retranslateUi(NewWorkingTreeForm) |
| 119 |
self.link_help.linkActivated['QString'].connect(NewWorkingTreeForm.linkActivated) |
| 120 |
self.link_help_revisions.linkActivated['QString'].connect(NewWorkingTreeForm.linkActivated) |
| 121 |
self.but_checkout.toggled['bool'].connect(self.but_lightweight.setEnabled) |
| 122 |
self.but_branch.toggled['bool'].connect(self.but_stacked.setEnabled) |
| 123 |
self.but_rev_specific.toggled['bool'].connect(self.revision.setEnabled) |
| 124 |
NewWorkingTreeForm.disableUi['bool'].connect(self.groupBox.setDisabled) |
| 125 |
NewWorkingTreeForm.disableUi['bool'].connect(self.groupBox_3.setDisabled) |
| 126 |
NewWorkingTreeForm.disableUi['bool'].connect(self.groupBox_2.setDisabled) |
| 127 |
QtCore.QMetaObject.connectSlotsByName(NewWorkingTreeForm) |
| 128 |
|
| 129 |
def retranslateUi(self, NewWorkingTreeForm): |
| 130 |
_translate = QtCore.QCoreApplication.translate |
| 131 |
NewWorkingTreeForm.setWindowTitle(_translate("NewWorkingTreeForm", "Create a new Bazaar Working Tree")) |
| 132 |
self.groupBox.setTitle(_translate("NewWorkingTreeForm", "Branch")) |
| 133 |
self.label_4.setText(_translate("NewWorkingTreeForm", "Branch source (enter a URL or select a local directory with an existing branch)")) |
| 134 |
self.from_picker.setText(_translate("NewWorkingTreeForm", "Browse...")) |
| 135 |
self.label.setText(_translate("NewWorkingTreeForm", "Local directory where the working tree will be created")) |
| 136 |
self.to_picker.setText(_translate("NewWorkingTreeForm", "Browse...")) |
| 137 |
self.groupBox_3.setTitle(_translate("NewWorkingTreeForm", "Working Tree Options")) |
| 138 |
self.but_checkout.setText(_translate("NewWorkingTreeForm", "Create a checkout")) |
| 139 |
self.but_lightweight.setToolTip(_translate("NewWorkingTreeForm", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n" |
| 140 |
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n" |
| 141 |
"p, li { white-space: pre-wrap; }\n" |
| 142 |
"</style></head><body style=\" font-family:\'MS Shell Dlg 2\'; font-size:8.25pt; font-weight:400; font-style:normal;\">\n" |
| 143 |
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"><span style=\" font-style:italic;\">Lightweight checkouts </span>depend on access to the branch for every operation.</p>\n" |
| 144 |
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">Normal checkouts can perform common operations like diff and status without such access, and also support local commits.</p>\n" |
| 145 |
"<p style=\"-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\"></p></body></html>")) |
| 146 |
self.but_lightweight.setText(_translate("NewWorkingTreeForm", "Light-weight checkout")) |
| 147 |
self.but_branch.setText(_translate("NewWorkingTreeForm", "Make a local copy of the branch")) |
| 148 |
self.but_stacked.setToolTip(_translate("NewWorkingTreeForm", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n" |
| 149 |
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n" |
| 150 |
"p, li { white-space: pre-wrap; }\n" |
| 151 |
"</style></head><body style=\" font-family:\'MS Shell Dlg 2\'; font-size:8.25pt; font-weight:400; font-style:normal;\">\n" |
| 152 |
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;\">A <span style=\" font-style:italic;\">stacked branch</span> only stores information not in the source branch, and as such, depends on the availability of the source branch</p></body></html>")) |
| 153 |
self.but_stacked.setText(_translate("NewWorkingTreeForm", "Create a stacked branch referring to the source branch")) |
| 154 |
self.link_help.setToolTip(_translate("NewWorkingTreeForm", "Click a link for more information about checkouts and branches.")) |
| 155 |
self.link_help.setText(_translate("NewWorkingTreeForm", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n" |
| 156 |
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n" |
| 157 |
"p, li { white-space: pre-wrap; }\n" |
| 158 |
"</style></head><body style=\" font-family:\'MS Shell Dlg 2\'; font-size:8.25pt; font-weight:400; font-style:normal;\">\n" |
| 159 |
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;\">Tell me more about <a href=\"bzrtopic:checkouts\"><span style=\" text-decoration: underline; color:#0000ff;\">checkouts</span></a> and <a href=\"bzrtopic:branches\"><span style=\" text-decoration: underline; color:#0000ff;\">branches</span></a></p></body></html>")) |
| 160 |
self.groupBox_2.setTitle(_translate("NewWorkingTreeForm", "Revision")) |
| 161 |
self.but_rev_tip.setText(_translate("NewWorkingTreeForm", "Most recent (tip) revision")) |
| 162 |
self.but_rev_specific.setText(_translate("NewWorkingTreeForm", "Revision:")) |
| 163 |
self.but_show_log.setText(_translate("NewWorkingTreeForm", "Show Log...")) |
| 164 |
self.link_help_revisions.setText(_translate("NewWorkingTreeForm", "<!DOCTYPE HTML PUBLIC \"-//W3C//DTD HTML 4.0//EN\" \"http://www.w3.org/TR/REC-html40/strict.dtd\">\n" |
| 165 |
"<html><head><meta name=\"qrichtext\" content=\"1\" /><style type=\"text/css\">\n" |
| 166 |
"p, li { white-space: pre-wrap; }\n" |
| 167 |
"</style></head><body style=\" font-family:\'MS Shell Dlg 2\'; font-size:8.25pt; font-weight:400; font-style:normal;\">\n" |
| 168 |
"<p style=\" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;\"><a href=\"bzrtopic:revisionspec\"><span style=\" text-decoration: underline; color:#0000ff;\">About revision identifiers</span></a></p></body></html>")) |