annotate gui/dialog/tools.c @ 36440:019636d54771

Add support for Nios-II architecture. Patch by Ezequiel Garc«ża [ezequiel vanguardiasur com.ar].
author reimar
date Fri, 06 Dec 2013 19:37:07 +0000
parents caf1f563e0ee
children 92159376ad91
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
1 /*
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
2 * This file is part of MPlayer.
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
3 *
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
4 * MPlayer is free software; you can redistribute it and/or modify
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
5 * it under the terms of the GNU General Public License as published by
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
6 * the Free Software Foundation; either version 2 of the License, or
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
7 * (at your option) any later version.
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
8 *
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
9 * MPlayer is distributed in the hope that it will be useful,
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
12 * GNU General Public License for more details.
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
13 *
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
14 * You should have received a copy of the GNU General Public License along
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
15 * with MPlayer; if not, write to the Free Software Foundation, Inc.,
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
17 */
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
18
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
19 #include <gdk/gdkkeysyms.h>
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
20 #include <gtk/gtk.h>
36024
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
21 #include <string.h>
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
22
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
23 #include "tools.h"
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
24
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
25 GtkWidget * gtkAddDialogFrame( GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
26 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
27 GtkWidget * frame;
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
28 frame=gtkAddFrame( NULL,GTK_SHADOW_IN,parent,1 );
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
29 gtk_container_set_border_width( GTK_CONTAINER( frame ),1 );
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
30 frame=gtkAddFrame( NULL,GTK_SHADOW_NONE,frame,1 );
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
31 frame=gtkAddFrame( NULL,GTK_SHADOW_ETCHED_OUT,frame,1 );
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
32 frame=gtkAddFrame( NULL,GTK_SHADOW_NONE,frame,1 );
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
33 return frame;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
34 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
35
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
36 GtkWidget * gtkAddFrame( const char * title,int type,GtkWidget * parent,int add )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
37 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
38 GtkWidget * frame = NULL;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
39 frame=gtk_frame_new( title );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
40 gtk_widget_show( frame );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
41 gtk_frame_set_shadow_type( GTK_FRAME( frame ),type );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
42 if ( !parent ) return frame;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
43 if ( add ) gtk_container_add( GTK_CONTAINER( parent ),frame );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
44 else gtk_box_pack_start( GTK_BOX( parent ),frame,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
45 return frame;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
46 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
47
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
48 GtkWidget * gtkAddLabel( const char * title,GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
49 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
50 GtkWidget * label;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
51 label=gtk_label_new( title );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
52 gtk_widget_show( label );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
53 if ( parent ) gtk_box_pack_start( GTK_BOX( parent ),label,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
54 gtk_misc_set_alignment( GTK_MISC( label ),0,0.5 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
55 gtk_misc_set_padding( GTK_MISC( label ),4,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
56 return label;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
57 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
58
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
59 GtkWidget * gtkAddVBox( GtkWidget * parent,int type )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
60 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
61 GtkWidget * vbox;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
62 vbox=gtk_vbox_new( FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
63 gtk_widget_show( vbox );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
64 if ( parent )
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
65 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
66 if ( type ) gtk_box_pack_start( GTK_BOX( parent ),vbox,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
67 else gtk_container_add( GTK_CONTAINER( parent ),vbox );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
68 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
69 return vbox;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
70 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
71
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
72 GtkWidget * gtkAddHBox( GtkWidget * parent,int type )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
73 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
74 GtkWidget * hbox;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
75 hbox=gtk_hbox_new( FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
76 gtk_widget_show( hbox );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
77 if ( parent )
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
78 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
79 if ( type ) gtk_box_pack_start( GTK_BOX( parent ),hbox,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
80 else gtk_container_add( GTK_CONTAINER( parent ),hbox );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
81 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
82 return hbox;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
83 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
84
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
85 GtkWidget * gtkAddCheckButton( const char * title, GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
86 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
87 GtkWidget * CB;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
88 CB=gtk_check_button_new_with_label( title );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
89 gtk_widget_show( CB );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
90 gtk_box_pack_start( GTK_BOX( parent ),CB,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
91 return CB;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
92 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
93
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
94 GtkWidget * gtkAddRadioButton( const char * title,GSList ** group,GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
95 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
96 GtkWidget * RB;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
97 RB=gtk_radio_button_new_with_label( *group,title );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
98 *group=gtk_radio_button_group( GTK_RADIO_BUTTON( RB ) );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
99 gtk_widget_show( RB );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
100 gtk_box_pack_start( GTK_BOX( parent ),RB,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
101 return RB;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
102 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
103
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
104 GtkWidget * gtkAddSpinButton( const char * title,GtkAdjustment * adj,GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
105 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
106 GtkWidget * SB;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
107 GtkWidget * label;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
108 label=gtk_label_new( title );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
109 gtk_misc_set_alignment( GTK_MISC( label ),0,0.5 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
110 gtk_box_pack_start( GTK_BOX( parent ),label,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
111 gtk_widget_show( label );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
112 SB=gtk_spin_button_new( adj,0,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
113 gtk_box_pack_start( GTK_BOX( parent ),SB,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
114 gtk_widget_show( SB );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
115 return SB;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
116 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
117
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
118 GtkWidget * gtkAddButton( const char * title,GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
119 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
120 GtkWidget * B;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
121 B=gtk_button_new_with_label( title );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
122 gtk_widget_show( B );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
123 gtk_container_add( GTK_CONTAINER( parent ),B );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
124 return B;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
125 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
126
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
127 GtkWidget * gtkAddHSeparator( GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
128 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
129 GtkWidget * hseparator;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
130 hseparator=gtk_hseparator_new();
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
131 gtk_widget_show( hseparator );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
132 gtk_box_pack_start( GTK_BOX( parent ),hseparator,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
133 gtk_widget_set_usize( hseparator,-2,6 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
134 return hseparator;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
135 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
136
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
137 GtkWidget * gtkAddHButtonBox( GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
138 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
139 GtkWidget * hbuttonbox;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
140 hbuttonbox=gtk_hbutton_box_new();
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
141 gtk_widget_show( hbuttonbox );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
142 gtk_box_pack_start( GTK_BOX( parent ),hbuttonbox,FALSE,FALSE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
143 gtk_button_box_set_child_size( GTK_BUTTON_BOX( hbuttonbox ),85,20 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
144 return hbuttonbox;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
145 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
146
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
147 GtkWidget * gtkAddHScale( GtkAdjustment * adj,GtkWidget * parent,int digit )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
148 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
149 GtkWidget * HS;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
150 HS=gtk_hscale_new( adj );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
151 gtk_widget_show( HS );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
152 if ( parent ) gtk_box_pack_start( GTK_BOX( parent ),HS,TRUE,TRUE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
153 gtk_scale_set_value_pos( GTK_SCALE( HS ),GTK_POS_RIGHT );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
154 gtk_scale_set_digits( GTK_SCALE( HS ),digit );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
155 return HS;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
156 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
157
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
158 GtkWidget * gtkAddVScale( GtkAdjustment * adj,GtkWidget * parent,int digit )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
159 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
160 GtkWidget * VS;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
161 VS=gtk_vscale_new( adj );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
162 gtk_widget_show( VS );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
163 if ( parent ) gtk_box_pack_start( GTK_BOX( parent ),VS,TRUE,TRUE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
164 // gtk_scale_set_value_pos( GTK_SCALE( VS ),GTK_POS_RIGHT );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
165 if ( digit == -1 ) gtk_scale_set_draw_value( GTK_SCALE( VS ),FALSE );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
166 else gtk_scale_set_digits( GTK_SCALE( VS ),digit );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
167 return VS;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
168 }
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
169
36023
a04e8798227b Cosmetic: Prefix all functions in dialog/tools.c with gtk.
ib
parents: 36009
diff changeset
170 GtkWidget * gtkAddCombo( GtkWidget * parent )
35526
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
171 {
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
172 GtkWidget * CB;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
173 CB=gtk_combo_new();
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
174 gtk_widget_show( CB );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
175 if ( parent ) gtk_box_pack_start( GTK_BOX( parent ),CB,TRUE,TRUE,0 );
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
176 return CB;
3c901704a27c Rebuild GUI directory structure.
ib
parents:
diff changeset
177 }
36024
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
178
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
179 int gtkFindInCList (GtkWidget *list, char *item)
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
180 {
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
181 gint j;
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
182 gchar *tmpstr;
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
183
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
184 for (j = 0; j < GTK_CLIST(list)->rows; j++)
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
185 {
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
186 gtk_clist_get_text(GTK_CLIST(list), j, 0, &tmpstr);
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
187
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
188 if (!strcmp(tmpstr, item)) return j;
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
189 }
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
190
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
191 return -1;
a9e5f317d6e4 Move gtkFindCList() to tools.c.
ib
parents: 36023
diff changeset
192 }