[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-12-07 Thread Ronald Oussoren
Ronald Oussoren added the comment: Merged to 3.1.x in r87120, merged to 2.7. in r87121. Ned: thanks for looking into this, doubly so because Tk-on-OSX is involved. -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-12-07 Thread Ronald Oussoren
Ronald Oussoren added the comment: Ned: never mind the command callback has a different signature than a keybinding. Committed the patch for 3.2 in r87119. -- ___ Python tracker _

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-12-07 Thread Ronald Oussoren
Ronald Oussoren added the comment: Ned: why does the patch change the signature of close_all_callback? -def close_all_callback(self, event): +def close_all_callback(self, *args, **kwds): -- ___ Python tracker

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-11-27 Thread Ned Deily
Ned Deily added the comment: Considering the discussion on the idle-dev list back in October about this issue, I think this low-risk, high-benefit fix should be going into all three upcoming releases. -- nosy: +benjamin.peterson, georg.brandl priority: high -> critical __

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-25 Thread Ned Deily
Ned Deily added the comment: BTW, the patched IDLEs were tested on 2.7 and py3k (3.2a3+) on 10.4, 10.5, and 10.6 with the Apple-supplied Tk 8.4 (all), the Apple-supplied Tk 8.5 (available only in 10.6), ActiveState Tk 8.4 (all), and ActiveState 8.5 (all). And the patches have no affect nor a

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-25 Thread Ned Deily
Changes by Ned Deily : Added file: http://bugs.python.org/file19367/issue10107-27.patch ___ Python tracker ___ ___ Python-bugs-list mailing li

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-25 Thread Ned Deily
Ned Deily added the comment: The attached patches implement an "exit" callback for IDLE on OS X that ensures IDLE will not terminate from an application Quit command without giving the opportunity to save files. -- assignee: ned.deily -> ronaldoussoren components: +Macintosh keywords:

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-15 Thread Ned Deily
Ned Deily added the comment: Looks like the "exit" callback will work for IDLE but there are the usual edge cases and odd differences among the various branches and build options to work through and fix up. Patch forthcoming. -- ___ Python tracker

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-15 Thread Ned Deily
Ned Deily added the comment: It looks like the '::tk::mac::Quit' callback does not exist in the Apple-supplied Tk 8.4.7 in OS X 10.5 and 10.4, although it does work with the Apple-supplied Tk 8.4.19(?) and 8.5 in 10.6 and with a current ActiveState 8.4.19 on 10.4 through 10.6. However, inste

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-15 Thread Tal Einat
Tal Einat added the comment: Note that some discussion about this issue is taking place on the idle-dev mailing list. Bruce Sherwood found the line "root.bind('<>', flist.close_all_callback)", which seems to be an unsuccessful attempt to achieve the wanted behavior. Kevin Walzer mentioned t

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-15 Thread Kevin Walzer
Kevin Walzer added the comment: Ronald--I think it works with both 8.4 and 8.5. -- ___ Python tracker ___ ___ Python-bugs-list mailin

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-15 Thread Ronald Oussoren
Ronald Oussoren added the comment: Kevin, which versions of Tk does this work with? IDLE should at least work with the versions of Tk 8.4 and 8.5 that Apple ships with OSX 10.4, 10.5 and 10.6 (the last one being the only one with built-in support for Tk 8.5) -- ___

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-15 Thread Kevin Walzer
Kevin Walzer added the comment: Try something like this: root.createcommand('::tk::mac::Quit', ) This will map whatever function IDLE calls to prompt the user to save data before closing, to the Apple quit event. -- nosy: +wordtech ___ Python tra

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-15 Thread Ronald Oussoren
Changes by Ronald Oussoren : -- nosy: +ronaldoussoren ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://ma

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-14 Thread Ned Deily
Ned Deily added the comment: The problem is that, by default on OS X, Tkinter uses Tk/Aqua which is itself a bona-fide OS X application and it creates the default menu options including a standard application quit. Looks like IDLE needs to register a hook provided by Tk/Aqua for a "quit" cal

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-14 Thread Brian Curtin
Changes by Brian Curtin : -- nosy: +taleinat ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-14 Thread Ned Deily
Changes by Ned Deily : -- versions: +Python 2.7, Python 3.1, Python 3.2 -Python 2.6 ___ Python tracker ___ ___ Python-bugs-list mailin

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-14 Thread Ned Deily
Changes by Ned Deily : -- nosy: +ned.deily stage: -> needs patch ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe

[issue10107] Quitting IDLE on Mac doesn't save unsaved code

2010-10-14 Thread Bruce Sherwood
New submission from Bruce Sherwood : It has just been discovered that at least since Python 2.6 on the Mac, quitting IDLE does not prompt to save unsaved code, which is then lost. The recently submitted diff for bringing Guilherme Polo's Google Summer of Code improvements into IDLE on Python 3