Ok, one last small fix.
Am Sun, 8 Apr 2007 21:58:41 +0200
schrieb Hannes Janetzek <[EMAIL PROTECTED]>:
> This patch is better. Perhaps the names es->hidden and e_shelf->hiding
> are a bit misleading since hidden includes the state while the shelf
> is hiding, and es->hiding means if the shelf should still hide when
> the hide_timer callback fires. Sorry, I think the patch is easier to
> understand :)
>
>
> Am Sun, 8 Apr 2007 21:25:30 +0200
> schrieb Hannes Janetzek <[EMAIL PROTECTED]>:
>
> > Am Fri, 06 Apr 2007 13:22:21 +0300
> > schrieb Виктор Кожухаров <[EMAIL PROTECTED]>:
> >
> > > В чт, 2007-04-05 в 21:09 +0200, Hannes Janetzek написа:
> > > > Hi,
> > > > I made a patch so that hiding of the shelf is done by the shelf
> > > > and not by the theme. I think this will make it easier to have a
> > > > consistent and configurable shelf-hiding behaviour.
> > > > I added one theme-data item to the shelf group:
> > > > "hidden_state_size" which sets the height or width for the shelf
> > > > when it is in hidden state.
> > > >
> > > The only problem with this patch that i can see is, that it should
> > > work regardless of whether the theme has a "hidden_state_size"
> > > set. Currently, if a theme does not have that, things will mess
> > > up, bad. And it might be useful to increase the default
> > > hidden_state_size from 2 to 6, so as to minimize the chance of
> > > rolling over to another virtual desktop.
> > >
> > > Other than that, the patch is dandy, and if no one objects, I'll
> > > commit it.
> > Thanks.
> >
> > I think the changes you have made are reasonable but one thing. The
> > shelf also disappears if i move the mouse out (the hide_timer
> > starts) and then move the mouse back in(while it is hiding or the
> > hide_timer is on). The attached patch should fix this.
> >
> > > >
> > > > Regards,
> > > > Hannes
> > > >
> > > >
> > > >
> > > > -------------------------------------------------------------------------
> > > > Take Surveys. Earn Cash. Influence the Future of IT
> > > > Join SourceForge.net's Techsay panel and you'll get the chance
> > > > to share your opinions on IT & business topics through brief
> > > > surveys-and earn cash
> > > > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> > > > _______________________________________________
> > > > enlightenment-devel mailing list
> > > > enlightenment-devel@lists.sourceforge.net
> > > > https://lists.sourceforge.net/lists/listinfo/enlightenment-devel
Index: e_shelf.c
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_shelf.c,v
retrieving revision 1.54
diff -u -r1.54 e_shelf.c
--- e_shelf.c 8 Apr 2007 09:32:48 -0000 1.54
+++ e_shelf.c 8 Apr 2007 20:05:32 -0000
@@ -271,7 +271,7 @@
E_OBJECT_TYPE_CHECK(es, E_SHELF_TYPE);
if (show && es->hidden && !es->instant_timer)
{
- es->hidden = 0;
+ es->hidden = 0;
edje_object_signal_emit(es->o_base, "e,state,visible", "e");
if (es->instant_delay >= 0.0)
{
@@ -291,7 +291,7 @@
}
else if (!show && es->cfg->autohide && !es->hidden)
{
- if(!es->hide_timer)
+ if(!es->hide_timer)
es->hide_timer = ecore_timer_add(1.0, _e_shelf_cb_hide_timer, es);
}
}
@@ -1059,6 +1059,7 @@
es = data;
ev = event_info;
edje_object_signal_emit(es->o_base, "e,state,focused", "e");
+ es->hiding = 0;
e_shelf_toggle(es, 1);
}
@@ -1076,7 +1077,10 @@
evas_object_geometry_get(es->o_base, &x, &y, &w, &h);
if (!E_INSIDE(ev->canvas.x, ev->canvas.y, x, y, w, h))
- e_shelf_toggle(es, 0);
+ {
+ es->hiding = 1;
+ e_shelf_toggle(es, 0);
+ }
}
edje_object_signal_emit(es->o_base, "e,state,unfocused", "e");
}
@@ -1098,24 +1102,26 @@
es = data;
- es->hidden = 1;
- edje_object_signal_emit(es->o_base, "e,state,hidden", "e");
- if (es->instant_delay >= 0.0)
+ if(es->hiding)
{
- if (!es->instant_timer)
- es->instant_timer = ecore_timer_add(es->instant_delay, _e_shelf_cb_instant_hide_timer, es);
+ es->hidden = 1;
+ edje_object_signal_emit(es->o_base, "e,state,hidden", "e");
+ if (es->instant_delay >= 0.0)
+ {
+ if (!es->instant_timer)
+ es->instant_timer = ecore_timer_add(es->instant_delay, _e_shelf_cb_instant_hide_timer, es);
+ }
+ else
+ {
+ if(!es->hide_animator)
+ es->hide_animator = ecore_animator_add(_e_shelf_cb_hide_animator, es);
+ }
+ if (es->hide_timer)
+ {
+ ecore_timer_del(es->hide_timer);
+ es->hide_timer = NULL;
+ }
}
- else
- {
- if(!es->hide_animator)
- es->hide_animator = ecore_animator_add(_e_shelf_cb_hide_animator, es);
- }
- if (es->hide_timer)
- {
- ecore_timer_del(es->hide_timer);
- es->hide_timer = NULL;
- }
-
return 1;
}
Index: e_shelf.h
===================================================================
RCS file: /var/cvs/e/e17/apps/e/src/bin/e_shelf.h,v
retrieving revision 1.20
diff -u -r1.20 e_shelf.h
--- e_shelf.h 8 Apr 2007 09:32:48 -0000 1.20
+++ e_shelf.h 8 Apr 2007 20:05:32 -0000
@@ -30,6 +30,7 @@
unsigned char fit_along : 1;
unsigned char fit_size : 1;
unsigned char hidden : 1;
+ unsigned char hiding : 1;
int size;
E_Config_Dialog *config_dialog;
E_Menu *menu;
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
enlightenment-devel mailing list
enlightenment-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-devel