mirror of
https://github.com/onionshare/onionshare.git
synced 2024-12-29 01:06:16 -05:00
Merge branch 'delete_multiple_items' of https://github.com/mig5/onionshare into mig5-delete_multiple_items
This commit is contained in:
commit
963ed0ef41
@ -35,6 +35,7 @@ class FileList(QtWidgets.QListWidget):
|
|||||||
self.setAcceptDrops(True)
|
self.setAcceptDrops(True)
|
||||||
self.setIconSize(QtCore.QSize(32, 32))
|
self.setIconSize(QtCore.QSize(32, 32))
|
||||||
self.setSortingEnabled(True)
|
self.setSortingEnabled(True)
|
||||||
|
self.setSelectionMode(QtWidgets.QAbstractItemView.ExtendedSelection)
|
||||||
|
|
||||||
class DropHereLabel(QtWidgets.QLabel):
|
class DropHereLabel(QtWidgets.QLabel):
|
||||||
"""
|
"""
|
||||||
@ -253,9 +254,11 @@ class FileSelection(QtWidgets.QVBoxLayout):
|
|||||||
"""
|
"""
|
||||||
Delete button clicked
|
Delete button clicked
|
||||||
"""
|
"""
|
||||||
current_row = self.file_list.currentRow()
|
selected = self.file_list.selectedItems()
|
||||||
self.file_list.filenames.pop(current_row)
|
for item in selected:
|
||||||
self.file_list.takeItem(current_row)
|
itemrow = self.file_list.row(item)
|
||||||
|
self.file_list.filenames.pop(itemrow)
|
||||||
|
self.file_list.takeItem(itemrow)
|
||||||
self.update()
|
self.update()
|
||||||
|
|
||||||
def server_started(self):
|
def server_started(self):
|
||||||
|
Loading…
Reference in New Issue
Block a user