Skip to content

Commit

Permalink
fix typo, unload record on BackSpace
Browse files Browse the repository at this point in the history
  • Loading branch information
piotrj committed Jan 3, 2024
1 parent 1eee52b commit 1f79570
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/librer.py
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ def __init__(self,cwd):
self.status_records_all.pack(fill='x',expand=0,side='left')
self.status_records_all_configure = lambda x : self.status_records_all.configure(image = self.ico_records_all, text = x,compound='left')
self.widget_tooltip(self.status_records_all,'All records in repository')
self.status_records_all.bind("<ButtonPress-1>", lambda event : self.unload_recod() )
self.status_records_all.bind("<ButtonPress-1>", lambda event : self.unload_record() )
self.status_records_all.bind("<Double-Button-1>", lambda event : self.unload_all_recods() )

self.status_record=Label(status_frame,image=self.ico_record,text='--',width=200,borderwidth=2,bg=self.bg_color,relief='groove',anchor='w')
Expand Down Expand Up @@ -727,6 +727,8 @@ def help_cascade_post():
self_main_bind('<F3>', lambda event : self.find_next())
self_main_bind('<Shift-F3>', lambda event : self.find_prev())

self_main_bind('<BackSpace>', lambda event : self.unload_record())

gc_collect()
gc_enable()

Expand Down Expand Up @@ -3935,7 +3937,7 @@ def record_info(self):
@block_actions_processing
@gui_block
@logwrapper
def unload_recod(self,record=None):
def unload_record(self,record=None):
if not record:
record = self.current_record

Expand All @@ -3959,7 +3961,7 @@ def unload_recod(self,record=None):
@logwrapper
def unload_all_recods(self):
for record in librer_core.records:
self.unload_recod(record)
self.unload_record(record)

@logwrapper
def show_log(self):
Expand Down

0 comments on commit 1f79570

Please sign in to comment.