Enlightenment CVS committal
Author : kwo
Project : e16
Module : e
Dir : e16/e/src
Modified Files:
E.h arrange.c dialog.c ewins.h focus.c session.c
Log Message:
Focus own dialogs when mapped.
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/E.h,v
retrieving revision 1.512
retrieving revision 1.513
diff -u -3 -r1.512 -r1.513
--- E.h 10 Nov 2005 21:39:29 -0000 1.512
+++ E.h 13 Nov 2005 12:40:10 -0000 1.513
@@ -778,7 +778,7 @@
void SnapEwin(EWin * ewin, int dx, int dy, int *new_dx,
int *new_dy);
void ArrangeEwin(EWin * ewin);
-void ArrangeEwinCentered(EWin * ewin, int focus);
+void ArrangeEwinCentered(EWin * ewin);
void ArrangeEwinXY(EWin * ewin, int *px, int *py);
void ArrangeEwinCenteredXY(EWin * ewin, int *px, int *py);
void ArrangeEwins(const char *params);
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/arrange.c,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -3 -r1.83 -r1.84
--- arrange.c 30 Oct 2005 19:40:49 -0000 1.83
+++ arrange.c 13 Nov 2005 12:40:13 -0000 1.84
@@ -810,14 +810,12 @@
}
void
-ArrangeEwinCentered(EWin * ewin, int focus)
+ArrangeEwinCentered(EWin * ewin)
{
int x, y;
ArrangeEwinCenteredXY(ewin, &x, &y);
EwinMove(ewin, x, y);
- if (focus)
- FocusToEWin(ewin, FOCUS_SET);
}
static int
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/dialog.c,v
retrieving revision 1.137
retrieving revision 1.138
diff -u -3 -r1.137 -r1.138
--- dialog.c 5 Nov 2005 17:12:53 -0000 1.137
+++ dialog.c 13 Nov 2005 12:40:13 -0000 1.138
@@ -538,6 +538,8 @@
ewin->data = ptr;
d->ewin = ewin;
+ ewin->props.focus_when_mapped = 1;
+
ewin->MoveResize = DialogEwinMoveResize;
ewin->Close = DialogEwinClose;
@@ -632,7 +634,7 @@
if (FindADialog() > 1)
ArrangeEwin(ewin);
else
- ArrangeEwinCentered(ewin, 0);
+ ArrangeEwinCentered(ewin);
}
if (!FindDialog(d->win))
AddItem(d, d->name, d->win, LIST_TYPE_DIALOG);
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/ewins.h,v
retrieving revision 1.30
retrieving revision 1.31
diff -u -3 -r1.30 -r1.31
--- ewins.h 13 Nov 2005 01:22:28 -0000 1.30
+++ ewins.h 13 Nov 2005 12:40:13 -0000 1.31
@@ -141,6 +141,7 @@
unsigned vroot:1; /* Virtual root window */
unsigned autosave:1;
unsigned no_border:1; /* Never apply border */
+ unsigned focus_when_mapped:1;
} props;
EwinInhibit inh_app;
EwinInhibit inh_user;
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/focus.c,v
retrieving revision 1.132
retrieving revision 1.133
diff -u -3 -r1.132 -r1.133
--- focus.c 13 Nov 2005 11:32:47 -0000 1.132
+++ focus.c 13 Nov 2005 12:40:13 -0000 1.133
@@ -331,13 +331,12 @@
case FOCUS_EWIN_NEW:
if (Conf.focus.all_new_windows_get_focus)
- {
- do_focus = 1;
- }
+ do_focus = 1;
else if (Mode.place.doing_manual)
- {
- do_focus = 1;
- }
+ do_focus = 1;
+
+ if (ewin->props.focus_when_mapped)
+ do_focus = 2;
if (EwinIsTransient(ewin))
{
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/session.c,v
retrieving revision 1.112
retrieving revision 1.113
diff -u -3 -r1.112 -r1.113
--- session.c 10 Nov 2005 21:39:29 -0000 1.112
+++ session.c 13 Nov 2005 12:40:13 -0000 1.113
@@ -986,7 +986,7 @@
ewin = FindEwinByDialog(d);
if (ewin)
- ArrangeEwinCentered(ewin, 1);
+ ArrangeEwinCentered(ewin);
return;
}
-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
enlightenment-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs