Generic file select



What is the 'proper' way to use a gtk fileselection dialog?

For example i have a menu callback which needs allow the user to select a file 
name, then loads it.  For preference I would like to be able to write:

mystring = getavalidfilename("My File Dialog Title");
if(mystring 1= NULL)
{
        loadfile(mystring);
}
else
{
        handle_error();
}

The problem I have is the example in the gtk docs returns immediately and the 
filename is set some time later in in an external variable.

Ian




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]