Enlightenment CVS committal

Author  : kwo
Project : e16
Module  : e

Dir     : e16/e/src


Modified Files:
        groups.c 


Log Message:
Enable pager and iconbox grouping.
===================================================================
RCS file: /cvsroot/enlightenment/e16/e/src/groups.c,v
retrieving revision 1.51
retrieving revision 1.52
diff -u -3 -r1.51 -r1.52
--- groups.c    13 Feb 2004 18:36:51 -0000      1.51
+++ groups.c    14 Feb 2004 23:51:29 -0000      1.52
@@ -22,6 +22,8 @@
  */
 #include "E.h"
 
+#define DISABLE_PAGER_ICONBOX_GROUPING 0
+
 Group              *
 CreateGroup()
 {
@@ -109,16 +111,18 @@
 
    for (i = 0; i < num; i++)
      {
+#if DISABLE_PAGER_ICONBOX_GROUPING
        /* disable iconboxes and pagers to go into groups */
-       if (!((ewins[i]->ibox) || (ewins[i]->pager)))
-          AddEwinToGroup(ewins[i], g);
-       else
+       if ((ewins[i]->ibox) || (ewins[i]->pager))
          {
             DialogOK(_("Cannot comply"),
                      _("Iconboxes and Pagers are disallowed from being\n"
                        "members of a group. You cannot add these windows\n"
                        "to a group.\n"));
+            return;
          }
+#endif
+       AddEwinToGroup(ewins[i], g);
      }
 }
 
@@ -129,28 +133,28 @@
 
    if (ewin && g)
      {
+#if DISABLE_PAGER_ICONBOX_GROUPING
        /* disable iconboxes and pagers to go into groups */
-       if (!((ewin->ibox) || (ewin->pager)))
-         {
-            for (i = 0; i < ewin->num_groups; i++)
-               if (ewin->groups[i] == g)
-                  return;
-            ewin->num_groups++;
-            ewin->groups =
-               Erealloc(ewin->groups, sizeof(Group *) * ewin->num_groups);
-            ewin->groups[ewin->num_groups - 1] = g;
-            g->num_members++;
-            g->members = Erealloc(g->members, sizeof(EWin *) * g->num_members);
-            g->members[g->num_members - 1] = ewin;
-            RememberImportantInfoForEwin(ewin);
-         }
-       else
+       if ((ewin->ibox) || (ewin->pager))
          {
             DialogOK(_("Cannot comply"),
                      _("Iconboxes and Pagers are disallowed from being\n"
                        "members of a group. You cannot add these windows\n"
                        "to a group.\n"));
+            return;
          }
+#endif
+       for (i = 0; i < ewin->num_groups; i++)
+          if (ewin->groups[i] == g)
+             return;
+       ewin->num_groups++;
+       ewin->groups =
+          Erealloc(ewin->groups, sizeof(Group *) * ewin->num_groups);
+       ewin->groups[ewin->num_groups - 1] = g;
+       g->num_members++;
+       g->members = Erealloc(g->members, sizeof(EWin *) * g->num_members);
+       g->members[g->num_members - 1] = ewin;
+       RememberImportantInfoForEwin(ewin);
      }
 }
 




-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to