[gtk+/client-side-decorations: 19/50] fix warnings, remove unneeded code
- From: Cody Russell <bratsche src gnome org>
- To: svn-commits-list gnome org
- Subject: [gtk+/client-side-decorations: 19/50] fix warnings, remove unneeded code
- Date: Wed, 8 Jul 2009 15:29:45 +0000 (UTC)
commit 776216e964db623784361dc409b1e8692c0ffaa2
Author: Cody Russell <crussell canonical com>
Date: Thu May 21 11:55:16 2009 +0200
fix warnings, remove unneeded code
gtk/gtkwindow.c | 94 -------------------------------------------------------
1 files changed, 0 insertions(+), 94 deletions(-)
---
diff --git a/gtk/gtkwindow.c b/gtk/gtkwindow.c
index 3114384..599d731 100644
--- a/gtk/gtkwindow.c
+++ b/gtk/gtkwindow.c
@@ -214,8 +214,6 @@ static void gtk_window_size_request (GtkWidget *widget,
GtkRequisition *requisition);
static void gtk_window_size_allocate (GtkWidget *widget,
GtkAllocation *allocation);
-static gint gtk_window_event (GtkWidget *widget,
- GdkEvent *event);
static gboolean gtk_window_map_event (GtkWidget *widget,
GdkEventAny *event);
static gboolean gtk_window_frame_event (GtkWindow *window,
@@ -308,10 +306,6 @@ static GtkKeyHash *gtk_window_get_key_hash (GtkWindow *window);
static void gtk_window_free_key_hash (GtkWindow *window);
static void gtk_window_on_composited_changed (GdkScreen *screen,
GtkWindow *window);
-static void gtk_window_compute_child_allocation (GtkWindow *window,
- GtkAllocation *child_allocation);
-static void gtk_window_real_compute_child_allocation (GtkWindow *window,
- GtkAllocation *child_allocation);
static void gtk_window_set_label_widget (GtkWindow *window,
GtkWidget *label);
@@ -366,8 +360,6 @@ static void gtk_window_forall (GtkContainer *container,
gboolean include_internals,
GtkCallback callback,
gpointer callback_data);
-static void gtk_window_remove (GtkContainer *container,
- GtkWidget *child);
G_DEFINE_TYPE_WITH_CODE (GtkWindow, gtk_window, GTK_TYPE_BIN,
@@ -488,11 +480,9 @@ gtk_window_class_init (GtkWindowClass *klass)
container_class->check_resize = gtk_window_check_resize;
container_class->forall = gtk_window_forall;
- container_class->remove = gtk_window_remove;
klass->set_focus = gtk_window_real_set_focus;
klass->frame_event = gtk_window_frame_event;
- klass->compute_child_allocation = gtk_window_real_compute_child_allocation;
klass->activate_default = gtk_window_real_activate_default;
klass->activate_focus = gtk_window_real_activate_focus;
klass->move_focus = gtk_window_move_focus;
@@ -5115,7 +5105,6 @@ gtk_window_size_allocate (GtkWidget *widget,
GtkWindow *window;
GtkContainer *container;
GtkAllocation child_allocation;
- GtkAllocation new_allocation;
GtkWindowPrivate *priv;
GtkRequisition deco_requisition;
GtkAllocation deco_allocation;
@@ -5167,78 +5156,6 @@ gtk_window_size_allocate (GtkWidget *widget,
}
}
-static void
-gtk_window_compute_child_allocation (GtkWindow *window,
- GtkAllocation *child_allocation)
-{
- g_return_if_fail (GTK_IS_WINDOW (window));
- g_return_if_fail (child_allocation != NULL);
-
- GTK_WINDOW_GET_CLASS (window)->compute_child_allocation (window, child_allocation);
-}
-
-static void
-gtk_window_real_compute_child_allocation (GtkWindow *window,
- GtkAllocation *child_allocation)
-{
- GtkWidget *widget = GTK_WIDGET (window);
- GtkWindowPrivate *priv = GTK_WINDOW_GET_PRIVATE (window);
- GtkAllocation *allocation = &widget->allocation;
- GtkRequisition child_requisition;
- gint top_margin;
-
- if (priv->title_hbox)
- {
- gtk_widget_get_child_requisition (priv->title_hbox, &child_requisition);
- top_margin = MAX (child_requisition.height, widget->style->ythickness);
- }
- else
- {
- top_margin = widget->style->ythickness;
- }
-
- child_allocation->x = (GTK_CONTAINER (window)->border_width +
- widget->style->xthickness);
- child_allocation->width = MAX(1, (gint)allocation->width - child_allocation->x * 2);
-
- child_allocation->y = (GTK_CONTAINER (window)->border_width + top_margin);
- child_allocation->height = MAX (1, ((gint)allocation->height - child_allocation->y -
- (gint)GTK_CONTAINER (window)->border_width -
- (gint)widget->style->ythickness));
-
- child_allocation->x += allocation->x;
- child_allocation->y += allocation->y;
-}
-
-static gint
-gtk_window_event (GtkWidget *widget, GdkEvent *event)
-{
- GtkWindow *window;
- gboolean return_val;
-
- window = GTK_WINDOW (widget);
-
- if (window->frame && (event->any.window == window->frame))
- {
- if ((event->type != GDK_KEY_PRESS) &&
- (event->type != GDK_KEY_RELEASE) &&
- (event->type != GDK_FOCUS_CHANGE))
- {
- g_signal_stop_emission_by_name (widget, "event");
- return_val = FALSE;
- g_signal_emit (widget, window_signals[FRAME_EVENT], 0, event, &return_val);
- return TRUE;
- }
- else
- {
- g_object_unref (event->any.window);
- event->any.window = g_object_ref (widget->window);
- }
- }
-
- return FALSE;
-}
-
static gboolean
gtk_window_frame_event (GtkWindow *window, GdkEvent *event)
{
@@ -5640,15 +5557,6 @@ gtk_window_check_resize (GtkContainer *container)
}
static void
-gtk_window_remove (GtkContainer *container,
- GtkWidget *child)
-{
- GtkWindowPrivate *priv = GTK_WINDOW_GET_PRIVATE (container);
-
- GTK_CONTAINER_CLASS (gtk_window_parent_class)->remove (container, child);
-}
-
-static void
gtk_window_forall (GtkContainer *container,
gboolean include_internals,
GtkCallback callback,
@@ -6942,8 +6850,6 @@ static gint
gtk_window_expose (GtkWidget *widget,
GdkEventExpose *event)
{
- GtkWindowPrivate *priv = GTK_WINDOW_GET_PRIVATE (widget);
-
if (!GTK_WIDGET_APP_PAINTABLE (widget))
gtk_window_paint (widget, &event->area);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]