mirror of
https://github.com/aseprite/aseprite.git
synced 2025-01-08 12:40:50 +00:00
lua: Add support to use app.activeFrame with a Frame object
This commit is contained in:
parent
e516d26fa8
commit
ca6d038af3
@ -367,7 +367,7 @@ int App_set_activeLayer(lua_State* L)
|
|||||||
|
|
||||||
int App_set_activeFrame(lua_State* L)
|
int App_set_activeFrame(lua_State* L)
|
||||||
{
|
{
|
||||||
const doc::frame_t frame = lua_tointeger(L, 2)-1;
|
const doc::frame_t frame = get_frame_number_from_arg(L, 2);
|
||||||
#ifdef ENABLE_UI
|
#ifdef ENABLE_UI
|
||||||
app::Context* ctx = App::instance()->context();
|
app::Context* ctx = App::instance()->context();
|
||||||
if (auto uiCtx = dynamic_cast<UIContext*>(ctx)) {
|
if (auto uiCtx = dynamic_cast<UIContext*>(ctx)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user