[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Can you "localize" a dialog?
- From: John Ringland <ringland emerald math buffalo edu>
- To: gtk-app-devel-list redhat com
- Subject: Can you "localize" a dialog?
- Date: Tue, 10 Aug 1999 11:22:42 -0400
I'm new to GTK+ and I'm struggling with how to "localize"
a dialog.
I'd like to write a (C++) DialogBox class that has a constructor
(or other member-function) which
pops up a dialog box window, and
DOESN'T RETURN UNTIL a button in that window has been clicked?
Is this style possible in GTK+? (Or do I have to write separate
callback functions for each response in the dialog?)
class DialogBox
{ public:
DialogBox( const char* text,
const char* choice1, const char* choice2,
int& returnvalue);
};
void some_callback(GtkWidget *widget, gpointer* data)
{
int repsonse;
DialogBox("Do you really mean that?", "Yes", "No", response);
if(response==1) { // do the yes thing }
else if(response==2) { // do the no thing }
}
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]