333 itm.setData(0, Qt.ItemDataRole.UserRole, filePath) |
333 itm.setData(0, Qt.ItemDataRole.UserRole, filePath) |
334 if name.endswith("/"): |
334 if name.endswith("/"): |
335 itm.setChildIndicatorPolicy( |
335 itm.setChildIndicatorPolicy( |
336 QTreeWidgetItem.ChildIndicatorPolicy.ShowIndicator |
336 QTreeWidgetItem.ChildIndicatorPolicy.ShowIndicator |
337 ) |
337 ) |
|
338 else: |
|
339 self.deviceFileTreeWidget.clear() |
|
340 |
338 self.deviceFileTreeWidget.header().resizeSections( |
341 self.deviceFileTreeWidget.header().resizeSections( |
339 QHeaderView.ResizeMode.ResizeToContents |
342 QHeaderView.ResizeMode.ResizeToContents |
340 ) |
343 ) |
341 |
344 |
342 if self.__expandedDeviceEntries: |
345 if self.__expandedDeviceEntries: |