WIP trying things
This commit is contained in:
parent
7b2b7fada5
commit
d267b32c0d
@ -88,15 +88,15 @@ class NoSelectDelegate(QStyledItemDelegate):
|
|||||||
def createEditor(self, parent, option, index):
|
def createEditor(self, parent, option, index):
|
||||||
editor = super().createEditor(parent, option, index)
|
editor = super().createEditor(parent, option, index)
|
||||||
if isinstance(editor, QLineEdit):
|
if isinstance(editor, QLineEdit):
|
||||||
def deselect():
|
# def deselect():
|
||||||
# Important! First disconnect, otherwise editor.deselect()
|
# # Important! First disconnect, otherwise editor.deselect()
|
||||||
# will call again this function
|
# # will call again this function
|
||||||
editor.selectionChanged.disconnect(deselect)
|
# editor.selectionChanged.disconnect(deselect)
|
||||||
editor.deselect()
|
# editor.deselect()
|
||||||
editor.selectionChanged.connect(deselect)
|
# editor.selectionChanged.connect(deselect)
|
||||||
# self.old_editor = editor
|
# self.old_editor = editor
|
||||||
# textedit = QTextEdit(parent)
|
textedit = QTextEdit(parent)
|
||||||
# textedit.setPlainText(editor.text())
|
textedit.setPlainText(editor.text())
|
||||||
return textedit
|
return textedit
|
||||||
|
|
||||||
# def destroyEditor(self, editor, index):
|
# def destroyEditor(self, editor, index):
|
||||||
@ -594,12 +594,12 @@ class PlaylistTab(QTableWidget):
|
|||||||
|
|
||||||
# As we have track info, any notes should be contained in
|
# As we have track info, any notes should be contained in
|
||||||
# the notes column
|
# the notes column
|
||||||
temp_item = QTableWidgetItem()
|
notes_item = QTableWidgetItem(row_data.note)
|
||||||
self.setItem(row, columns['row_notes'].idx, temp_item)
|
self.setItem(row, columns['row_notes'].idx, notes_item)
|
||||||
notes_item = QTextEdit(row_data.note)
|
# notes_item = QTextEdit(row_data.note)
|
||||||
minimum_size = QSize(25, 25)
|
# minimum_size = QSize(25, 25)
|
||||||
notes_item.setMinimumSize(minimum_size)
|
# notes_item.setMinimumSize(minimum_size)
|
||||||
self.setCellWidget(row, columns['row_notes'].idx, notes_item)
|
# self.setCellWidget(row, columns['row_notes'].idx, notes_item)
|
||||||
|
|
||||||
last_playtime = Playdates.last_played(session, row_data.track.id)
|
last_playtime = Playdates.last_played(session, row_data.track.id)
|
||||||
last_played_str = get_relative_date(last_playtime)
|
last_played_str = get_relative_date(last_playtime)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user