Enlightenment CVS committal

Author  : sebastid
Project : e17
Module  : libs/ecore

Dir     : e17/libs/ecore/src/lib/ecore_x


Modified Files:
        ecore_x_netwm.c 


Log Message:
Formatting.

===================================================================
RCS file: 
/cvsroot/enlightenment/e17/libs/ecore/src/lib/ecore_x/ecore_x_netwm.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -3 -r1.11 -r1.12
--- ecore_x_netwm.c     2 Mar 2005 07:06:44 -0000       1.11
+++ ecore_x_netwm.c     22 Mar 2005 19:34:10 -0000      1.12
@@ -763,35 +763,34 @@
 _ecore_x_netwm_state_atom_get(Ecore_X_Window_State s)
 {
    switch(s)
-   {
+     {
       case ECORE_X_WINDOW_STATE_MODAL:
-         return ECORE_X_ATOM_NET_WM_STATE_MODAL;
+        return ECORE_X_ATOM_NET_WM_STATE_MODAL;
       case ECORE_X_WINDOW_STATE_STICKY:
-         return ECORE_X_ATOM_NET_WM_STATE_STICKY;
+        return ECORE_X_ATOM_NET_WM_STATE_STICKY;
       case ECORE_X_WINDOW_STATE_MAXIMIZED_VERT:
-         return ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_VERT;
+        return ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_VERT;
       case ECORE_X_WINDOW_STATE_MAXIMIZED_HORZ:
-         return ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_HORZ;
+        return ECORE_X_ATOM_NET_WM_STATE_MAXIMIZED_HORZ;
       case ECORE_X_WINDOW_STATE_SHADED:
-         return ECORE_X_ATOM_NET_WM_STATE_SHADED;
+        return ECORE_X_ATOM_NET_WM_STATE_SHADED;
       case ECORE_X_WINDOW_STATE_SKIP_TASKBAR:
-         return ECORE_X_ATOM_NET_WM_STATE_SKIP_TASKBAR;
+        return ECORE_X_ATOM_NET_WM_STATE_SKIP_TASKBAR;
       case ECORE_X_WINDOW_STATE_SKIP_PAGER:
-         return ECORE_X_ATOM_NET_WM_STATE_SKIP_PAGER;
+        return ECORE_X_ATOM_NET_WM_STATE_SKIP_PAGER;
       case ECORE_X_WINDOW_STATE_HIDDEN:
-         return ECORE_X_ATOM_NET_WM_STATE_HIDDEN;
+        return ECORE_X_ATOM_NET_WM_STATE_HIDDEN;
       case ECORE_X_WINDOW_STATE_FULLSCREEN:
-         return ECORE_X_ATOM_NET_WM_STATE_FULLSCREEN;
+        return ECORE_X_ATOM_NET_WM_STATE_FULLSCREEN;
       case ECORE_X_WINDOW_STATE_ABOVE:
-         return ECORE_X_ATOM_NET_WM_STATE_ABOVE;
+        return ECORE_X_ATOM_NET_WM_STATE_ABOVE;
       case ECORE_X_WINDOW_STATE_BELOW:
-         return ECORE_X_ATOM_NET_WM_STATE_BELOW;
+        return ECORE_X_ATOM_NET_WM_STATE_BELOW;
       case ECORE_X_WINDOW_STATE_DEMANDS_ATTENTION:
-         return ECORE_X_ATOM_NET_WM_STATE_DEMANDS_ATTENTION;
+        return ECORE_X_ATOM_NET_WM_STATE_DEMANDS_ATTENTION;
       default:
-         return 0;
-   }
-
+        return 0;
+     }
 }
 
 int
@@ -809,13 +808,13 @@
    atoms = (Ecore_X_Atom *) data;
 
    for (i = 0; i < num; ++i)
-   {
-      if (atoms[i] == atom)
-      {
-         ret = 1;
-         break;
-      }
-   }
+     {
+       if (atoms[i] == atom)
+         {
+            ret = 1;
+            break;
+         }
+     }
 
    XFree(data);
    return ret;
