Skip to content

Commit

Permalink
debug gr tree
Browse files Browse the repository at this point in the history
  • Loading branch information
Kvieta1990 committed Oct 14, 2022
1 parent 5af9399 commit e87dd0a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
1 change: 1 addition & 0 deletions addie/calculate_gr/event_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ def generate_gr_step1(main_window):
generate_gr_step2(main_window,
sq_ws_name_list=sq_ws_name_list)

gr_widgets_status(main_window, True)

def generate_gr_step2(main_window, sq_ws_name_list):
"""Generate G(r) from specified S(Q) workspaces
Expand Down
4 changes: 3 additions & 1 deletion addie/calculate_gr/gofrtree.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ def pop_up_menu(self):
print('[Error] Nodes of different levels are selected.')

if leaf_level == 1:
self.removeAction(self._action_remove_plot)
self.addAction(self._action_plot)
self.addAction(self._action_ipython)
self.addAction(self._action_delete)
Expand Down Expand Up @@ -205,7 +206,8 @@ def is_gr_empty(self):
gr_exists = False
for key in self._leafDict.keys():
if key.startswith('G(r)'):
gr_exists = True
if len(self._leafDict[key]) > 0:
gr_exists = True
return not gr_exists

def is_sofq_empty(self):
Expand Down

0 comments on commit e87dd0a

Please sign in to comment.