Commit 553fa430 authored by Jeff Garzik's avatar Jeff Garzik

removed unused var 64-bit cast point to const data Made const-correct.

        * gdk/gdkfont.c: removed unused var
        * gdk/gdkim.c: 64-bit cast
        * gtk/gtkaccelgroup.c: point to const data
        * gtk/gtkdnd.[ch]: (gtk_drag_dest_set, gtk_drag_source_set):
          Made const-correct.
        * gtk/gtkfontsel.c: kill uninitialized var warning
        * gtk/gtkselection.[ch]: (gtk_target_list_new,
          gtk_target_list_add_table, gtk_selection_add_targets):
          Made const-correct.
        * gtk/testgtk.c: 64-bit cast
parent 9775547b
Thu Dec 24 12:40:45 1998 Jeff Garzik <jgarzik@pobox.com>
* gdk/gdkfont.c: removed unused var
* gdk/gdkim.c: 64-bit cast
* gtk/gtkaccelgroup.c: point to const data
* gtk/gtkdnd.[ch]: (gtk_drag_dest_set, gtk_drag_source_set):
Made const-correct.
* gtk/gtkfontsel.c: kill uninitialized var warning
* gtk/gtkselection.[ch]: (gtk_target_list_new,
gtk_target_list_add_table, gtk_selection_add_targets):
Made const-correct.
* gtk/testgtk.c: 64-bit cast
Thu Dec 24 03:16:52 CST 1998 Shawn T. Amundson <amundson@gtk.org>
* Released GTK+ 1.1.10
......
Thu Dec 24 12:40:45 1998 Jeff Garzik <jgarzik@pobox.com>
* gdk/gdkfont.c: removed unused var
* gdk/gdkim.c: 64-bit cast
* gtk/gtkaccelgroup.c: point to const data
* gtk/gtkdnd.[ch]: (gtk_drag_dest_set, gtk_drag_source_set):
Made const-correct.
* gtk/gtkfontsel.c: kill uninitialized var warning
* gtk/gtkselection.[ch]: (gtk_target_list_new,
gtk_target_list_add_table, gtk_selection_add_targets):
Made const-correct.
* gtk/testgtk.c: 64-bit cast
Thu Dec 24 03:16:52 CST 1998 Shawn T. Amundson <amundson@gtk.org>
* Released GTK+ 1.1.10
......
Thu Dec 24 12:40:45 1998 Jeff Garzik <jgarzik@pobox.com>
* gdk/gdkfont.c: removed unused var
* gdk/gdkim.c: 64-bit cast
* gtk/gtkaccelgroup.c: point to const data
* gtk/gtkdnd.[ch]: (gtk_drag_dest_set, gtk_drag_source_set):
Made const-correct.
* gtk/gtkfontsel.c: kill uninitialized var warning
* gtk/gtkselection.[ch]: (gtk_target_list_new,
gtk_target_list_add_table, gtk_selection_add_targets):
Made const-correct.
* gtk/testgtk.c: 64-bit cast
Thu Dec 24 03:16:52 CST 1998 Shawn T. Amundson <amundson@gtk.org>
* Released GTK+ 1.1.10
......
Thu Dec 24 12:40:45 1998 Jeff Garzik <jgarzik@pobox.com>
* gdk/gdkfont.c: removed unused var
* gdk/gdkim.c: 64-bit cast
* gtk/gtkaccelgroup.c: point to const data
* gtk/gtkdnd.[ch]: (gtk_drag_dest_set, gtk_drag_source_set):
Made const-correct.
* gtk/gtkfontsel.c: kill uninitialized var warning
* gtk/gtkselection.[ch]: (gtk_target_list_new,
gtk_target_list_add_table, gtk_selection_add_targets):
Made const-correct.
* gtk/testgtk.c: 64-bit cast
Thu Dec 24 03:16:52 CST 1998 Shawn T. Amundson <amundson@gtk.org>
* Released GTK+ 1.1.10
......
Thu Dec 24 12:40:45 1998 Jeff Garzik <jgarzik@pobox.com>
* gdk/gdkfont.c: removed unused var
* gdk/gdkim.c: 64-bit cast
* gtk/gtkaccelgroup.c: point to const data
* gtk/gtkdnd.[ch]: (gtk_drag_dest_set, gtk_drag_source_set):
Made const-correct.
* gtk/gtkfontsel.c: kill uninitialized var warning
* gtk/gtkselection.[ch]: (gtk_target_list_new,
gtk_target_list_add_table, gtk_selection_add_targets):
Made const-correct.
* gtk/testgtk.c: 64-bit cast
Thu Dec 24 03:16:52 CST 1998 Shawn T. Amundson <amundson@gtk.org>
* Released GTK+ 1.1.10
......
Thu Dec 24 12:40:45 1998 Jeff Garzik <jgarzik@pobox.com>
* gdk/gdkfont.c: removed unused var
* gdk/gdkim.c: 64-bit cast
* gtk/gtkaccelgroup.c: point to const data
* gtk/gtkdnd.[ch]: (gtk_drag_dest_set, gtk_drag_source_set):
Made const-correct.
* gtk/gtkfontsel.c: kill uninitialized var warning
* gtk/gtkselection.[ch]: (gtk_target_list_new,
gtk_target_list_add_table, gtk_selection_add_targets):
Made const-correct.
* gtk/testgtk.c: 64-bit cast
Thu Dec 24 03:16:52 CST 1998 Shawn T. Amundson <amundson@gtk.org>
* Released GTK+ 1.1.10
......
Thu Dec 24 12:40:45 1998 Jeff Garzik <jgarzik@pobox.com>
* gdk/gdkfont.c: removed unused var
* gdk/gdkim.c: 64-bit cast
* gtk/gtkaccelgroup.c: point to const data
* gtk/gtkdnd.[ch]: (gtk_drag_dest_set, gtk_drag_source_set):
Made const-correct.
* gtk/gtkfontsel.c: kill uninitialized var warning
* gtk/gtkselection.[ch]: (gtk_target_list_new,
gtk_target_list_add_table, gtk_selection_add_targets):
Made const-correct.
* gtk/testgtk.c: 64-bit cast
Thu Dec 24 03:16:52 CST 1998 Shawn T. Amundson <amundson@gtk.org>
* Released GTK+ 1.1.10
......
......@@ -521,7 +521,6 @@ gdk_text_extents_wc (GdkFont *font,
int direction;
int font_ascent;
int font_descent;
gint i;
g_return_if_fail (font != NULL);
g_return_if_fail (text != NULL);
......
......@@ -731,7 +731,7 @@ gdk_ic_real_set_attr (GdkIC *ic,
if (mask & GDK_IC_LINE_SPACING)
{
arg->name = XNLineSpace;
arg->value = (gpointer) attr->line_spacing;
arg->value = GINT_TO_POINTER( attr->line_spacing );
if (XSetICValues (xic, XNPreeditAttributes, arg, NULL))
error |= GDK_IC_LINE_SPACING;
......
......@@ -521,7 +521,6 @@ gdk_text_extents_wc (GdkFont *font,
int direction;
int font_ascent;
int font_descent;
gint i;
g_return_if_fail (font != NULL);
g_return_if_fail (text != NULL);
......
......@@ -731,7 +731,7 @@ gdk_ic_real_set_attr (GdkIC *ic,
if (mask & GDK_IC_LINE_SPACING)
{
arg->name = XNLineSpace;
arg->value = (gpointer) attr->line_spacing;
arg->value = GINT_TO_POINTER( attr->line_spacing );
if (XSetICValues (xic, XNPreeditAttributes, arg, NULL))
error |= GDK_IC_LINE_SPACING;
......
......@@ -716,7 +716,7 @@ gtk_accelerator_valid (guint keyval,
GDK_Terminate_Server, GDK_AudibleBell_Enable,
0
};
guint *ac_val;
const guint *ac_val;
modifiers &= GDK_MODIFIER_MASK;
......
......@@ -698,11 +698,11 @@ gtk_drag_unhighlight (GtkWidget *widget)
*************************************************************/
void
gtk_drag_dest_set (GtkWidget *widget,
GtkDestDefaults flags,
GtkTargetEntry *targets,
gint n_targets,
GdkDragAction actions)
gtk_drag_dest_set (GtkWidget *widget,
GtkDestDefaults flags,
const GtkTargetEntry *targets,
gint n_targets,
GdkDragAction actions)
{
GtkDragDestSite *site;
......@@ -1571,11 +1571,11 @@ gtk_drag_begin (GtkWidget *widget,
*************************************************************/
void
gtk_drag_source_set (GtkWidget *widget,
GdkModifierType start_button_mask,
GtkTargetEntry *targets,
gint n_targets,
GdkDragAction actions)
gtk_drag_source_set (GtkWidget *widget,
GdkModifierType start_button_mask,
const GtkTargetEntry *targets,
gint n_targets,
GdkDragAction actions)
{
GtkDragSourceSite *site;
......
......@@ -58,11 +58,11 @@ GtkWidget *gtk_drag_get_source_widget (GdkDragContext *context);
void gtk_drag_highlight (GtkWidget *widget);
void gtk_drag_unhighlight (GtkWidget *widget);
void gtk_drag_dest_set (GtkWidget *widget,
GtkDestDefaults flags,
GtkTargetEntry *targets,
gint n_targets,
GdkDragAction actions);
void gtk_drag_dest_set (GtkWidget *widget,
GtkDestDefaults flags,
const GtkTargetEntry *targets,
gint n_targets,
GdkDragAction actions);
void gtk_drag_dest_set_proxy (GtkWidget *widget,
GdkWindow *proxy_window,
......@@ -77,11 +77,11 @@ void gtk_drag_dest_unset (GtkWidget *widget);
/* Source side */
void gtk_drag_source_set (GtkWidget *widget,
GdkModifierType start_button_mask,
GtkTargetEntry *targets,
gint n_targets,
GdkDragAction actions);
void gtk_drag_source_set (GtkWidget *widget,
GdkModifierType start_button_mask,
const GtkTargetEntry *targets,
gint n_targets,
GdkDragAction actions);
void gtk_drag_source_unset (GtkWidget *widget);
......
......@@ -1264,7 +1264,7 @@ gtk_font_selection_select_best_style(GtkFontSelection *fontsel,
FontInfo *font;
FontStyle *styles;
gint row, prop, style, matched;
gint best_matched = -1, best_style = -1, best_row;
gint best_matched = -1, best_style = -1, best_row = -1;
#ifdef FONTSEL_DEBUG
g_message("In select_best_style\n");
......@@ -1301,6 +1301,7 @@ gtk_font_selection_select_best_style(GtkFontSelection *fontsel,
}
}
g_return_if_fail (best_style != -1);
g_return_if_fail (best_row != -1);
fontsel->style = best_style;
......
......@@ -151,8 +151,8 @@ static const char *gtk_selection_handler_key = "gtk-selection-handlers";
*/
GtkTargetList *
gtk_target_list_new (GtkTargetEntry *targets,
guint ntargets)
gtk_target_list_new (const GtkTargetEntry *targets,
guint ntargets)
{
GtkTargetList *result = g_new (GtkTargetList, 1);
result->list = NULL;
......@@ -206,9 +206,9 @@ gtk_target_list_add (GtkTargetList *list,
}
void
gtk_target_list_add_table (GtkTargetList *list,
GtkTargetEntry *targets,
guint ntargets)
gtk_target_list_add_table (GtkTargetList *list,
const GtkTargetEntry *targets,
guint ntargets)
{
gint i;
......@@ -461,10 +461,10 @@ gtk_selection_add_target (GtkWidget *widget,
}
void
gtk_selection_add_targets (GtkWidget *widget,
GdkAtom selection,
GtkTargetEntry *targets,
guint ntargets)
gtk_selection_add_targets (GtkWidget *widget,
GdkAtom selection,
const GtkTargetEntry *targets,
guint ntargets)
{
GtkTargetList *list;
......
......@@ -56,17 +56,17 @@ struct _GtkTargetPair {
guint info;
};
GtkTargetList *gtk_target_list_new (GtkTargetEntry *targets,
guint ntargets);
GtkTargetList *gtk_target_list_new (const GtkTargetEntry *targets,
guint ntargets);
void gtk_target_list_ref (GtkTargetList *list);
void gtk_target_list_unref (GtkTargetList *list);
void gtk_target_list_add (GtkTargetList *list,
GdkAtom target,
guint flags,
guint info);
void gtk_target_list_add_table (GtkTargetList *list,
GtkTargetEntry *targets,
guint ntargets);
void gtk_target_list_add_table (GtkTargetList *list,
const GtkTargetEntry *targets,
guint ntargets);
void gtk_target_list_remove (GtkTargetList *list,
GdkAtom target);
gboolean gtk_target_list_find (GtkTargetList *list,
......@@ -82,10 +82,10 @@ void gtk_selection_add_target (GtkWidget *widget,
GdkAtom selection,
GdkAtom target,
guint info);
void gtk_selection_add_targets (GtkWidget *widget,
GdkAtom selection,
GtkTargetEntry *targets,
guint ntargets);
void gtk_selection_add_targets (GtkWidget *widget,
GdkAtom selection,
const GtkTargetEntry *targets,
guint ntargets);
gint gtk_selection_convert (GtkWidget *widget,
GdkAtom selection,
GdkAtom target,
......
......@@ -7953,7 +7953,7 @@ static void
toggle_idle_container (GtkObject *button,
GtkContainer *container)
{
gtk_container_set_resize_mode (container, (guint) gtk_object_get_user_data (button));
gtk_container_set_resize_mode (container, GPOINTER_TO_INT (gtk_object_get_user_data (button)));
}
static void
......
......@@ -7953,7 +7953,7 @@ static void
toggle_idle_container (GtkObject *button,
GtkContainer *container)
{
gtk_container_set_resize_mode (container, (guint) gtk_object_get_user_data (button));
gtk_container_set_resize_mode (container, GPOINTER_TO_INT (gtk_object_get_user_data (button)));
}
static void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment