Commit Graph

52 Commits

Author SHA1 Message Date
4e385b44a6 Remove LocaleGuards from LuaInstance state methods
There are no float <=> string conversions in these methods and g_base64_encode
etc functions are not affected by locale.
2017-06-22 10:48:38 +10:00
8bb26628e3 Skip script-setup if there are no parameters (and name is unique) 2017-04-26 19:45:22 +02:00
f5995661d0 Lua: Action Script Dialog & MessageBox 2017-04-25 14:01:22 +02:00
4bf8f9f1a8 Use XMLNode::set_property API in LuaInstance class
Didn't seem worth converting from XMLNode::property API to
XMLNode::get_property and there may be some ordering issues.
2017-04-19 09:36:56 +10:00
c3f2cff8bc optimize LuaInstance::get_action_state, LuaInstance::get_hook_state
Lua serialize() is called recursively and concatenates strings.
(in Lua that results in a new string on the stack, with 2 unused old
strings). Collecting garbage every time becomes expensive, so do it
only once at the end. GUI scripts are not memory limited anyway.
2017-03-27 04:59:20 +02:00
b83ea5bd49 Save Lua script file origin (for later updates) -- GUI+Session plugin 2017-02-24 16:10:14 +01:00
9e543beb56 Add some convenient public editor methods (for lua-bindings)
and s/get// in the old API for consistency.
2017-02-24 16:10:14 +01:00
3780a9526e re-order inheritance
LuaBridge only allows one parent class, others need explicit casts.
Allowing RoutUI to be passed as Selectable argument is handy.
2017-02-24 16:10:14 +01:00
1e4e97019d Lua bindings to access editor selection + region selection bindings 2017-02-23 22:32:32 +01:00
2157cd0e94 Lua binding for pango_cairo_layout_path (text outlines) 2017-02-20 03:56:32 +01:00
a732c7c9fa Allow to un/load Lua Session Scripts in the Script Manager 2017-02-19 01:29:08 +01:00
2d50871034 Remove LuaCairo.color_to_rgba (now Ardour.LuaAPI.color_to_rgba) 2017-02-18 16:13:49 +01:00
3bbb4b76f7 Add Lua API to convert Canvas::Color to Cairo RGBA 2017-02-17 23:28:03 +01:00
472f14c803 Allow Lua action scripts to provide a button icon 2017-02-17 18:58:11 +01:00
cded378e17 Mark session dirty when changing scripts 2017-02-17 11:17:54 +01:00
f84cdb3381 fix crash when closing session w/action hooks
drop_callback() deletes the Callback itself (lua state is invalid)
2017-02-02 21:42:57 +01:00
1d2a76f239 Free some one time alloc of the UI (cleaner valgrind output)
No incremental leaks here..
* downcase (const char*) uses strdup, caller needs to free
* free allocated cursors when the editor is destroyed
* drop static editor lua-instance & bindings
* delete allocated gtk image/icons
2017-01-20 13:53:37 +01:00
b233a56a80 fix interface - proessor_selection is not a Lua C-Function 2016-10-05 01:14:43 +02:00
ddc4e61b57 forward Lua print() to Ardour's Log. 2016-08-26 17:02:23 +02:00
7837122e45 add a static function to access processor selection from a Lua script
local ps = ArdourUI.processor_selection()
  for p in ps:iter() do print (p:name ()) end
2016-08-26 03:24:06 +02:00
822810b88f the endless quest to plug memory leaks -- episode 379 2016-07-25 17:38:59 +02:00
bcee4e1518 add a lua timer callback signal 2016-07-24 13:00:15 +02:00
a450024c56 add some strategic lua gc steps. 2016-07-18 23:52:40 +02:00
e9a2eea867 remove old a3_curl API and switch some curl calls
Keep freesound-moocher as is until freesound-apiv2 branch is merged
or rebased.
2016-07-18 16:46:59 +02:00
9c2682d6f1 quick hack to test SSL in bundles
this needs to be reverted, and we need a proper curl wrapper,
shared by video-timeline AND freesound moocher
2016-07-17 17:03:48 +02:00
cf52d6e4b4 enough with umpteen "i18n.h" files. Consolidate on pbd/i18n.h 2016-07-14 14:45:23 -04:00
97ef89357a remove useless binding (fixes broken windows build) 2016-07-05 02:38:02 +02:00
d6338e6dfe unbind pangomm 1.30 API for compat. 2016-07-04 10:36:11 +02:00
f49d0a1b1d add PangoCairo lua bindings 2016-07-04 00:20:11 +02:00
d027ce8006 add Lua bindings for reference counted Cairo::ImageSurface 2016-07-02 23:36:34 +02:00
6d343ba3c6 fix LocaleGuard contstructor (3dc77280) 2016-05-07 12:19:41 +02:00
3dc7728038 we always only use the "C" locale when saving. 2016-05-05 21:49:56 +02:00
d21f202905 add some more Editor Selection lua bindings 2016-04-11 14:06:26 +02:00
96d0e099bd add Lua bindings for Range Time Selection
```lua
print (Editor:get_selection ().time:start ())

for ar in Editor:get_selection ().time:iter () do
  print (ar.id, ar.start, ar._end)
end
```
2016-04-11 00:31:35 +02:00
2b943ea36c convenient API to access track and region selection 2016-04-10 20:56:53 +02:00
e25dce8849 and a few more Editor lua bindings 2016-04-09 15:45:30 +02:00
7026d88a46 re-add std::vector<std::string> just for cairo's set_dash()
This fixes crash with the window version.
2016-04-05 00:00:06 +02:00
8acf782bd2 reduce header dependencies (part 2/2) 2016-03-28 19:14:56 +02:00
7bb1933734 fix out-of-order d'tor which garbles the lua stack. 2016-03-24 22:54:20 +01:00
a8943538ea Hide lua script selector before showing lua parameter dialog. 2016-03-23 17:00:10 +01:00
627f2aae48 UI part of lua code/header consolidation. 2016-03-23 17:00:10 +01:00
d062e1a84e further lua binding refactoring, match C++ namespaces 2016-03-22 00:30:27 +01:00
7083d711ac return values of reference params as Lua table 2016-03-21 18:58:09 +01:00
7079865bfc add missing GUI lua binding classe 2016-03-21 04:06:32 +01:00
93449d3431 expose Lua OSC transmitter 2016-03-19 13:15:37 +01:00
ee2d88a5cc add basic set of Cairo Lua bindings 2016-03-17 15:54:54 +01:00
56c32a1e77 Expose PublicEditor Bindings to Lua 2016-02-29 12:01:37 +01:00
8032208656 resolve ambiguous ‘operator==’ (‘int’ vs ‘const luabridge::LuaRef’) 2016-02-27 13:48:01 +01:00
65bedf75f1 proper "false" check for MSVC compat
Lua "function call" returns false on error.
2016-02-27 13:14:00 +01:00
a4cde4230c C++98 compat 2016-02-23 19:24:27 +01:00