11# -*- coding: utf-8 -*-
22"""
33tkfilebrowser - Alternative to filedialog for Tkinter
4- Copyright 2017 Juliette Monsel <j_4321@protonmail.com>
4+ Copyright 2017-2018 Juliette Monsel <j_4321@protonmail.com>
55
66tkfilebrowser is free software: you can redistribute it and/or modify
77it under the terms of the GNU General Public License as published by
@@ -141,8 +141,6 @@ def __init__(self, parent, initialdir="", initialfile="", mode="openfile",
141141 default = 'white' )
142142 fg = style .lookup ('TLabel' , 'foreground' , default = 'black' )
143143 active_bg = style .lookup ('TButton' , 'background' , ('active' ,))
144- # active_fg = style.lookup('TButton', 'foreground', ('active',))
145- # disabled_fg = style.lookup('TButton', 'foreground', ('disabled',))
146144 sel_bg = style .lookup ('Treeview' , 'background' , ('selected' ,))
147145 sel_fg = style .lookup ('Treeview' , 'foreground' , ('selected' ,))
148146 self .option_add ('*TCombobox*Listbox.selectBackground' , sel_bg )
@@ -277,13 +275,13 @@ def __init__(self, parent, initialdir="", initialfile="", mode="openfile",
277275 scroll_left .grid (row = 0 , column = 1 , sticky = "ns" )
278276 self .left_tree .configure (yscrollcommand = scroll_left .set )
279277
280- # --- list devices and bookmarked locations
281- # recent
278+ # list devices and bookmarked locations
279+ # -------- recent
282280 self .left_tree .insert ("" , "end" , iid = "recent" , text = _ ("Recent" ),
283281 image = self .im_recent )
284282 wrapper .add_tooltip ("recent" , _ ("Recently used" ))
285283
286- # devices
284+ # -------- devices
287285 devices = psutil .disk_partitions ()
288286
289287 for d in devices :
@@ -296,13 +294,13 @@ def __init__(self, parent, initialdir="", initialfile="", mode="openfile",
296294 image = self .im_drive )
297295 wrapper .add_tooltip (m , m )
298296
299- # home
297+ # -------- home
300298 home = expanduser ("~" )
301299 self .left_tree .insert ("" , "end" , iid = home , image = self .im_home ,
302300 text = split (home )[- 1 ])
303301 wrapper .add_tooltip (home , home )
304302
305- # desktop
303+ # -------- desktop
306304 try :
307305 desktop = check_output (['xdg-users-dir' , 'DESKTOP' ]).decode ().strip ()
308306 except Exception :
@@ -314,7 +312,7 @@ def __init__(self, parent, initialdir="", initialfile="", mode="openfile",
314312 text = split (desktop )[- 1 ])
315313 wrapper .add_tooltip (desktop , desktop )
316314
317- # bookmarks
315+ # -------- bookmarks
318316 path_bm = join (home , ".config" , "gtk-3.0" , "bookmarks" )
319317 path_bm2 = join (home , ".gtk-bookmarks" ) # old location
320318 if exists (path_bm ):
0 commit comments