fix scrolbar in listview and fix view icons in listview
This commit is contained in:
Binary file not shown.
@@ -518,7 +518,7 @@ class CustomFileDialog(tk.Toplevel):
|
||||
else:
|
||||
icon, file_type, size = self.get_file_icon(
|
||||
name, 'small'), "Datei", self._format_size(stat.st_size)
|
||||
self.tree.insert("", "end", text=name, image=icon, values=(
|
||||
self.tree.insert("", "end", text=f" {name}", image=icon, values=(
|
||||
size, file_type, modified_time))
|
||||
except (FileNotFoundError, PermissionError):
|
||||
continue
|
||||
@@ -541,7 +541,7 @@ class CustomFileDialog(tk.Toplevel):
|
||||
if not self.tree.selection():
|
||||
return
|
||||
item_id = self.tree.selection()[0]
|
||||
item_text = self.tree.item(item_id, 'text')
|
||||
item_text = self.tree.item(item_id, 'text').strip()
|
||||
self.selected_file = os.path.join(self.current_dir, item_text)
|
||||
self.update_status_bar()
|
||||
|
||||
@@ -565,7 +565,7 @@ class CustomFileDialog(tk.Toplevel):
|
||||
if not self.tree.selection():
|
||||
return
|
||||
item_id = self.tree.selection()[0]
|
||||
item_text = self.tree.item(item_id, 'text')
|
||||
item_text = self.tree.item(item_id, 'text').strip()
|
||||
path = os.path.join(self.current_dir, item_text)
|
||||
if self._handle_unsupported_file(path):
|
||||
return
|
||||
|
Reference in New Issue
Block a user