Commit Graph

105 Commits

Author SHA1 Message Date
Matthias Clasen
ff87c6516b file chooser: Allow to limit search
Add a button to allow restricting search to the current
folder (and subdirectories). This makes the search more
useful, and makes the file chooser more similar to
nautilus.
2015-02-14 01:03:38 -05:00
Matthias Clasen
2c5ea0dd45 file chooser: Add a location column for search
In search, we show files from differnt locations, and it makes
sense to show where they come from. This makes the file chooser
more similar to nautilus, too.
2015-02-14 01:03:38 -05:00
Matthias Clasen
61012f3efe file chooser: Don't open folders unexpectedly
Folders that show up among search results were unexpectedly
returned even for GTK_FILE_CHOOSER_ACTION_OPEN. Change things
around so that we switch to the folder instead, which is the
behavior we had in GTK+ 2.x.

https://bugzilla.gnome.org/show_bug.cgi?id=744204
2015-02-14 01:03:38 -05:00
Matthias Clasen
b876e036b2 file chooser: Allow opening folders in the file manager
This has been suggested in
https://bugzilla.gnome.org/show_bug.cgi?id=325150#c2
2015-02-11 23:34:04 -05:00
Matthias Clasen
99b17488dd file chooser: Unset sidebar during search
It is a bit misleading to have one of the places in the sidebar
selected while in search mode, since the search is not relative
to any location. So, unset the sidebar selection when we enter
search mode.
2015-01-28 18:26:42 -05:00
Matthias Clasen
e31e88582f file chooser: Unify search mode leaving
Make all ways to get out of search mode go through the same
code path, so we always populate the list.
2015-01-28 18:21:18 -05:00
Matthias Clasen
a385ca1bb7 file chooser: Fix key bindings
Key press handlers must chain up for key bindings to work.
2015-01-28 18:17:51 -05:00
Matthias Clasen
59c04d5184 file chooser: Load a directory when leaving search
Ensure that some folder contents are shown in
the list when we leave search mode.

https://bugzilla.gnome.org/show_bug.cgi?id=743659
2015-01-28 18:15:19 -05:00
Matthias Clasen
696129d83c file chooser: Don't switch too eagerly to search mode
If the search entry doesn't consume the key event, don't
change to search mode. Otherwise, we interfere e.g. with
Ctrl and Shift keys for selection.

https://bugzilla.gnome.org/show_bug.cgi?id=743660
2015-01-28 17:01:30 -05:00
Matthias Clasen
86eefc7609 file chooser: Make Escape go out of search mode
This works in most other places where we have search,
and is the expected behavior.
2015-01-28 16:07:51 -05:00
Matthias Clasen
1d64175c4b file chooser: Simplify search entry callback 2015-01-28 16:07:51 -05:00
Matthias Clasen
d270c5524f file chooser: Drop unused callbacks 2015-01-28 16:07:51 -05:00
Matthias Clasen
de4427304c file chooser: Add a search-mode property
This will be used to control search from the dialog.
2015-01-28 16:07:51 -05:00
Matthias Clasen
76b674f3b6 file chooser: Clean up includes 2015-01-28 16:07:51 -05:00
Christoph Reiter
8fc920144b GtkFileChooserWidget: Fix a crash for when the widget was unrefed right after setting a current folder.
Keep a reference to the widget while the async operation is ongoing.

https://bugzilla.gnome.org/show_bug.cgi?id=725164
2015-01-24 17:28:28 -05:00
Christoph Reiter
c235747847 GtkFileChooserWidget: remove unused fields and cleanup code.
These fields are never set, so we don't need the code to clean them up.

https://bugzilla.gnome.org/show_bug.cgi?id=725164
2015-01-24 17:28:28 -05:00
Matthias Clasen
b3c28e14fe file chooser: search improvements
Make it so that typing switches to search unless we have a better
use for the key events, and stop search if the entry is emptied.
2015-01-24 13:32:31 -05:00
Matthias Clasen
82e324f8ac file chooser: Fix up some focus issues
Better to switch the visible stack child early, since GtkStack
has its own focus handling now.
2015-01-18 19:45:13 -05:00
Matthias Clasen
1a38c4d066 file chooser: Make search work again
The last round of filechooser redesign work had left
search somewhat dysfunctional. This commit fixes things
up enough that search is once again a working feature
of the file chooser.
2015-01-18 18:59:43 -05:00
Matthias Clasen
dcd3d15380 file chooser: Drop the location label
Bringing us close to the new design.
2015-01-18 17:57:12 -05:00
Matthias Clasen
4b47c5a649 file chooser: Don't show 'Enter Location' in save modes
In these modes, the entry is permanently visible anyway.
2015-01-18 17:39:05 -05:00
Matthias Clasen
a8cb7352c5 file chooser: Make Ctrl-L work in recent
Just switch to browse mode when we see Ctrl-L in recent mode.
https://bugzilla.gnome.org/show_bug.cgi?id=660450
2015-01-18 17:35:22 -05:00
Matthias Clasen
8133e7e624 file chooser: Ensure the path bar is initialized
There are some cases where we can end up showing the path
bar without ever setting a file on it. One example is:
1) Open file chooser
2) Hit ~
3) Hit Ctrl-L
While this is a bit of a workaround, at least it makes sure
that we never end up with an empty space where the path bar
is supposed to be.
2015-01-18 17:13:12 -05:00
Matthias Clasen
6a7b549608 trivial refactoring 2015-01-18 16:57:21 -05:00
Matthias Clasen
dfe6399de8 file chooser: Make ~ and / work in recent
Complained about in
https://bugzilla.gnome.org/show_bug.cgi?id=743117
2015-01-18 16:18:12 -05:00
Iain Lane
8c5094c22c gtkfilechooserwidget: When using an extra widget, show or hide the filter combo as appropriate
https://bugzilla.gnome.org/show_bug.cgi?id=742653
2015-01-10 20:37:39 -05:00
Matthias Clasen
2aa3eea781 GtkFileChooser: Add a menuitem for 'sort directories first'
This has been requested repeatedly.
2014-11-03 00:02:13 -05:00
Matthias Clasen
f678e48a08 GtkFileChooser: Make preview update more understandable
Implement Federico's suggestion:
In single-selection mode, just use the selected row,
In multi-selection mode, use the cursor row as long as it is
in the selection.

