Enlightenment CVS committal
Author : raster
Project : e17
Module : libs/edje
Dir : e17/libs/edje/src/lib
Modified Files:
edje_calc.c edje_message_queue.c edje_text.c edje_util.c
Log Message:
aaaaaaaaaaaah message queue related fix.
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/edje/src/lib/edje_calc.c,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -3 -r1.36 -r1.37
--- edje_calc.c 14 Jul 2004 09:59:29 -0000 1.36
+++ edje_calc.c 12 Aug 2004 18:55:45 -0000 1.37
@@ -182,12 +182,15 @@
{
Evas_List *l;
+// printf("ed->freeze = %i\n", ed->freeze);
+// printf("ed->calc_only = %i\n", ed->calc_only);
if (!ed->dirty) return;
if (ed->freeze)
{
ed->recalc = 1;
if (!ed->calc_only) return;
}
+// printf("recalcies\n");
for (l = ed->parts; l; l = l->next)
{
Edje_Real_Part *ep;
@@ -504,12 +507,14 @@
char *font;
int size;
Evas_Coord tw, th;
+ char buf[4096];
text = chosen_desc->text.text;
font = chosen_desc->text.font;
size = chosen_desc->text.size;
- if ((chosen_desc->text.text_class) && (strlen(chosen_desc->text.text_class) >
0))
+ if ((chosen_desc->text.text_class) &&
+ (strlen(chosen_desc->text.text_class) > 0))
{
Edje_Text_Class *tc;
@@ -524,6 +529,15 @@
if (ep->text.text) text = ep->text.text;
if (ep->text.font) font = ep->text.font;
if (ep->text.size > 0) size = ep->text.size;
+
+ strcpy(buf, "fonts/");
+ strcat(buf, font);
+
+ evas_object_text_font_set(ep->object, buf, 10);
+
+ if (evas_object_text_ascent_get(ep->object) > 0) font = buf;
+// font = buf;
+
evas_object_text_font_set(ep->object, font, size);
if ((chosen_desc->text.min_x) || (chosen_desc->text.min_y))
{
@@ -698,6 +712,7 @@
Edje_Part_Description *chosen_desc;
double pos = 0.0;
+// printf("^^^^calc: %s\n", ep->part->name);
if (ep->calculated) return;
if (ep->calculating)
{
@@ -716,6 +731,8 @@
if (ep->param2.rel2_to_x) _edje_part_recalc(ed, ep->param2.rel2_to_x);
if (ep->param2.rel2_to_y) _edje_part_recalc(ed, ep->param2.rel2_to_y);
+// printf("CALC\n");
+
/* actually calculate now */
if (ep->description_pos == 0.0)
chosen_desc = ep->param1.description;
@@ -728,6 +745,7 @@
ep->calculated = 1;
return;
}
+// printf("CALC2\n");
ep->chosen_description = chosen_desc;
if (ep->param1.description)
@@ -852,6 +870,7 @@
}
if (!ed->calc_only)
{
+// printf("APPL\n");
if (ep->part->type == EDJE_PART_TYPE_RECTANGLE)
{
evas_object_move(ep->object, ed->x + p3.x, ed->y + p3.y);
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/edje/src/lib/edje_message_queue.c,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -3 -r1.6 -r1.7
--- edje_message_queue.c 6 Jul 2004 02:40:14 -0000 1.6
+++ edje_message_queue.c 12 Aug 2004 18:55:45 -0000 1.7
@@ -1,6 +1,9 @@
#include "Edje.h"
+#include <Ecore_Job.h>
#include "edje_private.h"
+Ecore_Job *job = NULL;
+
void
edje_object_message_send(Evas_Object *obj, Edje_Message_Type type, int id, void *msg)
{
@@ -23,7 +26,6 @@
static Evas_List *msgq = NULL;
static Evas_List *tmp_msgq = NULL;
-static Ecore_Idle_Enterer *idler = NULL;
static int
_edje_dummy_timer(void *data)
@@ -31,25 +33,27 @@
return 0;
}
-static int
-_edje_idler(void *data)
+static void
+_edje_job(void *data)
{
_edje_message_queue_process();
- return 1;
+ job = NULL;
}
void
_edje_message_init(void)
{
- idler = ecore_idle_enterer_add(_edje_idler, NULL);
}
void
_edje_message_shutdown(void)
{
_edje_message_queue_clear();
- ecore_idle_enterer_del(idler);
- idler = NULL;
+ if (job)
+ {
+ ecore_job_del(job);
+ job = NULL;
+ }
}
void
@@ -197,7 +201,8 @@
Edje_Message *em;
int i;
unsigned char *msg = NULL;
-
+
+ if (!job) job = ecore_job_add(_edje_job, NULL);
em = _edje_message_new(ed, queue, type, id);
if (!em) return;
switch (em->type)
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/edje/src/lib/edje_text.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -3 -r1.17 -r1.18
--- edje_text.c 24 May 2004 08:40:21 -0000 1.17
+++ edje_text.c 12 Aug 2004 18:55:45 -0000 1.18
@@ -292,6 +292,7 @@
Evas_Coord tw, th;
Evas_Coord ox, oy, sw, sh;
char *buf = NULL;
+ char buf2[4096];
text = chosen_desc->text.text;
font = chosen_desc->text.font;
@@ -312,6 +313,15 @@
if (ep->text.text) text = ep->text.text;
if (ep->text.font) font = ep->text.font;
if (ep->text.size > 0) size = ep->text.size;
+
+ strcpy(buf2, "fonts/");
+ strcat(buf2, font);
+
+ evas_object_text_font_set(ep->object, buf2, 10);
+
+ if (evas_object_text_ascent_get(ep->object) > 0) font = buf2;
+// font = buf2;
+
ox = _edje_text_styles[ep->part->effect].offset.x;
oy = _edje_text_styles[ep->part->effect].offset.y;
sw = params->w - (_edje_text_styles[ep->part->effect].pad.l +
_edje_text_styles[ep->part->effect].pad.r);
===================================================================
RCS file: /cvsroot/enlightenment/e17/libs/edje/src/lib/edje_util.c,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -3 -r1.40 -r1.41
--- edje_util.c 14 Jul 2004 09:59:29 -0000 1.40
+++ edje_util.c 12 Aug 2004 18:55:45 -0000 1.41
@@ -351,6 +351,7 @@
Evas_List *l;
Edje_Text_Class *tc;
+// printf("------------ edje_object_text_class_set\n");
ed = _edje_fetch(obj);
if ((!ed) || (!text_class)) return;
if (size < 0.0) size = 0.0;
@@ -1455,15 +1456,25 @@
_edje_freeze(Edje *ed)
{
ed->freeze++;
+// printf("FREEZE %i\n", ed->freeze);
return ed->freeze;
}
int
_edje_thaw(Edje *ed)
{
+// printf("THAW %i\n", ed->freeze);
ed->freeze--;
- if (ed->freeze < 0) ed->freeze = 0;
- if ((ed->freeze == 0) && (ed->recalc)) _edje_recalc(ed);
+ if (ed->freeze < 0)
+ {
+// printf("-------------########### OVER THAW\n");
+ ed->freeze = 0;
+ }
+ if ((ed->freeze == 0) && (ed->recalc))
+ {
+// printf("thaw recalc\n");
+ _edje_recalc(ed);
+ }
return ed->freeze;
}
-------------------------------------------------------
SF.Net email is sponsored by Shop4tech.com-Lowest price on Blank Media
100pk Sonic DVD-R 4x for only $29 -100pk Sonic DVD+R for only $33
Save 50% off Retail on Ink & Toner - Free Shipping and Free Gift.
http://www.shop4tech.com/z/Inkjet_Cartridges/9_108_r285
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs