On Fri, Jan 9, 2009 at 6:00 PM, <[email protected]> wrote:
> > Date: Thu, 08 Jan 2009 15:27:11 +0000 > From: Andrew Gatt <[email protected]> > Subject: Embedded browser upload > To: [email protected] > Message-ID: <[email protected]> > Content-Type: text/plain; charset=ISO-8859-1; format=flowed > > I'm trying to implement a file chooser for the upload dialog signal for > an embedded browser using the browser-eal. I've successfully attached > the signal, which fires correctly when the browse button is pressed, the > file chooser is created and filename_global is filled with the correct > filename, however this filename is not passed into the engine and the > browse entry field remains empty on the web page. Can anyone help shed > some light on this for me. > > Here's what i've got for the upload dialog signal callback. As the name > suggests filename_global is a simple global ghar*. > > gchar* g_web_widget_signal_upload_dialog(GObject *engine_widget, > const gchar *path, > const gchar *filter, > GObject *browser_window) > { > GtkWidget * dialog ; > filename_global = NULL; > dialog = hildon_file_chooser_dialog_new ( GTK_WINDOW > (browser_window), GTK_FILE_CHOOSER_ACTION_OPEN); > gtk_widget_show_all ( GTK_WIDGET ( dialog )); > if ( gtk_dialog_run ( GTK_DIALOG ( dialog )) == GTK_RESPONSE_OK ) { > filename_global = gtk_file_chooser_get_filename ( > GTK_FILE_CHOOSER (dialog)); > } > gtk_widget_destroy ( dialog ); > > return filename_global; try: return gnome_vfs_get_uri_from_local_path(filename_global); > > } > > If anyone can help i'd really appreciate it. > > Thanks > > Andrew > > > -- Best Regards, Zhihai Wang
_______________________________________________ maemo-developers mailing list [email protected] https://lists.maemo.org/mailman/listinfo/maemo-developers
