mirror of
https://github.com/wassname/sloth.git
synced 2026-07-09 18:21:07 +08:00
Keep selection in treeview in sync with current image
This commit is contained in:
@@ -69,6 +69,8 @@ class MainWindow(QMainWindow):
|
||||
elif isinstance(new_image, ImageFileModelItem):
|
||||
self.controls.setFilename(os.path.basename(new_image['filename']))
|
||||
|
||||
self.selectionmodel.setCurrentIndex(index, QItemSelectionModel.ClearAndSelect|QItemSelectionModel.Rows)
|
||||
|
||||
def onScaleChanged(self, scale):
|
||||
self.zoominfo.setText("%.2f%%" % (100 * scale, ))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user