work work work :)


			
			
				devs/princeamd/enlightenment-0.17-elive
			
			
		
Carsten Haitzler 21 years ago
parent ce769c8f21
commit 94b8a4d832
  1. 1
      src/actions.c
  2. 5
      src/border.c
  3. 4
      src/border.h
  4. 10
      src/desktops.c
  5. 70
      src/icccm.c
  6. 6
      src/icccm.h

@ -600,6 +600,7 @@ e_act_move_stop (void *o, E_Action *a, void *data, int x, int y, int rx, int ry
b->current.visible = 1;
e_border_adjust_limits(b);
e_guides_hide();
e_desktops_add_border(b->desk, b);
return;
UN(a);
UN(data);

@ -1194,6 +1194,11 @@ e_border_adopt(Window win, int use_client_pos)
e_icccm_get_mwm_hints(win, b);
e_icccm_get_layer(win, b);
e_icccm_get_title(win, b);
e_icccm_get_class(win, b);
e_icccm_get_hints(win, b);
e_icccm_get_machine(win, b);
e_icccm_get_command(win, b);
e_icccm_get_icon_name(win, b);
b->current.shaped_client = e_icccm_is_shaped(win);
/* we have now placed the bugger */
b->placed = 1;

@ -76,6 +76,9 @@ struct _E_Border
char *name;
char *class;
char *command;
char *machine;
char *icon_name;
int pid;
Window group;
int takes_focus;
int sticky;
@ -87,6 +90,7 @@ struct _E_Border
int titlebar;
int border;
int handles;
int initial_state;
int is_desktop;
int w, h;
struct {

@ -101,7 +101,7 @@ e_desktops_scroll(E_Desktop *desk, int dx, int dy)
b = l->data;
/* if sticky */
if (b->client.sticky)
if ((b->client.sticky) && (!b->mode.move))
e_window_gravity_set(b->win.main, StaticGravity);
else
e_window_gravity_set(b->win.main, grav);
@ -131,7 +131,7 @@ e_desktops_scroll(E_Desktop *desk, int dx, int dy)
b = l->data;
e_window_gravity_reset(b->win.main);
if (!b->client.sticky)
if ((!b->client.sticky) && (!b->mode.move))
{
b->current.requested.x += dx;
b->current.requested.y += dy;
@ -329,7 +329,7 @@ e_desktops_goto(int d, int ax, int ay)
E_Border *b;
b = l->data;
if (!b->client.sticky)
if ((!b->client.sticky) && (!b->mode.move))
{
if (b->client.desk != d)
{
@ -358,5 +358,7 @@ e_desktops_goto(int d, int ax, int ay)
desk->desk.desk = d;
desk->desk.area.x = ax;
desk->desk.area.y = ay;
}
e_icccm_set_desk_area(0, desk->desk.area.x, desk->desk.area.y);
e_icccm_set_desk(0, desk->desk.desk);
}
}

@ -318,6 +318,56 @@ e_icccm_get_title(Window win, E_Border *b)
else e_strdup(b->client.title, "No Title");
}
void
e_icccm_get_class(Window win, E_Border *b)
{
IF_FREE(b->client.name);
IF_FREE(b->client.class);
b->client.name = NULL;
b->client.class = NULL;
e_window_get_name_class(win, &(b->client.name), &(b->client.class));
if (!b->client.name) e_strdup(b->client.name, "Unknown");
if (!b->client.class) e_strdup(b->client.class, "Unknown");
}
void
e_icccm_get_hints(Window win, E_Border *b)
{
e_window_get_hints(win, &(b->client.takes_focus),
&(b->client.initial_state), NULL, NULL, NULL,
&(b->client.group));
}
void
e_icccm_get_machine(Window win, E_Border *b)
{
IF_FREE(b->client.machine);
b->client.machine = NULL;
b->client.machine = e_window_get_machine(win);
}
void
e_icccm_get_command(Window win, E_Border *b)
{
IF_FREE(b->client.command);
b->client.command = NULL;
b->client.command = e_window_get_command(win);
}
void
e_icccm_get_icon_name(Window win, E_Border *b)
{
IF_FREE(b->client.icon_name);
b->client.icon_name = NULL;
b->client.icon_name = e_window_get_icon_name(win);
}
void
e_icccm_get_state(Window win, E_Border *b)
{
}
void
e_icccm_set_frame_size(Window win, int l, int r, int t, int b)
{
@ -391,14 +441,32 @@ e_icccm_handle_property_change(Atom a, E_Border *b)
static Atom a_wm_normal_hints = 0;
static Atom a_motif_wm_hints = 0;
static Atom a_wm_name = 0;
static Atom a_wm_class = 0;
static Atom a_wm_hints = 0;
static Atom a_wm_client_machine = 0;
static Atom a_wm_command = 0;
static Atom a_wm_icon_name = 0;
static Atom a_wm_state = 0;
E_ATOM(a_wm_normal_hints, "WM_NORMAL_HINTS");
E_ATOM(a_motif_wm_hints, "_MOTIF_WM_HINTS");
E_ATOM(a_wm_name, "WM_NAME");
E_ATOM(a_wm_class, "WM_CLASS");
E_ATOM(a_wm_hints, "WM_HINTS");
E_ATOM(a_wm_client_machine, "WM_CLIENT_MACHINE");
E_ATOM(a_wm_command, "WM_COMMAND");
E_ATOM(a_wm_icon_name, "WM_ICON_NAME");
E_ATOM(a_wm_state, "WM_STATE");
if (a == a_wm_normal_hints) e_icccm_get_size_info(b->win.client, b);
else if (a == a_motif_wm_hints) e_icccm_get_mwm_hints(b->win.client, b);
else if (a == a_wm_name) e_icccm_get_title(b->win.client, b);
else if (a == a_wm_class) e_icccm_get_class(b->win.client, b);
else if (a == a_wm_hints) e_icccm_get_hints(b->win.client, b);
else if (a == a_wm_client_machine) e_icccm_get_machine(b->win.client, b);
else if (a == a_wm_command) e_icccm_get_command(b->win.client, b);
else if (a == a_wm_icon_name) e_icccm_get_icon_name(b->win.client, b);
else if (a == a_wm_state) e_icccm_get_state(b->win.client, b);
}
void

@ -15,6 +15,12 @@ void e_icccm_get_size_info(Window win, E_Border *b);
void e_icccm_get_mwm_hints(Window win, E_Border *b);
void e_icccm_get_layer(Window win, E_Border *b);
void e_icccm_get_title(Window win, E_Border *b);
void e_icccm_get_class(Window win, E_Border *b);
void e_icccm_get_hints(Window win, E_Border *b);
void e_icccm_get_machine(Window win, E_Border *b);
void e_icccm_get_command(Window win, E_Border *b);
void e_icccm_get_icon_name(Window win, E_Border *b);
void e_icccm_get_state(Window win, E_Border *b);
void e_icccm_set_frame_size(Window win, int l, int r, int t, int b);
void e_icccm_set_desk_area(Window win, int ax, int ay);
void e_icccm_set_desk_area_size(Window win, int ax, int ay);

Loading…
Cancel
Save