@@ -837,44 +836,44 @@
    oldset = (Ecore_X_Atom *) old_data;
 
    if (on)
-   {
-      if (ecore_x_netwm_window_state_isset(win, state))
-      {
-         XFree(old_data);
-         return;
-      }
-      newset = calloc(num + 1, sizeof(Ecore_X_Atom));
-      if (!newset) return;
-      data = (unsigned char *) newset;
-
-      for (i = 0; i < num; i++)
-         newset[i] = oldset[i];
-      newset[num] = atom;
-
-      ecore_x_window_prop_property_set(win, ECORE_X_ATOM_NET_WM_STATE,
-                                      XA_ATOM, 32, data, num + 1);
-   }
+     {
+       if (ecore_x_netwm_window_state_isset(win, state))
+         {
+            XFree(old_data);
+            return;
+         }
+       newset = calloc(num + 1, sizeof(Ecore_X_Atom));
+       if (!newset) return;
+       data = (unsigned char *) newset;
+
+       for (i = 0; i < num; i++)
+         newset[i] = oldset[i];
+       newset[num] = atom;
+
+       ecore_x_window_prop_property_set(win, ECORE_X_ATOM_NET_WM_STATE,
+                                        XA_ATOM, 32, data, num + 1);
+     }
    else
-   {
-      if (!ecore_x_netwm_window_state_isset(win, state))
-      {
-         XFree(old_data);
-         return;
-      }
-      newset = calloc(num - 1, sizeof(Atom));
-      if (!newset)
-      {
-         XFree(old_data);
-         return;
-      }
-      data = (unsigned char *) newset;
-      for (i = 0; i < num; i++)
-         if (oldset[i] != atom)
-            newset[j++] = oldset[i];
-
-      ecore_x_window_prop_property_set(win, ECORE_X_ATOM_NET_WM_STATE,
-                                      XA_ATOM, 32, data, num - 1);
-   }
+     {
+       if (!ecore_x_netwm_window_state_isset(win, state))
+         {
+            XFree(old_data);
+            return;
+         }
+       newset = calloc(num - 1, sizeof(Atom));
+       if (!newset)
+         {
+            XFree(old_data);
+            return;
+         }
+       data = (unsigned char *) newset;
+       for (i = 0; i < num; i++)
+         if (oldset[i] != atom)
+           newset[j++] = oldset[i];
+
+       ecore_x_window_prop_property_set(win, ECORE_X_ATOM_NET_WM_STATE,
+                                        XA_ATOM, 32, data, num - 1);
+     }
    XFree(oldset);
    free(newset);
 }
