Commit graph

18529 commits

Author SHA1 Message Date
Inaki Larranaga Murgoitio
d922891e0c Updated Basque language 2015-10-14 14:07:19 +02:00
Inaki Larranaga Murgoitio
9b8c163d62 Updated Basque language 2015-10-14 14:05:25 +02:00
Carlos Soriano
bfd9ccf65c file: get filesystem type asynchronously
We were peeking the filesystem type synchronously since nautilus
was checking for some file infos that are only required once
synchronously. However the call for the filesystem is usually slow
which makes nautilus main thread hang.

To avoid I/O in the main thread, make the filesystem type request
asynchronously and part of all the others attributes for the file.

https://bugzilla.gnome.org/show_bug.cgi?id=756280
2015-10-14 12:19:55 +02:00
Carlos Soriano
55e1b80a39 file-operations: fix toolbar button not showing soon
We were not taking into account the time the operations
takes to prepare the operation itself. That makes big
operations take more time than needed for show the toolbar
operations button feedback than expected (2 seconds).
Fix that exposing a new timer that takes into account all
the time since the start of the operation and use that
for deciding when to show the file operations toolbar button
or not.

https://bugzilla.gnome.org/show_bug.cgi?id=756096
2015-10-13 18:01:34 +02:00
Carlos Soriano
45a5c5a40e file: default to not being able to trash
We were using as default that we can trash files, and after
we only set the if it is possible to trash or not if the filesystem
reports that has the info.
In most of schemes that the trash is not supported, the filesystem
actually don't have that info, making can_trash true and providing
the option on nautilus context menu, which does nothing.
Default to not being able to trash to avoid this situation.
2015-10-08 18:02:45 +02:00
Carlos Soriano
9395369c63 files-view: enable properties on all cases
We changed the meaning of remote from being only network://
to be a lot of schemes.
Thing is, the properties action was disabled for "remote", and
now that means lot of locations.
I think there is not enough reason to disable properties altogether,
if the network:// file doesn't provide enough info, probably it should.
2015-10-08 15:27:26 +02:00
Carlos Soriano
f329f501c9 toolbar: use finalize instead of dispose
We were disconnecting all the signals on dispose, except
the ones that comes from the widgets and are added with
gtk_widget_class_bind_template_callback. Therefore those
can be emitted after a dispose.

In the toolbar case, we connect to the toggle signal of a
button, which when the toolbar gets disposed, the buttons gets
untoggled and the signal is emitted, then the toolbar tries to
perform actions on external data that was cleared already on dispose.

