MCPcopy Index your code
hub / github.com/python/cpython / helplist_item_edit

Method helplist_item_edit

Lib/idlelib/configdialog.py:2169–2187  ·  view source on GitHub ↗

Handle edit button for the help list. Query with existing help source information and update config if the values are changed.

(self)

Source from the content-addressed store, hash-verified

2167 self.update_help_changes()
2168
2169 def helplist_item_edit(self):
2170 """Handle edit button for the help list.
2171
2172 Query with existing help source information and update
2173 config if the values are changed.
2174 """
2175 item_index = self.helplist.index(ANCHOR)
2176 help_source = self.user_helplist[item_index]
2177 new_help_source = HelpSource(
2178 self, 'Edit Help Source',
2179 menuitem=help_source[0],
2180 filepath=help_source[1],
2181 ).result
2182 if new_help_source and new_help_source != help_source:
2183 self.user_helplist[item_index] = new_help_source
2184 self.helplist.delete(item_index)
2185 self.helplist.insert(item_index, new_help_source[0])
2186 self.update_help_changes()
2187 self.set_add_delete_state() # Selected will be un-selected
2188
2189 def helplist_item_remove(self):
2190 """Handle remove button for the help list.

Callers 1

Calls 6

update_help_changesMethod · 0.95
set_add_delete_stateMethod · 0.95
HelpSourceClass · 0.90
indexMethod · 0.45
deleteMethod · 0.45
insertMethod · 0.45

Tested by 1