mupen64plus-oldsvn/frontends/gtk2/debugger/ui_clist_edit.h

66 lines
2.6 KiB
C

/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Mupen64plus - ui_clist_edit.h *
* Mupen64Plus homepage: http://code.google.com/p/mupen64plus/ *
* Copyright (C) 2002 John Ellis *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the *
* Free Software Foundation, Inc., *
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
#ifndef __UI_CLIST_EDIT_H__
#define __UI_CLIST_EDIT_H__
typedef struct _ClistEditData ClistEditData;
struct _ClistEditData
{
GtkWidget *window;
GtkWidget *entry;
gchar *old_name;
gchar *new_name;
gint (*edit_func)(ClistEditData *ced, const gchar *oldname, const gchar *newname, gpointer data);
gpointer edit_data;
GtkCList *clist;
gint row;
gint column;
};
/*
* edit_func: return TRUE is rename successful, FALSE on failure.
*/
gint clist_edit_by_row(GtkCList *clist, gint row, gint column,
gint (*edit_func)(ClistEditData *, const gchar *, const gchar *, gpointer), gpointer data);
/*
* use this when highlighting a right-click menued or dnd clist row.
*/
void clist_edit_set_highlight(GtkWidget *clist, gint row, gint set);
/*
* Useful for alternating dark/light rows in lists.
*/
void clist_edit_shift_color(GtkStyle *style);
/*
* Various g_list utils, do not really fit anywhere, so they are here.
*/
GList *uig_list_insert_link(GList *list, GList *link, gpointer data);
GList *uig_list_insert_list(GList *parent, GList *insert_link, GList *list);
#endif /* __UI_CLIST_EDIT_H__ */