GtkFileChooserButton Combo

Welp, I finally finished the GtkFileChooserButton-as-combo-box work I’d been doing, mainly by going through GtkFileChooserDefault line-by-line to figure out how the hell it handled the folder dropdown in save mode. So, after coming to a minor epiphany about abstraction, particularly within the the MVC model (specifically, the “C” shouldn’t be any more abstract than it absolutely has to be, there’s plenty of abstraction to be had in the “M” and the “V”), thanks indirectly to Federico, I bring you this:

Feel the love, damnit. 😉

Advertisements

6 thoughts on “GtkFileChooserButton Combo

  1. I would put forth that the filesystem root is not a particularly useful folder to include in that list.

  2. That is a very nice hack you got there.

    (Dude, your software complains about email not been provided, but its
    lacking the star that says `fill me in’).

    Miguel.

  3. Excellent. I’d like something exactly like this for glom. I’m hoping that I can add the application’s examples directory to the list, just for the current application.

    And adding a “recent files” sub menu for the application would be really nice.

  4. Miguel: Fixed the missing required (*).

    Murray: It’s just a simple button in “OPEN” mode, so a “recent files” thing isn’t really feasible. App-specific shortcuts can be added with gtk_file_chooser_add_shortcut_folder(), but I totally missed support for those in the patch. So it looks like I’m not totally done with it yet… sigh ;-).

  5. This is cool!

    Now, I wait for the day when Epiphany will be able to embed this in web-pages for <input TYPE=”FILE”> instead of the ugly text-box and “Browse” button combo! If I got it correctly what it does, that is 🙂

Comments are closed.