forked from enlightenment/efl
parent
81715399a1
commit
9b891c8217
|
@ -31,4 +31,4 @@ ecore_value.c \
|
||||||
ecore_private.h
|
ecore_private.h
|
||||||
|
|
||||||
libecore_la_LIBADD = -lm @dlopen_libs@ @winsock_libs@
|
libecore_la_LIBADD = -lm @dlopen_libs@ @winsock_libs@
|
||||||
libecore_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0
|
libecore_la_LDFLAGS = -version-info 1:0:0
|
||||||
|
|
|
@ -7,7 +7,7 @@ INCLUDES = \
|
||||||
-I$(top_srcdir)/src/lib/ecore_con \
|
-I$(top_srcdir)/src/lib/ecore_con \
|
||||||
@SSL_CFLAGS@
|
@SSL_CFLAGS@
|
||||||
|
|
||||||
libecore_con_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0 \
|
libecore_con_la_LDFLAGS = -version-info 1:0:0 \
|
||||||
-L$(top_builddir)/src/lib/ecore/.libs
|
-L$(top_builddir)/src/lib/ecore/.libs
|
||||||
|
|
||||||
if BUILD_ECORE_CON
|
if BUILD_ECORE_CON
|
||||||
|
|
|
@ -11,10 +11,10 @@ INCLUDES = \
|
||||||
|
|
||||||
CLEANFILES = $(DB)
|
CLEANFILES = $(DB)
|
||||||
|
|
||||||
libecore_config_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0 \
|
libecore_config_la_LDFLAGS = -version-info 1:0:0 \
|
||||||
-L$(top_builddir)/src/lib/ecore/.libs
|
-L$(top_builddir)/src/lib/ecore/.libs
|
||||||
|
|
||||||
ecore_config_ipc_ecore_la_LDFLAGS = $(LDFLAGS) -no-undefined -module \
|
ecore_config_ipc_ecore_la_LDFLAGS = -no-undefined -module \
|
||||||
-avoid-version -rdynamic -shared
|
-avoid-version -rdynamic -shared
|
||||||
|
|
||||||
if BUILD_ECORE_CONFIG
|
if BUILD_ECORE_CONFIG
|
||||||
|
|
|
@ -29,7 +29,7 @@ $(ECORE_X_INC) \
|
||||||
$(ECORE_FB_INC) \
|
$(ECORE_FB_INC) \
|
||||||
@evas_cflags@
|
@evas_cflags@
|
||||||
|
|
||||||
libecore_evas_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0 \
|
libecore_evas_la_LDFLAGS = -version-info 1:0:0 \
|
||||||
$(ECORE_X_LDF) \
|
$(ECORE_X_LDF) \
|
||||||
$(ECORE_FB_LDF) \
|
$(ECORE_FB_LDF) \
|
||||||
-L$(top_builddir)/src/lib/ecore/.libs
|
-L$(top_builddir)/src/lib/ecore/.libs
|
||||||
|
|
|
@ -4,7 +4,7 @@ INCLUDES = \
|
||||||
-I$(top_srcdir)/src/lib/ecore \
|
-I$(top_srcdir)/src/lib/ecore \
|
||||||
-I$(top_builddir)/src/lib/ecore
|
-I$(top_builddir)/src/lib/ecore
|
||||||
|
|
||||||
libecore_fb_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0 \
|
libecore_fb_la_LDFLAGS = -version-info 1:0:0 \
|
||||||
-L$(top_builddir)/src/lib/ecore/.libs
|
-L$(top_builddir)/src/lib/ecore/.libs
|
||||||
|
|
||||||
if BUILD_ECORE_FB
|
if BUILD_ECORE_FB
|
||||||
|
|
|
@ -9,7 +9,7 @@ INCLUDES = \
|
||||||
-I$(top_srcdir)/src/lib/ecore_ipc \
|
-I$(top_srcdir)/src/lib/ecore_ipc \
|
||||||
@SSL_CFLAGS@
|
@SSL_CFLAGS@
|
||||||
|
|
||||||
libecore_ipc_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0 \
|
libecore_ipc_la_LDFLAGS = -version-info 1:0:0 \
|
||||||
-L$(top_builddir)/src/lib/ecore/.libs \
|
-L$(top_builddir)/src/lib/ecore/.libs \
|
||||||
-L$(top_builddir)/src/lib/ecore_con/.libs
|
-L$(top_builddir)/src/lib/ecore_con/.libs
|
||||||
|
|
||||||
|
|
|
@ -4,7 +4,7 @@ INCLUDES = \
|
||||||
-I$(top_srcdir)/src/lib/ecore \
|
-I$(top_srcdir)/src/lib/ecore \
|
||||||
-I$(top_builddir)/src/lib/ecore
|
-I$(top_builddir)/src/lib/ecore
|
||||||
|
|
||||||
libecore_job_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0 \
|
libecore_job_la_LDFLAGS = -version-info 1:0:0 \
|
||||||
-L$(top_builddir)/src/lib/ecore/.libs
|
-L$(top_builddir)/src/lib/ecore/.libs
|
||||||
|
|
||||||
if BUILD_ECORE_JOB
|
if BUILD_ECORE_JOB
|
||||||
|
|
|
@ -5,7 +5,7 @@ INCLUDES = \
|
||||||
-I$(top_builddir)/src/lib/ecore \
|
-I$(top_builddir)/src/lib/ecore \
|
||||||
@iconv_cflags@
|
@iconv_cflags@
|
||||||
|
|
||||||
libecore_txt_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0 \
|
libecore_txt_la_LDFLAGS = -version-info 1:0:0 \
|
||||||
-L$(top_builddir)/src/lib/ecore/.libs
|
-L$(top_builddir)/src/lib/ecore/.libs
|
||||||
|
|
||||||
if BUILD_ECORE_TXT
|
if BUILD_ECORE_TXT
|
||||||
|
|
|
@ -869,6 +869,47 @@ void ecore_x_gc_del(Ecore_X_GC gc);
|
||||||
int ecore_x_client_message32_send(Ecore_X_Window win, Ecore_X_Atom type, long d0, long d1, long d2, long d3, long d4);
|
int ecore_x_client_message32_send(Ecore_X_Window win, Ecore_X_Atom type, long d0, long d1, long d2, long d3, long d4);
|
||||||
int ecore_x_client_message8_send(Ecore_X_Window win, Ecore_X_Atom type, const void *data, int len);
|
int ecore_x_client_message8_send(Ecore_X_Window win, Ecore_X_Atom type, const void *data, int len);
|
||||||
|
|
||||||
|
#if 0 /* ??? */
|
||||||
|
void ecore_x_netwm_init(void);
|
||||||
|
#endif
|
||||||
|
void ecore_x_netwm_desk_count_set(Ecore_X_Window root, int n_desks);
|
||||||
|
void ecore_x_netwm_desk_roots_set(Ecore_X_Window root, int n_desks, Ecore_X_Window * vroots);
|
||||||
|
void ecore_x_netwm_desk_names_set(Ecore_X_Window root, int n_desks, const char **names);
|
||||||
|
void ecore_x_netwm_desk_size_set(Ecore_X_Window root, int width, int height);
|
||||||
|
void ecore_x_netwm_desk_workareas_set(Ecore_X_Window root, int n_desks, int *areas);
|
||||||
|
void ecore_x_netwm_desk_current_set(Ecore_X_Window root, int desk);
|
||||||
|
void ecore_x_netwm_desk_viewports_set(Ecore_X_Window root, int n_desks, int *origins);
|
||||||
|
void ecore_x_netwm_showing_desktop_set(Ecore_X_Window root, int on);
|
||||||
|
void ecore_x_netwm_client_list_set(Ecore_X_Window root, int n_clients, Ecore_X_Window * p_clients);
|
||||||
|
void ecore_x_netwm_client_list_stacking_set(Ecore_X_Window root, int n_clients, Ecore_X_Window * p_clients);
|
||||||
|
void ecore_x_netwm_client_active_set(Ecore_X_Window root, Ecore_X_Window win);
|
||||||
|
|
||||||
|
/* FIXME: these funcs need categorising */
|
||||||
|
void ecore_x_drawable_geometry_get(Ecore_X_Drawable d, int *x, int *y, int *w, int *h);
|
||||||
|
int ecore_x_drawable_border_width_get(Ecore_X_Drawable d);
|
||||||
|
int ecore_x_drawable_depth_get(Ecore_X_Drawable d);
|
||||||
|
Ecore_X_Window *ecore_x_window_root_list(int *num_ret);
|
||||||
|
int ecore_x_window_manage(Ecore_X_Window win);
|
||||||
|
void ecore_x_window_container_manage(Ecore_X_Window win);
|
||||||
|
void ecore_x_window_client_manage(Ecore_X_Window win);
|
||||||
|
void ecore_x_window_sniff(Ecore_X_Window win);
|
||||||
|
void ecore_x_window_client_sniff(Ecore_X_Window win);
|
||||||
|
Ecore_X_Atom ecore_x_atom_get(char *name);
|
||||||
|
|
||||||
|
typedef enum _Ecore_X_Gravity {
|
||||||
|
ECORE_X_GRAVITY_FORGET = 0,
|
||||||
|
ECORE_X_GRAVITY_UNMAP = 0,
|
||||||
|
ECORE_X_GRAVITY_NW = 1,
|
||||||
|
ECORE_X_GRAVITY_N = 2,
|
||||||
|
ECORE_X_GRAVITY_NE = 3,
|
||||||
|
ECORE_X_GRAVITY_W = 4,
|
||||||
|
ECORE_X_GRAVITY_CENTER = 5,
|
||||||
|
ECORE_X_GRAVITY_E = 6,
|
||||||
|
ECORE_X_GRAVITY_SW = 7,
|
||||||
|
ECORE_X_GRAVITY_S = 8,
|
||||||
|
ECORE_X_GRAVITY_SE = 9,
|
||||||
|
ECORE_X_GRAVITY_STATIC = 10
|
||||||
|
} Ecore_X_Gravity;
|
||||||
void
|
void
|
||||||
ecore_x_icccm_state_set(Ecore_X_Window win, Ecore_X_Window_State_Hint state);
|
ecore_x_icccm_state_set(Ecore_X_Window win, Ecore_X_Window_State_Hint state);
|
||||||
void
|
void
|
||||||
|
@ -898,7 +939,28 @@ int ecore_x_client_message8_send(Ecore_X_Window win, Ecore_X_Atom t
|
||||||
Ecore_X_Window *icon_window,
|
Ecore_X_Window *icon_window,
|
||||||
Ecore_X_Window *window_group,
|
Ecore_X_Window *window_group,
|
||||||
int *is_urgent);
|
int *is_urgent);
|
||||||
|
void
|
||||||
|
ecore_x_icccm_size_pos_hints_set(Ecore_X_Window win,
|
||||||
|
int request_pos,
|
||||||
|
Ecore_X_Gravity gravity,
|
||||||
|
int min_w, int min_h,
|
||||||
|
int max_w, int max_h,
|
||||||
|
int base_w, int base_h,
|
||||||
|
int step_x, int step_y,
|
||||||
|
double min_aspect,
|
||||||
|
double max_aspect);
|
||||||
|
|
||||||
|
int
|
||||||
|
ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win,
|
||||||
|
int *request_pos,
|
||||||
|
Ecore_X_Gravity *gravity,
|
||||||
|
int *min_w, int *min_h,
|
||||||
|
int *max_w, int *max_h,
|
||||||
|
int *base_w, int *base_h,
|
||||||
|
int *step_x, int *step_y,
|
||||||
|
double *min_aspect,
|
||||||
|
double *max_aspect);
|
||||||
|
|
||||||
void ecore_x_netwm_init(void);
|
void ecore_x_netwm_init(void);
|
||||||
void ecore_x_netwm_wm_identify(Ecore_X_Window root, Ecore_X_Window check, const char *wm_name);
|
void ecore_x_netwm_wm_identify(Ecore_X_Window root, Ecore_X_Window check, const char *wm_name);
|
||||||
void ecore_x_netwm_desk_count_set(Ecore_X_Window root, int n_desks);
|
void ecore_x_netwm_desk_count_set(Ecore_X_Window root, int n_desks);
|
||||||
|
|
|
@ -9,7 +9,7 @@ INCLUDES = \
|
||||||
-I$(top_builddir)/src/lib/ecore_job \
|
-I$(top_builddir)/src/lib/ecore_job \
|
||||||
@x_cflags@
|
@x_cflags@
|
||||||
|
|
||||||
libecore_x_la_LDFLAGS = $(LDFLAGS) -version-info 1:0:0 \
|
libecore_x_la_LDFLAGS = -version-info 1:0:0 \
|
||||||
-L$(top_builddir)/src/lib/ecore/.libs \
|
-L$(top_builddir)/src/lib/ecore/.libs \
|
||||||
-L$(top_builddir)/src/lib/ecore_txt/.libs \
|
-L$(top_builddir)/src/lib/ecore_txt/.libs \
|
||||||
-L$(top_builddir)/src/lib/ecore_job/.libs
|
-L$(top_builddir)/src/lib/ecore_job/.libs
|
||||||
|
|
|
@ -182,79 +182,145 @@ ecore_x_icccm_hints_get(Ecore_X_Window win,
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* FIXME: working here */
|
void
|
||||||
|
ecore_x_icccm_size_pos_hints_set(Ecore_X_Window win,
|
||||||
|
int request_pos,
|
||||||
|
Ecore_X_Gravity gravity,
|
||||||
|
int min_w, int min_h,
|
||||||
|
int max_w, int max_h,
|
||||||
|
int base_w, int base_h,
|
||||||
|
int step_x, int step_y,
|
||||||
|
double min_aspect,
|
||||||
|
double max_aspect)
|
||||||
|
{
|
||||||
|
/* FIXME: working here */
|
||||||
|
XSizeHints hint;
|
||||||
|
|
||||||
|
hint.flags = 0;
|
||||||
|
if (request_pos)
|
||||||
|
{
|
||||||
|
hint.flags |= USPosition;
|
||||||
|
}
|
||||||
|
if (gravity != ECORE_X_GRAVITY_NW)
|
||||||
|
{
|
||||||
|
hint.flags |= PWinGravity;
|
||||||
|
hint.win_gravity = gravity;
|
||||||
|
}
|
||||||
|
if ((min_w > 0) || (min_h > 0))
|
||||||
|
{
|
||||||
|
hint.flags |= PMinSize;
|
||||||
|
hint.min_width = min_w;
|
||||||
|
hint.min_height = min_h;
|
||||||
|
}
|
||||||
|
if ((max_w > 0) || (max_h > 0))
|
||||||
|
{
|
||||||
|
hint.flags |= PMaxSize;
|
||||||
|
hint.max_width = max_w;
|
||||||
|
hint.max_height = max_h;
|
||||||
|
}
|
||||||
|
if ((base_w > 0) || (base_h > 0))
|
||||||
|
{
|
||||||
|
hint.flags |= PBaseSize;
|
||||||
|
hint.base_width = base_w;
|
||||||
|
hint.base_height = base_h;
|
||||||
|
}
|
||||||
|
if ((step_x > 1) || (step_y > 1))
|
||||||
|
{
|
||||||
|
hint.flags |= PResizeInc;
|
||||||
|
hint.width_inc = step_x;
|
||||||
|
hint.height_inc = step_y;
|
||||||
|
}
|
||||||
|
if ((min_aspect > 0.0) || (max_aspect > 0.0))
|
||||||
|
{
|
||||||
|
hint.flags |= PAspect;
|
||||||
|
hint.min_aspect.x = min_aspect * 10000;
|
||||||
|
hint.min_aspect.x = 10000;
|
||||||
|
hint.max_aspect.x = max_aspect * 10000;
|
||||||
|
hint.max_aspect.x = 10000;
|
||||||
|
}
|
||||||
|
XSetWMNormalHints(_ecore_x_disp, win, &hint);
|
||||||
|
}
|
||||||
|
|
||||||
int
|
int
|
||||||
ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win)
|
ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win,
|
||||||
|
int *request_pos,
|
||||||
|
Ecore_X_Gravity *gravity,
|
||||||
|
int *min_w, int *min_h,
|
||||||
|
int *max_w, int *max_h,
|
||||||
|
int *base_w, int *base_h,
|
||||||
|
int *step_x, int *step_y,
|
||||||
|
double *min_aspect,
|
||||||
|
double *max_aspect)
|
||||||
{
|
{
|
||||||
XSizeHints hint;
|
XSizeHints hint;
|
||||||
long mask;
|
long mask;
|
||||||
|
|
||||||
|
int minw = 0, minh = 0;
|
||||||
|
int maxw = 32767, maxh = 32767;
|
||||||
|
int basew = 0, baseh = 0;
|
||||||
|
int stepx = 1, stepy = 1;
|
||||||
|
double mina = 0.0, maxa = 0.0;
|
||||||
|
|
||||||
if (!XGetWMNormalHints(_ecore_x_disp, win, &hint, &mask)) return 0;
|
if (!XGetWMNormalHints(_ecore_x_disp, win, &hint, &mask)) return 0;
|
||||||
if ((hint.flags & USPosition) || ((hint.flags & PPosition)))
|
if ((hint.flags & USPosition) || ((hint.flags & PPosition)))
|
||||||
{
|
{
|
||||||
int x, y, w, h;
|
if (*request_pos) *request_pos = 1;
|
||||||
|
|
||||||
// D("%li %li\n", hint.flags & USPosition, hint.flags & PPosition);
|
|
||||||
// b->client.pos.requested = 1;
|
|
||||||
// b->client.pos.gravity = NorthWestGravity;
|
|
||||||
// if (hint.flags & PWinGravity)
|
|
||||||
// b->client.pos.gravity = hint.win_gravity;
|
|
||||||
// x = y = w = h = 0;
|
|
||||||
// ecore_window_get_geometry(win, &x, &y, &w, &h);
|
|
||||||
// b->client.pos.x = x;
|
|
||||||
// b->client.pos.y = y;
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
// b->client.pos.requested = 0;
|
if (*request_pos) *request_pos = 0;
|
||||||
|
}
|
||||||
|
if (hint.flags & PWinGravity)
|
||||||
|
{
|
||||||
|
if (*gravity) *gravity = hint.win_gravity;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if (*gravity) *gravity = ECORE_X_GRAVITY_NW;
|
||||||
}
|
}
|
||||||
if (hint.flags & PMinSize)
|
if (hint.flags & PMinSize)
|
||||||
{
|
{
|
||||||
// min_w = hint.min_width;
|
minw = hint.min_width;
|
||||||
// min_h = hint.min_height;
|
minh = hint.min_height;
|
||||||
}
|
}
|
||||||
if (hint.flags & PMaxSize)
|
if (hint.flags & PMaxSize)
|
||||||
{
|
{
|
||||||
// max_w = hint.max_width;
|
maxw = hint.max_width;
|
||||||
// max_h = hint.max_height;
|
maxh = hint.max_height;
|
||||||
// if (max_w < min_w)
|
if (maxw < minw) maxw = minw;
|
||||||
// max_w = min_w;
|
if (maxh < minh) maxh = minh;
|
||||||
// if (max_h < min_h)
|
|
||||||
// max_h = min_h;
|
|
||||||
}
|
|
||||||
if (hint.flags & PResizeInc)
|
|
||||||
{
|
|
||||||
// step_w = hint.width_inc;
|
|
||||||
// step_h = hint.height_inc;
|
|
||||||
// if (step_w < 1)
|
|
||||||
// step_w = 1;
|
|
||||||
// if (step_h < 1)
|
|
||||||
// step_h = 1;
|
|
||||||
}
|
}
|
||||||
if (hint.flags & PBaseSize)
|
if (hint.flags & PBaseSize)
|
||||||
{
|
{
|
||||||
// base_w = hint.base_width;
|
basew = hint.base_width;
|
||||||
// base_h = hint.base_height;
|
baseh = hint.base_height;
|
||||||
// if (base_w > max_w)
|
if (basew > minw) minw = basew;
|
||||||
// max_w = base_w;
|
if (baseh > minh) minh = baseh;
|
||||||
// if (base_h > max_h)
|
|
||||||
// max_h = base_h;
|
|
||||||
}
|
}
|
||||||
else
|
if (hint.flags & PResizeInc)
|
||||||
{
|
{
|
||||||
// base_w = min_w;
|
stepx = hint.width_inc;
|
||||||
// base_h = min_h;
|
stepy = hint.height_inc;
|
||||||
|
if (stepx < 1) stepx = 1;
|
||||||
|
if (stepy < 1) stepy = 1;
|
||||||
}
|
}
|
||||||
if (hint.flags & PAspect)
|
if (hint.flags & PAspect)
|
||||||
{
|
{
|
||||||
// if (hint.min_aspect.y > 0)
|
if (hint.min_aspect.y > 0)
|
||||||
// aspect_min =
|
mina = ((double)hint.min_aspect.x) / ((double)hint.min_aspect.y);
|
||||||
// ((double)hint.min_aspect.x) / ((double)hint.min_aspect.y);
|
if (hint.max_aspect.y > 0)
|
||||||
// if (hint.max_aspect.y > 0)
|
maxa = ((double)hint.max_aspect.x) / ((double)hint.max_aspect.y);
|
||||||
// aspect_max =
|
|
||||||
// ((double)hint.max_aspect.x) / ((double)hint.max_aspect.y);
|
|
||||||
}
|
}
|
||||||
|
if (min_w) *min_w = minw;
|
||||||
|
if (min_h) *min_h = minh;
|
||||||
|
if (max_w) *max_w = maxw;
|
||||||
|
if (max_h) *max_h = maxh;
|
||||||
|
if (base_w) *base_w = basew;
|
||||||
|
if (base_h) *base_h = baseh;
|
||||||
|
if (step_x) *step_x = stepx;
|
||||||
|
if (step_y) *step_y = stepy;
|
||||||
|
if (min_aspect) *min_aspect = mina;
|
||||||
|
if (max_aspect) *max_aspect = maxa;
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -272,7 +338,7 @@ ecore_x_icccm_size_pos_hints_get(Ecore_X_Window win)
|
||||||
/* get/set transient for */
|
/* get/set transient for */
|
||||||
/* send iconify request */
|
/* send iconify request */
|
||||||
|
|
||||||
/* FIXME: there are older E hints, gnome hitns and mwm hints and new netwm */
|
/* FIXME: there are older E hints, gnome hints and mwm hints and new netwm */
|
||||||
/* hints. each should go in their own file/section so we know which */
|
/* hints. each should go in their own file/section so we know which */
|
||||||
/* is which. also older kde hints too. we shoudl try support as much */
|
/* is which. also older kde hints too. we should try support as much */
|
||||||
/* as makese sense to support */
|
/* as makese sense to support */
|
||||||
|
|
Loading…
Reference in New Issue