File download

72 views
Skip to first unread message

Roman Minařík

unread,
Oct 16, 2014, 12:22:17 AM10/16/14
to cef...@googlegroups.com
Hi, its possible download file?

<a href="test.xls">Excel</a>

Thank for answer.

Czarek Tomczak

unread,
Oct 16, 2014, 2:31:02 AM10/16/14
to cef...@googlegroups.com
The fork by fromkeith has download handler implemented: https://github.com/fromkeith/cef2go

--
You received this message because you are subscribed to the Google Groups "CEF2go" group.
To unsubscribe from this group and stop receiving emails from it, send an email to cef2go+un...@googlegroups.com.
Visit this group at http://groups.google.com/group/cef2go.
For more options, visit https://groups.google.com/d/optout.

Roman Minařík

unread,
Oct 16, 2014, 4:14:45 AM10/16/14
to cef...@googlegroups.com
Thanks for answer. I was try merge your source and fromkeith source together, but I dont know how setup download handlet(?) for download files from browser.
After compile this merged source, download nor works :-(

Can you help me?

Dne čtvrtek, 16. října 2014 6:22:17 UTC+2 Roman Minařík napsal(a):

Czarek Tomczak

unread,
Oct 16, 2014, 4:35:42 AM10/16/14
to cef...@googlegroups.com
The structure in fromkeith repo was changed, I don't think merging will work. Also I don't see any working example in his repo, unfortunately. If you know a bit of C it shouldn't be much of a hassle to add downloads supports to original cef2go repo. To add a default download handler, there is no need to expose any API to Go. It's just a matter of calling callback->Continue(suggested_name, true); in CefDownloadHandler::OnBeforeDownload. Download handler needs to be implemented here: https://github.com/CzarekTomczak/cef2go/blob/master/handlers/cef_client.h#L48 and then the OnBeforeDownload callback. You can take a look at fromkeith repo for reference, but most of its code that exposes API can be ignored. Patches/pull requests are welcome.

--
Reply all
Reply to author
Forward
0 new messages