aboutsummaryrefslogtreecommitdiff
path: root/src/lua_interface.c
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2008-11-01 17:44:57 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2008-11-01 17:44:57 -0400
commitfcf078c25d81ca2a9b75f6baec18ce7eb477a8f3 (patch)
treeaff95f8a75924cb6433d60aec4c93c6536e82421 /src/lua_interface.c
parentb7b4c83d44aa6e5af69ca0a33be71ac07dfa8966 (diff)
downloadtextadept-fcf078c25d81ca2a9b75f6baec18ce7eb477a8f3.tar.gz
textadept-fcf078c25d81ca2a9b75f6baec18ce7eb477a8f3.zip
Added support for some AppleEvents, use Scintilla namespace on OSX.
Diffstat (limited to 'src/lua_interface.c')
-rw-r--r--src/lua_interface.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/lua_interface.c b/src/lua_interface.c
index 4ae435f0..beac8b40 100644
--- a/src/lua_interface.c
+++ b/src/lua_interface.c
@@ -16,6 +16,10 @@
l_cfunc(l, ni, "__newindex"); \
} lua_setmetatable(l, -2); }
+#ifdef MAC
+using namespace Scintilla;
+#endif
+
LS *lua;
bool closing = false;
@@ -523,7 +527,7 @@ bool l_is_ta_table_function(const char *table, const char *function) {
* argument.
* @param nargs The number of arguments to pass to the Lua function to call.
* @param retn Optional number of expected return values. Defaults to 0.
- * @param keep_return Optoinal flag indicating whether or not to keep the return
+ * @param keep_return Optional flag indicating whether or not to keep the return
* values at the top of the stack. If false, discards the return values.
* Defaults to false.
*/
@@ -1247,7 +1251,11 @@ LF l_cf_buffer_find(LS *lua) {
LF l_cf_buffer_text_range(LS *lua) {
l_check_focused_buffer(lua, 1);
+#ifndef MAC
TextRange tr;
+#else
+ Scintilla::Textrange tr;
+#endif
tr.chrg.cpMin = luaL_checkinteger(lua, 2);
tr.chrg.cpMax = luaL_checkinteger(lua, 3);
char *text = new char[tr.chrg.cpMax - tr.chrg.cpMin + 1];