GNOME Bugzilla – Bug 440859
enable file chooser previews for epiphany
Last modified: 2007-12-17 14:02:57 UTC
Hello, I came from bug #372344. I would really like Epiphany to enable the GTK filechooser's preview (at least for images). I'm not sure if it could be of use for Save, but it would be vital for "open" or "browse" choosers. Here is a use case: Bob wants to send a picture by attaching it to a message in Gmail/Hotmail/etc, or he wants to upload that picture to picasa/flickr manually. Or he wants to post cats on 4chan because it's caturday desu. The problem is, all his files are named 3029239423.jpg, PICT0012.JPG, PICT0013.JPG, etc. And he has thousands of them. He would have to browse the folder containing the files using Nautilus, memorize their location and file name, and then select them with epiphany's file chooser. Not intuitive. What do you think? I'm no programmer, but I would guess that the gtk file chooser would only need an extra argument to enable that preview like in GIMP? Having this feature would allow me to remain sane for a couple of months more (until I manage to convince the gtk guys that an icon view is not evil :) and it would make epiphany a LOT more integrated into the GNOME desktop. Looking at http://pygtk.org/pygtk2reference/class-gtkfilechooser.html (yeah I know, that's the python gtk bindings and Epiphany is not in python), I would *guess* that the relevant function(s) could be set_preview_widget(preview_widget) set_preview_widget_active(active) Let me know what you think!
Thanks for the bug report. This particular bug has already been reported into our bug tracking system, but please feel free to report any further bugs you find. *** This bug has been marked as a duplicate of 144337 ***
Oops, that's about HTML. Reopening.
Note that it's possible to drag and drop a random object from Nautilus to the GTK file chooser and it will show the correct path. But I agree this could be a useful feature.
I suspect this is a mozilla thing, I couldn't find the dialog on ephy's source (well there's a dialog but it's for File>Open). And it also looks like the FF one so I would say it's mozilla's fault. Am I right (hope not)?
Created attachment 96267 [details] [review] Implements file previews This creates previews for images in the file chooser, I don't think there are other filetypes worth previewing.
(In reply to comment #5) > This creates previews for images in the file chooser, I don't think there are > other filetypes worth previewing. Well, since it's a web browser, HTML documents could use previews too. Let's tackle that later though, it's going to be a tad more complicated :) + gchar *filename; Just char, not gchar. + pixbuf = gdk_pixbuf_new_from_file_at_size (filename, 100, 100, NULL); Is 100 a good size? it seems a bit small... Also let's #define this number at least. Otherwise this patch looks fine, thanks!
------------------------------------------------------------------------ r7502 | diegoe | 2007-09-27 23:59:47 -0500 (Thu, 27 Sep 2007) | 6 lines * lib/ephy-file-chooser.c: Add a preview for the FileChooser. The default size is 150x150. Fixes bug #440859. Do you think we should add the HTML previewing? I don't know if it has enough use cases.
(In reply to comment #7) > Do you think we should add the HTML previewing? I don't know if it has enough > use cases. Let's wait and see if someone requests it with a good reason :)
If we're going to show previews we might as well re-use the nautilus thumbnailer to fetch previews for anything anyone might want to upload to a website.
*** Bug 503903 has been marked as a duplicate of this bug. ***