API: gdk: Remove depth argument from gdk_window_get_geometry()

We don't want to expose depth anymore. If you need it, query the visual.
This commit is contained in:
Benjamin Otte 2010-12-05 14:36:59 +01:00
parent 84fd9b166c
commit 645d0ac403
7 changed files with 10 additions and 15 deletions

View File

@ -304,7 +304,7 @@ gdk_screen_get_monitor_at_window (GdkScreen *screen,
g_return_val_if_fail (GDK_IS_SCREEN (screen), -1);
gdk_window_get_geometry (window, &win_rect.x, &win_rect.y, &win_rect.width,
&win_rect.height, NULL);
&win_rect.height);
gdk_window_get_origin (window, &win_rect.x, &win_rect.y);
num_monitors = gdk_screen_get_n_monitors (screen);

View File

@ -6809,7 +6809,6 @@ gdk_window_set_device_cursor (GdkWindow *window,
* @y: (out) (allow-none): return location for Y coordinate of window (relative to its parent)
* @width: (out) (allow-none): return location for width of window
* @height: (out) (allow-none): return location for height of window
* @depth: (out) (allow-none): return location for bit depth of window
*
* Any of the return location arguments to this function may be %NULL,
* if you aren't interested in getting the value of that field.
@ -6839,8 +6838,7 @@ gdk_window_get_geometry (GdkWindow *window,
gint *x,
gint *y,
gint *width,
gint *height,
gint *depth)
gint *height)
{
GdkWindow *parent;
GdkWindowImplClass *impl_class;
@ -6862,7 +6860,7 @@ gdk_window_get_geometry (GdkWindow *window,
impl_class = GDK_WINDOW_IMPL_GET_CLASS (window->impl);
impl_class->get_geometry (window, x, y,
width, height,
depth);
NULL);
/* This reports the position wrt to the native parent, we need to convert
it to be relative to the client side parent */
parent = window->parent;
@ -6884,8 +6882,6 @@ gdk_window_get_geometry (GdkWindow *window,
*width = window->width;
if (height)
*height = window->height;
if (depth)
*depth = window->depth;
}
}
}

View File

@ -720,8 +720,7 @@ void gdk_window_get_geometry (GdkWindow *window,
gint *x,
gint *y,
gint *width,
gint *height,
gint *depth);
gint *height);
int gdk_window_get_width (GdkWindow *window);
int gdk_window_get_height (GdkWindow *window);
void gdk_window_get_position (GdkWindow *window,

View File

@ -559,7 +559,7 @@ gdk_window_cache_new (GdkScreen *screen)
toplevel_windows = gdk_screen_get_toplevel_windows (screen);
for (list = toplevel_windows; list; list = list->next) {
window = GDK_WINDOW (list->data);
gdk_window_get_geometry (window, &x, &y, &width, &height, NULL);
gdk_window_get_geometry (window, &x, &y, &width, &height);
gdk_window_cache_add (result, GDK_WINDOW_XID (window),
x, y, width, height,
gdk_window_is_visible (window));

View File

@ -3229,7 +3229,7 @@ _gdk_windowing_window_at_device_position (GdkDisplay *display,
pointer_window = child;
break;
}
gdk_window_get_geometry (window, NULL, NULL, &width, &height, NULL);
gdk_window_get_geometry (window, NULL, NULL, &width, &height);
if (winx >= 0 && winy >= 0 && winx < width && winy < height)
{
/* A childless toplevel, or below another window? */
@ -5096,7 +5096,7 @@ calculate_unmoving_origin (MoveResizeData *mv_resize)
{
gdk_window_get_frame_extents (mv_resize->moveresize_window, &rect);
gdk_window_get_geometry (mv_resize->moveresize_window,
NULL, NULL, &width, &height, NULL);
NULL, NULL, &width, &height);
switch (mv_resize->moveresize_geometry.win_gravity)
{

View File

@ -6704,7 +6704,7 @@ gtk_icon_view_autoscroll (GtkIconView *icon_view)
window = gtk_widget_get_window (GTK_WIDGET (icon_view));
gdk_window_get_pointer (window, &px, &py, NULL);
gdk_window_get_geometry (window, &x, &y, &width, &height, NULL);
gdk_window_get_geometry (window, &x, &y, &width, &height);
/* see if we are near the edge. */
voffset = py - (y + 2 * SCROLL_EDGE_SIZE);

View File

@ -362,7 +362,7 @@ gtk_decorated_window_motion_notify (GtkWidget *widget,
win_x += DECORATION_BORDER_LEFT;
win_y += DECORATION_BORDER_TOP;
gdk_window_get_geometry (win, NULL, NULL, &win_w, &win_h, NULL);
gdk_window_get_geometry (win, NULL, NULL, &win_w, &win_h);
if (deco->moving)
{
@ -547,7 +547,7 @@ gtk_decorated_window_window_state (GtkWidget *widget,
{
int w, h;
gdk_window_get_geometry (widget->window, NULL, NULL,
&deco->last_w, &deco->last_h, NULL);
&deco->last_w, &deco->last_h);
gdk_window_get_origin (widget->window, &deco->last_x, &deco->last_y);
w = gdk_screen_get_width(gdk_screen_get_default()) - DECORATION_BORDER_TOT_X;
h = gdk_screen_get_height(gdk_screen_get_default()) - DECORATION_BORDER_TOT_Y;