summaryrefslogtreecommitdiff
path: root/src/nautilus-pathbar.c
Commit message (Collapse)AuthorAgeFilesLines
* general: remove vim modelinesCarlos Soriano2016-04-041-1/+0
| | | | | | | | | | | | | Vim and emacs modelines are used to specify some of the code style in the code. However, this is misleading and poorly supported since nautilus had a mix of code style for some time. Also, the mode lines doesn't specify the whole code style, so we will need to use a different tool as well to specify the whole code style. For that, we can just use a different tool for everything. So remove the mode lines, and in a short future we will reestyle the nautilus code to have a single code style, and use a tool like editorconfig to specify the whole code style.
* pathbar: use gint for widget sizeCarlos Soriano2016-03-211-1/+1
| | | | It was incorrectly using guint16.
* pathbar: avoid gtk+ warningsCarlos Soriano2016-03-211-0/+3
| | | | | | | | If we don't request the slider preferred size in allocation, gtk+ triggers a warning. The code of the path bar shouldn't do what is doing, and now gtk+ warns about it. In order to fix it, request the preferred size in size_allocate.
* pathbar: add slider-button class to slidersCarlos Soriano2016-03-211-0/+4
| | | | So they behave like the file chooser ones.
* pathbar: use pan symbolic iconCarlos Soriano2016-03-211-2/+2
|
* pathbar: remove hardcoded width for slidersCarlos Soriano2016-03-171-1/+3
|
* pathbar: use sane arrowsCarlos Soriano2016-03-171-5/+6
| | | | Just symbolic icons, not GtkArrows.
* pathbar: always show the slidersCarlos Soriano2016-03-141-3/+3
| | | | | | | | | The style cannot be done in a way that makes the path bar with a permanent visual glitch. Follow what the file chooser does and always show the sliders to prevent that, although we are reclutant to any solution, none of them are good. Let's make the new path bar for 3.22.
* pathbar: add image-button class to iconic buttonsCarlos Soriano2016-03-031-0/+4
| | | | Request from Lapo.
* remove gtk_button_set_focus_on_clickRazvan Chitu2016-02-261-2/+2
| | | | | | | The function is deprecated. Replace it with the parent function gtk_widget_set_focus_on_click. https://bugzilla.gnome.org/show_bug.cgi?id=762245
* pathbar: remove gtk_style_context_invalidateRazvan Chitu2016-02-261-32/+0
| | | | | | | | | | | | In Nautilus, a size allocation of the pathbar could cause style context invalidation for its children. Previously the invalidation had to be done manually. Since it is now done automatically, checking if it is needed and explicitly doing it are no longer necessary. Remove function responsible for invalidating style contexts. Remove the logic for checking if invalidation is needed. https://bugzilla.gnome.org/show_bug.cgi?id=762246
* pathbar: extra unref causing crashesCarlos Soriano2015-11-121-1/+0
| | | | | | | We unref in unschedule, so not need to do it here, which causes that we unref twice a file and therefore crashes randomly after some time if the user uses the rigth click menu of the pathbar
* resources: organize the resource files in a separate folderFelipe Borges2015-11-121-1/+1
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=757978
* places-view: implement a view for Other LocationsGeorges Basile Stavracas Neto2015-08-201-6/+17
| | | | | | | | | | | | | | | | | GtkFileChooser received a Other Locations view that lists persistent devices, as well as networks and the root location for the computer's hard drive. Since Nautilus is a file management tool too, it should keep consistency between Gtk+ file chooser, something that doesn't happen since it doesn't display Other Locations. To fix that, add NautilusPlacesView, a NautilusView implementation that displays the GtkPlacesView widget. In order to implement that, update window-slot to correctly display the places-view whenever Other Locations is clicked. https://bugzilla.gnome.org/show_bug.cgi?id=753871
* pathbar: handle context menuGeorges Basile Stavracas Neto2015-08-041-24/+224
| | | | | | | | | | | | | | | | | | | | | | NautilusView is an abstract class that manages various context menus, depending on the view's location, the clicked point and the implementation details. While this in theory provides a good isolation from other classes, in practice NautilusView manages the pathbar context menu, which is not necessary, as it doesn't depend on the current view anymore after the GAction rework. Fix that by making NautilusPathBar manage the context menu by itself instead of the view. To cleanly implement that, add a new signal that matches GtkPlacesSidebar::open-location signature, and adapt NautilusWindow to reuse the existing methods to handle pathbar's new signal. https://bugzilla.gnome.org/show_bug.cgi?id=753158
* pathbar: add clip hack to buttonsCosimo Cecchi2014-09-031-0/+32
| | | | | Not very pretty, but this is the best we can do right now with public API...
* Pathbar: Add a style classMatthias Clasen2014-07-171-0/+2
| | | | | Use the same style class that GTK+ adds to its pathbar now, so the two can share the theming.
* Do not modify ellipsize property within a size request functionDaniel Wyatt2014-02-171-7/+4
| | | | | | | Instead, we can use the natural size request which is equivalent to the non-ellipsized size. See: https://developer.gnome.org/gtk3/stable/GtkLabel.html#label-text-layout https://bugzilla.gnome.org/show_bug.cgi?id=697198
* Fix window dragging on the path barMatthias Clasen2014-02-151-1/+2
| | | | | | | | GtkWindow relies on button press, release and motion notify events being propagated. Therefore, we need to select for motion notify events to make window dragging work. https://bugzilla.gnome.org/show_bug.cgi?id=722542
* path bar: Request enough natural width to fit all buttonsYosef Or Boczko2014-02-151-1/+1
| | | | | | | Otherwise, we are at the mercy of the container giving us more space than we request, which does not always work. https://bugzilla.gnome.org/show_bug.cgi?id=722542
* Updated FSF's addressDaniel Mustieles2014-01-311-3/+1
|
* pathbar: add a return value from path-event signalCosimo Cecchi2013-08-241-4/+5
| | | | | | | | And make it so the return value is actually given in the callback, instead of depending on the window and the pathbar agree on what happened. https://bugzilla.gnome.org/show_bug.cgi?id=706605
* pathbar: do not unconditionally bubble up button-press-eventStefano Facchini2013-08-241-1/+1
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=706605
* Fix obvious cut&paste bugFederico Mena Quintero2013-05-031-1/+1
| | | | Signed-off-by: Federico Mena Quintero <federico@gnome.org>
* pathbar: use text-button style class for pathbar buttonsCosimo Cecchi2013-02-221-0/+2
| | | | | This will give it more horizontal spacing, like we do for text buttons in main toolbars.
* Normalize signal namesWilliam Jon McCann2013-01-221-4/+4
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=692234
* pathbar: don't assume a mounted mount is always availableCosimo Cecchi2012-10-191-2/+6
| | | | | | We might be refreshing while the mount disappears; in that case, the pathbar will try to get a symbolic icon from a NULL mount, hitting an assertion.
* pathbar: consistently use symbolic icons for root elements in pathbarCosimo Cecchi2012-10-101-53/+29
| | | | We were still using non-symbolic icons for mount roots.
* Fix file leakWilliam Jon McCann2012-09-111-1/+4
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=683769
* pathbar: clear buttons directly when file is goneCosimo Cecchi2012-08-311-4/+7
| | | | | | Instead of having the code in nautilus-window-manage-views clear the pathbar, since it receives the same signal, handle it internally. This should make code more robust.
* Don't try to close the window when a mount goes awayWilliam Jon McCann2012-08-311-42/+2
| | | | | | Go to home instead. https://bugzilla.gnome.org/show_bug.cgi?id=666985
* Rename icon view to canvas viewWilliam Jon McCann2012-08-071-1/+0
| | | | | | | This will allow us to retain canvas view for the desktop directory but implement a new icon view for other folders. https://bugzilla.gnome.org/show_bug.cgi?id=681370
* pathbar: additional fix for last commitCosimo Cecchi2012-08-011-0/+3
| | | | We were missing to add the up slider width in the LTR case.
* pathbar: fix allocation offset for the down slider buttonCosimo Cecchi2012-08-011-2/+2
| | | | | | | We want the down slider button to be linked visually to the rest of the pathbar. https://bugzilla.gnome.org/show_bug.cgi?id=680916
* pathbar: remove unused spacing private memberCosimo Cecchi2012-08-011-19/+16
| | | | | We use a linked style right now, so keeping this around just makes the code harder to read.
* pathbar: set single line mode for pathbar button labelsCosimo Cecchi2012-07-191-0/+2
| | | | | | We never want these buttons to have more than a single line of text. https://bugzilla.gnome.org/show_bug.cgi?id=680289
* pathbar: remove unused codeCosimo Cecchi2012-07-131-34/+0
| | | | | Since we don't show any icon for the trash in the pathbar, there's no need to listen to the changed signal on the trash monitor here.
* Use GIcons in pathbarWilliam Jon McCann2012-07-111-40/+11
| | | | This allow it to work with symbolic icons
* Fix some compiler warningsWilliam Jon McCann2012-07-031-2/+0
|
* pathbar: fix set_label_size_request() for no-label buttonsCosimo Cecchi2012-07-021-0/+4
| | | | | It's convenient to just call this in a loop on the button data, so just return if there's no label to set the size request for.
* pathbar: implement get_path_for_child()Cosimo Cecchi2012-06-301-3/+117
| | | | Implementation taken from GtkPathBar
* Use a more GNOME 3 toolbar layoutWilliam Jon McCann2012-06-301-1/+4
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=676531
* pathbar: fix unwanted ellipsizing in buttons with certain themesCosimo Cecchi2012-06-251-62/+55
| | | | | | | | | | | | | | | | | Themes can nowadays set padding on GtkLabel widgets (e.g. Ambiance and Radiance do this for labels in primary toolbar buttons). This breaks our hack to force a size request for the pathbar labels, since we measure the PangoLayout directly instead of measuring the GtkLabel it's part of (which includes the border/padding values from the theme). Fix this by measuring the size requisition of GtkLabel directly; for this to work effectively, we need to pack an (invisible) additional label in the button GtkBox, always set the text to both labels and update the requisition of the non-bold one to MIN(MAX_POSSIBLE_WIDTH, MAX (width, bold_width)) every time a size-request cycle is called. https://bugzilla.gnome.org/show_bug.cgi?id=678341
* pathbar: set a maximum label width for pathbar buttonsCosimo Cecchi2012-06-041-5/+18
| | | | | | | | | | | | | | | | | | Set a maximum allowed width of 250px for pathbar button requisitions, and ellipsize after that. This fixes buttons disappearing completely from the pathbar in case there was not enough space to show the complete folder name, I am not sure I completely like this approach in all the situations, since there might be some value in showing more of a very long folder name if there's space available on screen, but unfortunately, it's not really possible without restructuring completely the way NautilusPathBar allocates children. Adapted for master, and slightly modified from an initial patch by Ted M Lin <tedmlin@gmail.com> https://bugzilla.gnome.org/show_bug.cgi?id=313854
* pathbar: simplify codeCosimo Cecchi2012-06-041-18/+9
|
* all: fix GCC pointer signedness warningsCosimo Cecchi2012-05-311-1/+1
| | | | New cycle, new set of warnings triggered by glibc/GCC.
* pathbar: remove unused codeCosimo Cecchi2012-04-291-34/+0
| | | | | The path-set signal has no listeners connected anymore, so it can be safely removed.
* pathbar: add a path-event signalCosimo Cecchi2012-04-291-0/+53
| | | | This will be useful to remove some hairy code from NautilusWindowPane
* pathbar: remove fake root attributesCosimo Cecchi2012-04-291-215/+132
| | | | | | | | | | | We currently allow going up from Home towards the filesystem root with a little back arrow; in the code this is implemented by keeping track of an additional fake root. Since we want to change the pathbar not to show the back arrow anymore in such cases, remove this code (and refactor other pieces of code around it). https://bugzilla.gnome.org/show_bug.cgi?id=619616
* pathbar: simplify codeCosimo Cecchi2012-04-271-11/+2
|