To avoid that, just clear the data on finalize instead of
dispose.
2015-10-08 10:51:27 +02:00
Carlos Soriano
940d6d7b6d toolbar: fix progress leak 2015-10-08 01:28:47 +02:00
Carlos Soriano
733c22e20f toolbar: rename function 2015-10-08 01:28:30 +02:00
Carlos Soriano
745652a9f3 directory: protect against null filesystem type
The filesystem:type attribute could be NULL, then g_strv_contains
will crash if that happens.
Just don't call it if the attribute is not set.
2015-10-08 01:27:24 +02:00
Carlos Soriano
dee623a8dc directory: add more remote file system schemes 2015-10-08 01:27:04 +02:00
Carlos Soriano
5bf37b7769 files-view: order unrefing the model so state is clean up
In done_loading we check for floating bar and empty states.
In case the directory doesn't exists anymore in this case,
we cannot do that (without adding bunch of if's).
So instead reorder the unrefing so the directory is alive
when all the checks are performed.
This fixes seeing the floating bar when a directory fails to
load because the user doesn't have permissions.

https://bugzilla.gnome.org/show_bug.cgi?id=755207
2015-10-07 20:33:00 +02:00
Carlos Soriano
e2c5c42a20 directory-async: keep directory alive
Lately we did some changes on the view/slot/window/app
interaction with the directory/model ownership. That means
that now most of the times the directory/model is freed when
it should.
In this case, when loading the children of a directory reports
an error, say the user doesn't have permission to access the
directory, the view unref the directory in the signal callback,
and any further interaction with it by the directory itself after
signaling becomes accessing invalid memory.

To avoid this, the directory should have a ref on itself for any
signal that can cause the owners of it to unref.

https://bugzilla.gnome.org/show_bug.cgi?id=755207
2015-10-07 20:33:00 +02:00
Carlos Soriano
16b3460c4b settings: open folders on dnd by default
I have been going back and forward on this. And even if
I strongly think this is not good enough to be in the default
installation of Nautilus, removing 'features' or behaviors that
users were used to without providing a good alternative is even worse.
Probably Nautilus didn't have such high standards when this was
implemented, and this behavior was accepted even that emails from
usability and accessibility were asking to not do it, but it was done
given that no alternative was possible because of Apple patents on
'spring folders'.

So final decision from my side and after discussing it with some
people, is to continue shipping it by default until we have a better
solution.

The setting will be still there as 'open-folder-on-dnd-hover' and
can be modified by the user using dconf.

Discussions for better solution will be followed in
https://bugzilla.gnome.org/show_bug.cgi?id=754455
2015-10-07 14:03:21 +02:00
Carlos Soriano
749a864405 dnd: use GtkPlacesSidebar drop targets hints
Currently the dnd on the sidebar is only triggered when hovering
above the sidebar itself. However we would like to give some
feedback all along on the dnd operation.
For that GtkPlacesSidebar has set_drop_targets_visible public API,
which was implemented a few months ago and the GtkFileChooser is
already using.

I just forgot to implement the support for it on Nautilus... even if
the original work was done for Nautilus, since users will probably
use dnd more on nautilus than on the file chooser.

I'm not entirely happy with the implementation, since it uses custom
functions to access the drag data, given that we need them at drag-begin
time and in random places on the code, since nautilus is doing all the dnd
work manually and on different places.
The final result is that drag and drop is still managed mostly on its own
widgets, in this case list-view and canvas-view, and nautilus-dnd manages
a central accessor for dnd in nautilus, in this case requesting depending
on the widget that is the owner of the data, its data through the custom
functions of that particula widget. All other ways I tried to do it entirely
with only gtk_drag_* or gdk_drag_* functions were in vanish if no a complete
refactoring is done, and probably it doesn't worth the effort. Also I
actually separated the list view dnd code as well, so now at least the
pattern to handling dnd on nautilus is more or less consistent.
2015-10-06 23:36:30 +02:00
Carlos Soriano
02af0763c5 window: avoid crash when no dnd items
Sometimes is reported that there are not items as sources.
That makes nautilus crash trying to iterate betweeen them
in nautilus_drag_default_drop_action_for_icon.
Even if the fix should be there, it's a situation that
shouldn't happen at all, so I leave it as a responsability
of the caller.
2015-10-06 19:24:48 +02:00
Carlos Soriano
28409a235d list-view-dnd: fix deprecation 2015-10-06 19:22:09 +02:00
Carlos Soriano
ef14edf634 list-view: move dnd handling to a separate file
Following what canvas-dnd, slot-dnd and other widgets on nautilus
does.
Code will be much better for upcoming patches.
2015-10-06 19:22:09 +02:00
Carlos Soriano
f4f23383ac list-view-private: remove the file
It's not used
2015-10-06 19:22:09 +02:00
Carlos Soriano
4f2a59fee9 canvas-container: fix conflicting types 2015-10-06 19:18:01 +02:00
Carlos Soriano
b189ddf0d3 canvas-container: avoid creating layout if not grid
When relayouting we want to finish adding and layouting
the previous layout, but sometimes we can try to layout
when it's actually not possible to create a grid, for
instance if the size of the desktop is not enough or is
not yet allocated.
To prevent that, return early if we try to relayout in
that case and schedule a relayout.

https://bugzilla.gnome.org/show_bug.cgi?id=755582
2015-10-06 19:10:17 +02:00
Carlos Soriano
9ee7c173b5 toolbar: remove operations button timeout correctly
We were resetting the id to 0 without actually removing
it in the case a timeout was already there and we tried
to set a new one.

https://bugzilla.gnome.org/show_bug.cgi?id=755584
2015-10-06 18:53:34 +02:00
Carlos Soriano
5c9f68da01 file-operations: don't free ngettext strings
Pointed by Mathias.

https://bugzilla.gnome.org/show_bug.cgi?id=755586
2015-10-06 18:37:40 +02:00
Carlos Soriano
07719c951f Revert "nautilus-bookmark: don't crash if file is gone"
This reverts commit 9429c94f35.
This was a blind fix, and it's not correct. Correct one is only
need on 3.14 with commit a0cbf72827
2015-10-06 17:09:00 +02:00
Carlos Soriano
44de344af0 application-actions: use valid window list
We were using the internal list of the application to
iterate through the windows and closing them.
Problem is that when closing one window, the list is modified,
so next time accessing the list we are accessing the "old"
list, which is invalid and makes nautilus crash.

To fix it make a copy of the list to preserve the consistency.

https://bugzilla.gnome.org/show_bug.cgi?id=755803
2015-10-06 15:46:02 +02:00
Jiri Grönroos
f1dffe0991 Updated Finnish translation 2015-10-05 18:01:34 +00:00
GNOME Translation Robot
a5de9c39db Updated Scottish Gaelic translation 2015-10-01 11:59:56 +00:00
Milo Casagrande
aeee8413cb Updated Italian translation 2015-09-28 14:32:46 +00:00
Seán de Búrca
ba81e57091 Updated Irish translation 2015-09-27 14:48:11 -06:00
Stas Solovey
c623350b4f Updated Russian translation 2015-09-27 20:43:22 +00:00
Yosef Or Boczko
7bcec09bf0 Updated Hebrew translation 2015-09-27 11:40:32 +03:00
Trần Ngọc Quân
3db8f7ccf8 Updated Vietnamese translation
Signed-off-by: Trần Ngọc Quân <vnwildman@gmail.com>
2015-09-26 08:15:25 +07:00
Khaled Hosny
f4cbb7c192 Update Arabic translation 2015-09-23 23:20:54 +02:00
Ask Hjorth Larsen
5228e2635b Updated Danish translation 2015-09-23 16:57:15 +00:00
Carlos Soriano
8135123b33 release: prepare for 3.18.0 2015-09-23 00:06:38 +02:00
Carlos Soriano
07d53b0347 gtkplacesview: update to master 2015-09-22 23:35:00 +02:00
andreas.reis@gmail.com
f03ab5c8e1 list-view: use filename column width for rename popover position
It's still not ideal, since we would like to be on the middle of the
label. But is better than what we have... (and hopefully we will
have listbox for next release and this shouldn't be a problem)

https://bugzilla.gnome.org/show_bug.cgi?id=754620
2015-09-22 23:29:29 +02:00
Carlos Soriano
4b6c6adb23 files-view: fix remote warning label
Wrong autocompletion for showing_*, not sure how I slipped
that into master :(
2015-09-22 23:12:12 +02:00
Carlos Soriano
748eb9f8a5 files-view: be code consistent for loading a directory
We were using different ways for it, but we can actually use
the parent method most of the times.
2015-09-22 23:10:53 +02:00
Carlos Soriano
68a989006d query-editor: plug memory leak 2015-09-22 23:10:00 +02:00
Carlos Soriano
9dbe133f2a query-editor: use real location for search
Most of the times we were using as a location the invented
uri for the search directory as a model for the search, which
is wrong and the search was no returning results and the view
loading the cached files.

Before the window slot changes done a few weeks ago this was fine
because we didn't set more than once the location of the query editor
in a single search. So we were protected about this situation.

However now with the isolation of the model, the window slot is unaware
of the details of the model (if it is an invented uri or not) so can't
control that.

To fix it, make the query editor aware of the type of model used, and in
case of it being a search directory, use the base model as a location
for the search, and if not, use the file location uri.

https://bugzilla.gnome.org/show_bug.cgi?id=755336
2015-09-22 22:44:57 +02:00
Yuri Myasoedov
9ea79449c8 Updated Russian translation 2015-09-22 21:20:19 +03:00
Милош Поповић
5019eae913 Updated Serbian Latin translation 2015-09-21 18:53:03 +00:00
Милош Поповић
aa17826126 Updated Serbian translation 2015-09-21 18:51:37 +00:00
Enrico Nicoletto
7ba3c901c6 Updated Brazilian Portuguese translation 2015-09-21 01:36:15 +00:00
Ask Hjorth Larsen
6462f19118 Updated Danish translation 2015-09-20 17:30:57 +00:00
Anders Jonsson
7b57137734 Updated Swedish translation 2015-09-20 17:27:36 +00:00
Jiro Matsuzawa
864796e922 Updated Japanese translation 2015-09-21 01:55:45 +09:00
Kjartan Maraas
9dc7043d7f Updated Norwegian bokmål translation. 2015-09-20 12:38:15 +02:00
Andika Triwidada
f65b1b8e3c Updated Indonesian translation 2015-09-20 10:35:12 +00:00