diff options
author | 2009-02-10 10:24:56 -0500 | |
---|---|---|
committer | 2009-02-10 10:24:56 -0500 | |
commit | ddcc45f0615ab6ba776635a15e2183f8d50401a7 (patch) | |
tree | 958e817be2c18db9005db29ddcbdeeb72350d77e /core/file_io.lua | |
parent | 59c9eb6528d1759bc2734150cb3d99ec2e3eab5b (diff) | |
download | textadept-ddcc45f0615ab6ba776635a15e2183f8d50401a7.tar.gz textadept-ddcc45f0615ab6ba776635a15e2183f8d50401a7.zip |
Moved the textadept.locale table into the globals table.
Diffstat (limited to 'core/file_io.lua')
-rw-r--r-- | core/file_io.lua | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/core/file_io.lua b/core/file_io.lua index 4dce2721..8e487930 100644 --- a/core/file_io.lua +++ b/core/file_io.lua @@ -1,6 +1,7 @@ -- Copyright 2007-2009 Mitchell mitchell<att>caladbolg.net. See LICENSE. local textadept = _G.textadept +local locale = _G.locale --- -- Provides file input/output routines for Textadept. @@ -48,7 +49,6 @@ end -- specified, the user is prompted to open files from a dialog. -- @usage textadept.io.open(filename) function open(filenames) - local locale = textadept.locale filenames = filenames or cocoa_dialog('fileselect', { title = locale.IO_OPEN_TITLE, @@ -113,7 +113,7 @@ function save_as(buffer, filename) if not filename then filename = cocoa_dialog('filesave', { - title = textadept.locale.IO_SAVE_TITLE, + title = locale.IO_SAVE_TITLE, ['with-directory'] = (buffer.filename or ''):match('.+[/\\]'), ['with-file'] = (buffer.filename or ''):match('[^/\\]+$'), ['no-newline'] = true @@ -148,7 +148,6 @@ end -- buffer. -- @usage buffer:close() function close(buffer) - local locale = textadept.locale textadept.check_focused_buffer(buffer) if buffer.dirty and cocoa_dialog('yesno-msgbox', { title = locale.IO_CLOSE_TITLE, |