forked from enlightenment/efl
Revert to revision 64488 in order to split the code into new feature and indentation
SVN revision: 64633
This commit is contained in:
parent
193052b816
commit
1d300f049b
|
@ -7121,7 +7121,7 @@ st_collections_group_programs_program_action(void)
|
||||||
@property
|
@property
|
||||||
transition
|
transition
|
||||||
@parameters
|
@parameters
|
||||||
[type] [length] [[interp val 1]] [[interp val 2]] [[option]]
|
[type] [length] [[interp val 1]] [[interp val 2]]
|
||||||
@effect
|
@effect
|
||||||
Defines how transitions occur using STATE_SET action.\n
|
Defines how transitions occur using STATE_SET action.\n
|
||||||
Where 'type' is the style of the transition and 'length' is a double
|
Where 'type' is the style of the transition and 'length' is a double
|
||||||
|
@ -7157,11 +7157,6 @@ st_collections_group_programs_program_action(void)
|
||||||
spring "swings" and val 1 specifies the decay, but it can exceed 1.0
|
spring "swings" and val 1 specifies the decay, but it can exceed 1.0
|
||||||
on the outer swings.
|
on the outer swings.
|
||||||
|
|
||||||
Valid option is CURRENT.
|
|
||||||
|
|
||||||
CURRENT is the option which the edje object moves from current position.
|
|
||||||
It can be used as the last parameter of the every type.
|
|
||||||
|
|
||||||
@endproperty
|
@endproperty
|
||||||
*/
|
*/
|
||||||
static void
|
static void
|
||||||
|
@ -7195,30 +7190,15 @@ st_collections_group_programs_program_transition(void)
|
||||||
"SPRING", EDJE_TWEEN_MODE_SPRING,
|
"SPRING", EDJE_TWEEN_MODE_SPRING,
|
||||||
NULL);
|
NULL);
|
||||||
current_program->tween.time = FROM_DOUBLE(parse_float_range(1, 0.0, 999999999.0));
|
current_program->tween.time = FROM_DOUBLE(parse_float_range(1, 0.0, 999999999.0));
|
||||||
if ((current_program->tween.mode >= EDJE_TWEEN_MODE_LINEAR) &&
|
|
||||||
(current_program->tween.mode <= EDJE_TWEEN_MODE_DECELERATE))
|
|
||||||
{
|
|
||||||
if ((get_arg_count() == 3) && (!strcmp(parse_str(2), "CURRENT")))
|
|
||||||
current_program->tween.mode |= EDJE_TWEEN_MODE_OPT_FROM_CURRENT;
|
|
||||||
else if (get_arg_count() != 2)
|
|
||||||
{
|
|
||||||
ERR("%s: Error. parse error %s:%i. "
|
|
||||||
"Need 2rd parameter to set time",
|
|
||||||
progname, file_in, line - 1);
|
|
||||||
exit(-1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// the following need v1
|
// the following need v1
|
||||||
// EDJE_TWEEN_MODE_ACCELERATE_FACTOR
|
// EDJE_TWEEN_MODE_ACCELERATE_FACTOR
|
||||||
// EDJE_TWEEN_MODE_DECELERATE_FACTOR
|
// EDJE_TWEEN_MODE_DECELERATE_FACTOR
|
||||||
// EDJE_TWEEN_MODE_SINUSOIDAL_FACTOR
|
// EDJE_TWEEN_MODE_SINUSOIDAL_FACTOR
|
||||||
// current_program->tween.v1
|
// current_program->tween.v1
|
||||||
else if ((current_program->tween.mode >= EDJE_TWEEN_MODE_ACCELERATE_FACTOR) &&
|
if ((current_program->tween.mode >= EDJE_TWEEN_MODE_ACCELERATE_FACTOR) &&
|
||||||
(current_program->tween.mode <= EDJE_TWEEN_MODE_SINUSOIDAL_FACTOR))
|
(current_program->tween.mode <= EDJE_TWEEN_MODE_SINUSOIDAL_FACTOR))
|
||||||
{
|
{
|
||||||
if ((get_arg_count() == 4) && (!strcmp(parse_str(3), "CURRENT")))
|
if (get_arg_count() != 3)
|
||||||
current_program->tween.mode |= EDJE_TWEEN_MODE_OPT_FROM_CURRENT;
|
|
||||||
else if (get_arg_count() != 3)
|
|
||||||
{
|
{
|
||||||
ERR("%s: Error. parse error %s:%i. "
|
ERR("%s: Error. parse error %s:%i. "
|
||||||
"Need 3rd parameter to set factor",
|
"Need 3rd parameter to set factor",
|
||||||
|
@ -7235,9 +7215,7 @@ st_collections_group_programs_program_transition(void)
|
||||||
else if ((current_program->tween.mode >= EDJE_TWEEN_MODE_DIVISOR_INTERP) &&
|
else if ((current_program->tween.mode >= EDJE_TWEEN_MODE_DIVISOR_INTERP) &&
|
||||||
(current_program->tween.mode <= EDJE_TWEEN_MODE_SPRING))
|
(current_program->tween.mode <= EDJE_TWEEN_MODE_SPRING))
|
||||||
{
|
{
|
||||||
if ((get_arg_count() == 5) && (!strcmp(parse_str(4), "CURRENT")))
|
if (get_arg_count() != 4)
|
||||||
current_program->tween.mode |= EDJE_TWEEN_MODE_OPT_FROM_CURRENT;
|
|
||||||
else if (get_arg_count() != 4)
|
|
||||||
{
|
{
|
||||||
ERR("%s: Error. parse error %s:%i. "
|
ERR("%s: Error. parse error %s:%i. "
|
||||||
"Need 3rd and 4th parameters to set factor and counts",
|
"Need 3rd and 4th parameters to set factor and counts",
|
||||||
|
|
|
@ -631,9 +631,7 @@ typedef enum _Edje_Tween_Mode
|
||||||
EDJE_TWEEN_MODE_DIVISOR_INTERP = 8,
|
EDJE_TWEEN_MODE_DIVISOR_INTERP = 8,
|
||||||
EDJE_TWEEN_MODE_BOUNCE = 9,
|
EDJE_TWEEN_MODE_BOUNCE = 9,
|
||||||
EDJE_TWEEN_MODE_SPRING = 10,
|
EDJE_TWEEN_MODE_SPRING = 10,
|
||||||
EDJE_TWEEN_MODE_LAST = 11,
|
EDJE_TWEEN_MODE_LAST = 11
|
||||||
EDJE_TWEEN_MODE_MASK = 0xff,
|
|
||||||
EDJE_TWEEN_MODE_OPT_FROM_CURRENT = (1 << 31)
|
|
||||||
} Edje_Tween_Mode;
|
} Edje_Tween_Mode;
|
||||||
|
|
||||||
typedef enum _Edje_Cursor
|
typedef enum _Edje_Cursor
|
||||||
|
|
|
@ -56,7 +56,7 @@ _edje_part_pos_set(Edje *ed, Edje_Real_Part *ep, int mode, FLOAT_T pos, FLOAT_T
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
switch (mode & EDJE_TWEEN_MODE_MASK)
|
switch (mode)
|
||||||
{
|
{
|
||||||
case EDJE_TWEEN_MODE_SINUSOIDAL:
|
case EDJE_TWEEN_MODE_SINUSOIDAL:
|
||||||
npos = FROM_DOUBLE(ecore_animator_pos_map(TO_DOUBLE(pos),
|
npos = FROM_DOUBLE(ecore_animator_pos_map(TO_DOUBLE(pos),
|
||||||
|
@ -2152,8 +2152,8 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int flags)
|
||||||
statec = confine_to->state;
|
statec = confine_to->state;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
// if (ep->text.source) _edje_part_recalc(ed, ep->text.source, flags);
|
// if (ep->text.source) _edje_part_recalc(ed, ep->text.source, flags);
|
||||||
// if (ep->text.text_source) _edje_part_recalc(ed, ep->text.text_source, flags);
|
// if (ep->text.text_source) _edje_part_recalc(ed, ep->text.text_source, flags);
|
||||||
|
|
||||||
/* actually calculate now */
|
/* actually calculate now */
|
||||||
chosen_desc = ep->chosen_description;
|
chosen_desc = ep->chosen_description;
|
||||||
|
@ -2212,23 +2212,11 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int flags)
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (ep->param2)
|
if (ep->param2 && ep->description_pos != ZERO)
|
||||||
{
|
{
|
||||||
int beginning_pos, part_type;
|
int beginning_pos, part_type;
|
||||||
Edje_Calc_Params *p2, *p3;
|
Edje_Calc_Params *p2, *p3;
|
||||||
|
|
||||||
if (ep->current)
|
|
||||||
{
|
|
||||||
p1->x = ep->current->x - ed->x;
|
|
||||||
p1->y = ep->current->y - ed->y;
|
|
||||||
p1->w = ep->current->w;
|
|
||||||
p1->h = ep->current->h;
|
|
||||||
p1->color.r = ep->current->color.r;
|
|
||||||
p1->color.g = ep->current->color.g;
|
|
||||||
p1->color.b = ep->current->color.b;
|
|
||||||
p1->color.a = ep->current->color.a;
|
|
||||||
}
|
|
||||||
|
|
||||||
p3 = &lp3;
|
p3 = &lp3;
|
||||||
|
|
||||||
#ifndef EDJE_CALC_CACHE
|
#ifndef EDJE_CALC_CACHE
|
||||||
|
@ -2446,15 +2434,15 @@ _edje_part_recalc(Edje *ed, Edje_Real_Part *ep, int flags)
|
||||||
|
|
||||||
if (ep->swallowed_object)
|
if (ep->swallowed_object)
|
||||||
{
|
{
|
||||||
//// the below really is wrong - swallow color shouldn't affect swallowed object
|
//// the below really is wrong - swallow color shouldn't affect swallowed object
|
||||||
//// color - the edje color as a WHOLE should though - and that should be
|
//// color - the edje color as a WHOLE should though - and that should be
|
||||||
//// done via the clipper anyway. this created bugs when objects had their
|
//// done via the clipper anyway. this created bugs when objects had their
|
||||||
//// colro set and were swallowed - then had their color changed.
|
//// colro set and were swallowed - then had their color changed.
|
||||||
// evas_object_color_set(ep->swallowed_object,
|
// evas_object_color_set(ep->swallowed_object,
|
||||||
// (pf->color.r * pf->color.a) / 255,
|
// (pf->color.r * pf->color.a) / 255,
|
||||||
// (pf->color.g * pf->color.a) / 255,
|
// (pf->color.g * pf->color.a) / 255,
|
||||||
// (pf->color.b * pf->color.a) / 255,
|
// (pf->color.b * pf->color.a) / 255,
|
||||||
// pf->color.a);
|
// pf->color.a);
|
||||||
if (pf->visible)
|
if (pf->visible)
|
||||||
{
|
{
|
||||||
evas_object_move(ep->swallowed_object, ed->x + pf->x, ed->y + pf->y);
|
evas_object_move(ep->swallowed_object, ed->x + pf->x, ed->y + pf->y);
|
||||||
|
|
|
@ -1212,7 +1212,6 @@ struct _Edje_Real_Part
|
||||||
Edje_Real_Part_State param1; // 20
|
Edje_Real_Part_State param1; // 20
|
||||||
// WITH EDJE_CALC_CACHE: 140
|
// WITH EDJE_CALC_CACHE: 140
|
||||||
Edje_Real_Part_State *param2, *custom; // 8
|
Edje_Real_Part_State *param2, *custom; // 8
|
||||||
Edje_Calc_Params *current; // 4
|
|
||||||
|
|
||||||
#ifdef EDJE_CALC_CACHE
|
#ifdef EDJE_CALC_CACHE
|
||||||
int state; // 4
|
int state; // 4
|
||||||
|
@ -1231,8 +1230,8 @@ struct _Edje_Real_Part
|
||||||
#ifdef EDJE_CALC_CACHE
|
#ifdef EDJE_CALC_CACHE
|
||||||
unsigned char invalidate : 1; // 0
|
unsigned char invalidate : 1; // 0
|
||||||
#endif
|
#endif
|
||||||
}; // 264
|
}; // 260
|
||||||
// WITH EDJE_CALC_CACHE: 404
|
// WITH EDJE_CALC_CACHE: 400
|
||||||
|
|
||||||
struct _Edje_Running_Program
|
struct _Edje_Running_Program
|
||||||
{
|
{
|
||||||
|
|
|
@ -478,24 +478,6 @@ _edje_program_run(Edje *ed, Edje_Program *pr, Eina_Bool force, const char *ssig,
|
||||||
rp = ed->table_parts[pt->id % ed->table_parts_size];
|
rp = ed->table_parts[pt->id % ed->table_parts_size];
|
||||||
if (rp)
|
if (rp)
|
||||||
{
|
{
|
||||||
if ((rp->object) && (pr->tween.mode & EDJE_TWEEN_MODE_OPT_FROM_CURRENT))
|
|
||||||
{
|
|
||||||
rp->current = calloc(1, sizeof(Edje_Calc_Params));
|
|
||||||
evas_object_geometry_get(rp->object, &(rp->current->x),
|
|
||||||
&(rp->current->y),
|
|
||||||
&(rp->current->w),
|
|
||||||
&(rp->current->h));
|
|
||||||
evas_object_color_get(rp->object, &(rp->current->color.r),
|
|
||||||
&(rp->current->color.g),
|
|
||||||
&(rp->current->color.b),
|
|
||||||
&(rp->current->color.a));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if (rp->current) free(rp->current);
|
|
||||||
rp->current = NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (rp->program)
|
if (rp->program)
|
||||||
_edje_program_end(ed, rp->program);
|
_edje_program_end(ed, rp->program);
|
||||||
_edje_part_description_apply(ed, rp,
|
_edje_part_description_apply(ed, rp,
|
||||||
|
@ -580,7 +562,7 @@ _edje_program_run(Edje *ed, Edje_Program *pr, Eina_Bool force, const char *ssig,
|
||||||
if (pt->id == runp->program->id)
|
if (pt->id == runp->program->id)
|
||||||
{
|
{
|
||||||
_edje_program_end(ed, runp);
|
_edje_program_end(ed, runp);
|
||||||
// goto done;
|
// goto done;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
for (ll = ed->pending_actions; ll; )
|
for (ll = ed->pending_actions; ll; )
|
||||||
|
@ -592,11 +574,11 @@ _edje_program_run(Edje *ed, Edje_Program *pr, Eina_Bool force, const char *ssig,
|
||||||
ed->pending_actions = eina_list_remove(ed->pending_actions, pp);
|
ed->pending_actions = eina_list_remove(ed->pending_actions, pp);
|
||||||
ecore_timer_del(pp->timer);
|
ecore_timer_del(pp->timer);
|
||||||
free(pp);
|
free(pp);
|
||||||
// goto done;
|
// goto done;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// done:
|
// done:
|
||||||
// continue;
|
// continue;
|
||||||
}
|
}
|
||||||
// _edje_emit(ed, "program,stop", pr->name);
|
// _edje_emit(ed, "program,stop", pr->name);
|
||||||
if (_edje_block_break(ed)) goto break_prog;
|
if (_edje_block_break(ed)) goto break_prog;
|
||||||
|
|
Loading…
Reference in New Issue