File Dialog --> gfilescanner



hmm after read the list about file dialog a came up with an idea.
Maybe this has been discussed before.

But why not move the filedialog tabcompletion/filescanning  code to glib?

Reason: 

* This could helpful in other applications for example run dialogs 
   or when you write your own fileselector (for example I am using a
fileselector in
   my gMiniCPPEnviroment.

* this could also be used as simple filesearcher.

very basic test API :

/* GFileScannerFunc callback */
/* return TRUE continue scanning */ 

typedef gboolean (* GFileScannerFunc)(gchar *filename)

typedef GFileScanner 
{
  gboolean (* GFileScannerFunc)(gchar *filename, gpointer data)
  GCompletion *compl;
} ;

/* init scanner and  setup a callback */
GFileScanner* g_file_scanner_new(GFileScannerFunc *scancb)
gboolean g_file_scanner_set(GFileScanner  *sc, gchar *filename)             /*
hmm give me a better name */

Needs to work on this.....

Greats

Mikael H.







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