Rearange things so the main lua group is the, um, main one,

the edje group is swallowed in that, and the bubbles lua group
is swallowed into the edje group.

Demonstrates all ways of lua swallowing, except direct lua to lua.


SVN revision: 65140
This commit is contained in:
David Walter Seikel 2011-11-14 00:18:41 +00:00
parent f631c2ca09
commit b0716602f1
1 changed files with 48 additions and 48 deletions

View File

@ -12,10 +12,8 @@ images {
}
collections {
// The group name NEEDS a / in it,
// or the part below that tries to swallow it don't work.
// Leaving just the lua part visible.
group { name: "example/lua";
group {
name: "main";
lua_script_only: 1;
lua_script {
--// stick object private/local vars here
@ -88,6 +86,7 @@ collections {
D.tim = edje.timer(1.23, mycb);
D.tra = edje.transition(5.0, mycb3);
D.ani = edje.animator(mycb2);
edje_geom = edje.geom();
if (edje.spanky) then edje.spanky(); end
@ -116,6 +115,10 @@ collections {
edje.messagesend(7, "strfloat", "hello world", 7.654);
edje.messagesend(7, "strintset","hello world", {1, 2, 3});
D.edje = edje.edje();
D.edje:file("plain/edje/group");
D.edje:show();
D.rect = edje.rect();
D.rect:geom (5, 10, 50, 30);
D.rect:color (255, 128, 60, 255);
@ -237,11 +240,13 @@ collections {
function move (x, y)
print("lua::move x=" .. x .. " x=" .. y);
D.edje:move(0, 0);
end
function resize (w, h)
print("lua::resize w=" .. w .. " h=" .. h);
D.text:move((w - text_geom.w) / 2, (h - text_geom.h) / 8);
D.edje:resize(w, h);
end
function message (id, type, v1, v2)
@ -258,11 +263,13 @@ collections {
}
}
group
{ name: "bubbles/lua";
// The group name NEEDS a / in it,
// or the part below that tries to swallow it won't work.
// Leaving just the lua part visible.
group {
name: "bubbles/lua";
lua_script_only: 1;
lua_script
{
lua_script {
local bubbles = { };
local bubbleCols = 8;
local bubbleRows = 6;
@ -296,8 +303,7 @@ collections {
}
group {
name: "elm/bg/base/default";
name: "plain/edje/group";
parts {
part {
name: "background";
@ -309,6 +315,7 @@ collections {
}
}
// A lua group embedded in an edje group.
part {
name: "bubbles_lua";
type: GROUP;
@ -319,6 +326,7 @@ collections {
part {
name: "background_image";
type: IMAGE;
mouse_events: 0;
description {
state: "default" 0.0;
@ -342,14 +350,6 @@ collections {
}
}
part {
name: "example_lua";
type: GROUP;
source: "example/lua";
mouse_events: 0;
description { state: "default" 0.0; }
}
}
}