https://bugzilla.gnome.org/show_bug.cgi?id=154709
2014-10-19 17:54:28 -04:00
Matthias Clasen
faa1909474 GtkFileChooserWidget: Better typography
No double space after .

https://bugzilla.gnome.org/show_bug.cgi?id=735192
2014-09-29 23:05:22 -04:00
Matthias Clasen
683a7f1429 GtkFileChooserWidget: Use ratio in formatted times
This matches what we do in other places now.
2014-08-22 02:04:31 -04:00
Matthias Clasen
31e4ec4632 GtkFileChooserWidget: Remove an errant line
This was leaking a schema object, and looks like a bad merge.
2014-06-28 21:38:47 -04:00
Jasper St. Pierre
9c37b3de74 gtk: Don't use GObjectClass.constructor
Use the newer constructed instead, which has a fast path in GObject.
2014-06-26 19:06:43 -04:00
Matthias Clasen
872fbfacd3 Split GtkWindowGroup into its own file
gtkwindow.c is too big and too messy. This is a small step
towards making it better.
2014-06-04 06:24:05 -04:00
Matthias Clasen
0011c9dae4 Fix filechooser actionbar visibility
The actionbar was always visible, even when there is no filter
and no extra widget to show. Now we only show it when there is
something to show.
2014-05-24 00:00:00 -04:00
Matthias Clasen
fd65b68927 docs: Trivial typo fix 2014-05-19 22:47:59 -04:00
William Jon McCann
384b227e7b file-chooser: make enter location an operation mode
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:35:02 -04:00
William Jon McCann
20dfe1dd7f file-chooser: merge path bar mode and location mode
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:35:01 -04:00
William Jon McCann
d8ca588e17 file-chooser: remove select a folder info message
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:35:01 -04:00
William Jon McCann
d46ed4ec00 file-chooser: don't use an special label for recent
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:35:00 -04:00
William Jon McCann
a644b34154 file-chooser: add a search bar instead of using a path bar mode
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:35:00 -04:00
William Jon McCann
b05b91c692 file-chooser: style save mode name box as a search bar
So we get a bottom border etc.

https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:34:59 -04:00
William Jon McCann
22e3552a9d file-chooser: don't show a "save folder:" label
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:34:58 -04:00
William Jon McCann
5c42068bb3 file-chooser: move location entry into same place as pathbar
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:34:58 -04:00
William Jon McCann
df9522d8a8 file-chooser: allow views to extend to the sides of the dialog
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:34:56 -04:00
William Jon McCann
256a3a51da file-chooser: move pathbar into preview pane
https://bugzilla.gnome.org/show_bug.cgi?id=722211
2014-04-22 22:34:56 -04:00
Bastien Nocera
f71f7215ab all: Name more idles and timeouts
Following up from 438cd857c4,
name more timeouts and idles.

The original grep was missing checking for gdk_threads_add_*()
functions (at least for some of the files).

https://bugzilla.gnome.org/show_bug.cgi?id=726870
2014-03-26 20:09:30 -04:00
Matthias Clasen
c99935a540 file chooser: Don't react to entry changes in select-folder mode
In select-folder mode, we are putting the directory name into the
entry ourselves. Then the entry appends a /. If we react to this
'spontaneous' change of the entry by clearing the list selection,
this will in turn make us clear the entry. We don't want that.

https://bugzilla.gnome.org/show_bug.cgi?id=726855
2014-03-21 22:08:50 -04:00
William Jon McCann
77fced56fc file-chooser: emit selection-changed when location entry changes too
https://bugzilla.gnome.org/show_bug.cgi?id=547988
2014-03-03 06:10:03 -05:00
William Jon McCann
e709c965a4 Don't leak the queried file info
https://bugzilla.gnome.org/show_bug.cgi?id=554618
2014-02-21 14:51:25 -05:00
Matthias Clasen
2a8446bdec Add docs 2014-02-19 19:39:06 -05:00