mirror of
https://github.com/HIllya51/LunaTranslator.git
synced 2024-12-29 16:44:13 +08:00
fix
This commit is contained in:
parent
c5d195a2f7
commit
6c4aa72b07
@ -1620,7 +1620,7 @@ class listediter(QDialog):
|
|||||||
QHeaderView.ResizeMode.ResizeToContents
|
QHeaderView.ResizeMode.ResizeToContents
|
||||||
)
|
)
|
||||||
table.horizontalHeader().setStretchLastSection(True)
|
table.horizontalHeader().setStretchLastSection(True)
|
||||||
if ispathsedit:
|
if not (ispathsedit is None):
|
||||||
table.setEditTriggers(QAbstractItemView.EditTrigger.NoEditTriggers)
|
table.setEditTriggers(QAbstractItemView.EditTrigger.NoEditTriggers)
|
||||||
table.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectRows)
|
table.setSelectionBehavior(QAbstractItemView.SelectionBehavior.SelectRows)
|
||||||
table.setSelectionMode((QAbstractItemView.SelectionMode.SingleSelection))
|
table.setSelectionMode((QAbstractItemView.SelectionMode.SingleSelection))
|
||||||
@ -1671,7 +1671,9 @@ class listediter(QDialog):
|
|||||||
|
|
||||||
def click1(self):
|
def click1(self):
|
||||||
|
|
||||||
if self.ispathsedit:
|
if self.ispathsedit is None:
|
||||||
|
self.hcmodel.insertRow(0, [QStandardItem("")])
|
||||||
|
else:
|
||||||
openfiledirectory(
|
openfiledirectory(
|
||||||
"",
|
"",
|
||||||
multi=False,
|
multi=False,
|
||||||
@ -1680,8 +1682,6 @@ class listediter(QDialog):
|
|||||||
filter1=self.ispathsedit.get("filter1", "*.*"),
|
filter1=self.ispathsedit.get("filter1", "*.*"),
|
||||||
callback=self.__cb,
|
callback=self.__cb,
|
||||||
)
|
)
|
||||||
else:
|
|
||||||
self.hcmodel.insertRow(0, [QStandardItem("")])
|
|
||||||
|
|
||||||
|
|
||||||
class listediterline(QLineEdit):
|
class listediterline(QLineEdit):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user