@@ -906,26 +905,26 @@
 _ecore_x_netwm_window_type_atom_get(Ecore_X_Window_Type type)
 {
    switch (type)
-   {
+     {
       case ECORE_X_WINDOW_TYPE_DESKTOP:
-         return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DESKTOP;
+        return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DESKTOP;
       case ECORE_X_WINDOW_TYPE_DOCK:
-         return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DOCK;
+        return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DOCK;
       case ECORE_X_WINDOW_TYPE_TOOLBAR:
-         return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_TOOLBAR;
+        return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_TOOLBAR;
       case ECORE_X_WINDOW_TYPE_MENU:
-         return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_MENU;
+        return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_MENU;
       case ECORE_X_WINDOW_TYPE_UTILITY:
-         return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_UTILITY;
+        return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_UTILITY;
       case ECORE_X_WINDOW_TYPE_SPLASH:
-         return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_SPLASH;
+        return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_SPLASH;
       case ECORE_X_WINDOW_TYPE_DIALOG:
-         return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DIALOG;
+        return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_DIALOG;
       case ECORE_X_WINDOW_TYPE_NORMAL:
-         return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NORMAL;
+        return ECORE_X_ATOM_NET_WM_WINDOW_TYPE_NORMAL;
       default:
-         return 0;
-   }
+        return 0;
+     }
 }
 
 /*
@@ -962,14 +961,14 @@
    atoms = (Ecore_X_Atom *) data;
 
    for (i = 0; i < num; ++i)
-   {
-      type = _ecore_x_netwm_window_type_type_get(atoms[i]);
-      if (type)
-       {
-          ret = type;
-          break;
-       }
-   }
+     {
+       type = _ecore_x_netwm_window_type_type_get(atoms[i]);
+       if (type)
+         {
+            ret = type;
+            break;
+         }
+     }
 
    XFree(data);
    return ret;
@@ -1020,13 +1019,13 @@
    atoms = (Ecore_X_Atom *) data;
 
    for (i = 0; i < num; ++i)
-   {
-      if (atom == atoms[i])
-       {
-          ret = 1;
-          break;
-       }
-   }
+     {
+       if (atom == atoms[i])
+         {
+            ret = 1;
+            break;
+         }
+     }
 
    XFree(data);
    return ret;
@@ -1048,44 +1047,44 @@
    oldset = (Ecore_X_Atom *) old_data;
 
    if (on)
-   {
-      if (ecore_x_netwm_allowed_action_isset(win, action))
-      {
-         XFree(old_data);
-         return;
-      }
-      newset = calloc(num + 1, sizeof(Ecore_X_Atom));
-      if (!newset) return;
-      data = (unsigned char *) newset;
-
-      for (i = 0; i < num; i++)
-         newset[i] = oldset[i];
-      newset[num] = atom;
-
-      ecore_x_window_prop_property_set(win, 
ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS,
-                                      XA_ATOM, 32, data, num + 1);
-   }
+     {
+       if (ecore_x_netwm_allowed_action_isset(win, action))
+         {
+            XFree(old_data);
+            return;
+         }
+       newset = calloc(num + 1, sizeof(Ecore_X_Atom));
+       if (!newset) return;
+       data = (unsigned char *) newset;
+
+       for (i = 0; i < num; i++)
+         newset[i] = oldset[i];
+       newset[num] = atom;
+
+       ecore_x_window_prop_property_set(win, 
ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS,
+                                        XA_ATOM, 32, data, num + 1);
+     }
    else
-   {
-      if (!ecore_x_netwm_allowed_action_isset(win, action))
-      {
-         XFree(old_data);
-         return;
-      }
-      newset = calloc(num - 1, sizeof(Atom));
-      if (!newset)
-      {
-         XFree(old_data);
-         return;
-      }
-      data = (unsigned char *) newset;
-      for (i = 0; i < num; i++)
-         if (oldset[i] != atom)
-            newset[j++] = oldset[i];
-
-      ecore_x_window_prop_property_set(win, 
ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS,
-                                      XA_ATOM, 32, data, num - 1);
-   }
+     {
+       if (!ecore_x_netwm_allowed_action_isset(win, action))
+         {
+            XFree(old_data);
+            return;
+         }
+       newset = calloc(num - 1, sizeof(Atom));
+       if (!newset)
+         {
+            XFree(old_data);
+            return;
+         }
+       data = (unsigned char *) newset;
+       for (i = 0; i < num; i++)
+         if (oldset[i] != atom)
+           newset[j++] = oldset[i];
+
+       ecore_x_window_prop_property_set(win, 
ECORE_X_ATOM_NET_WM_ALLOWED_ACTIONS,
+                                        XA_ATOM, 32, data, num - 1);
+     }
    XFree(oldset);
    free(newset);
 }




-------------------------------------------------------
This SF.net email is sponsored by: 2005 Windows Mobile Application Contest
Submit applications for Windows Mobile(tm)-based Pocket PCs or Smartphones
for the chance to win $25,000 and application distribution. Enter today at
http://ads.osdn.com/?ad_id=6882&alloc_id=15148&op=click
_______________________________________________
enlightenment-cvs mailing list
enlightenment-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to