aboutsummaryrefslogtreecommitdiff
path: root/core/events.lua
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2008-02-23 18:13:24 -0500
committermitchell <70453897+667e-11@users.noreply.github.com>2008-02-23 18:13:24 -0500
commit47b8c0db856c48abbcbcb5635deaa5c2cc41427e (patch)
tree2d94eab5c87463131001fc815e60acf0cc9c6f41 /core/events.lua
parent04a91f8ab1db479b48f26f3f808b74ba8a617e9b (diff)
downloadtextadept-47b8c0db856c48abbcbcb5635deaa5c2cc41427e.tar.gz
textadept-47b8c0db856c48abbcbcb5635deaa5c2cc41427e.zip
Eliminated Zenity dependency; replaced with my CocoaDialog clone (lua_dialog).
Diffstat (limited to 'core/events.lua')
-rw-r--r--core/events.lua10
1 files changed, 5 insertions, 5 deletions
diff --git a/core/events.lua b/core/events.lua
index f9f6d484..1fb1ab42 100644
--- a/core/events.lua
+++ b/core/events.lua
@@ -372,11 +372,11 @@ add_handler('quit',
end
end
if any then
- list = list..'\nQuit without saving?'
- if os.execute('zenity --question --title Alert '..
- '--text "'..list..'"') ~= 0 then
- return false
- end
+ if tonumber( cocoa_dialog( 'yesno-msgbox', {
+ title = 'Save?',
+ text = 'Save changes before quitting?',
+ ['informative-text'] = list..'\nYou will have to save changes manually.'
+ } ) ) ~= 2 then return false end
end
textadept.io.save_session()
return true