Since clicking to get an IDLE context menu moves the cursor,
any text selection should be and now is cleared.
(cherry picked from commit
4ca060d8ad7c6df1fd4df30f9a14f6aa35380c09)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
======================================
+bpo-39885: Since clicking to get an IDLE context menu moves the
+cursor, any text selection should be and now is cleared.
+
bpo-39852: Edit "Go to line" now clears any selection, preventing
accidental deletion. It also updates Ln and Col on the status bar.
rmenu = None
def right_menu_event(self, event):
+ self.text.tag_remove("sel", "1.0", "end")
self.text.mark_set("insert", "@%d,%d" % (event.x, event.y))
if not self.rmenu:
self.make_rmenu()
--- /dev/null
+Since clicking to get an IDLE context menu moves the cursor,
+any text selection should be and now is cleared.