Commit graph

18347 commits

Author SHA1 Message Date
Carlos Soriano 3946214747 remove leftovers of connect to server 2015-08-21 11:34:52 +02:00
Georges Basile Stavracas Neto 8d3c60e2bd files-view: don't show empty state for desktop
Nautilus shows a visual feedback for when the current folder is
empty. This, however, is undesired for the desktop, since we don't
want to clutter the desktop area.

Fix that by not displaying the empty state for desktop view only.

https://bugzilla.gnome.org/show_bug.cgi?id=753752
2015-08-20 23:43:52 -03:00
Georges Basile Stavracas Neto 474a6c2aa0 connect-server: remove legacy code
nautilus-connect-server is a legacy application from
GNOME 2 era, where we had no consistent way to manage
servers.

With the introduction of NautilusPlacesView, this code
becomes obsolete, as the network management logic is
moved to the places view.

Remove the legacy code.

https://bugzilla.gnome.org/show_bug.cgi?id=753871
2015-08-20 17:39:18 -03:00
Carlos Soriano 94fd7f94e3 window-slot: use g_error_matches
And add a comment to track this...

https://bugzilla.gnome.org/show_bug.cgi?id=753871
2015-08-20 17:39:05 -03:00
Georges Basile Stavracas Neto 404f1492db places-view: implement a view for Other Locations
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
2015-08-20 17:38:35 -03:00
Georges Basile Stavracas Neto abef8cac2f application: don't block UI if not necesary
we were asking for the file type blocking the UI. Use
nautilus file instead which catch the values.

https://bugzilla.gnome.org/show_bug.cgi?id=753871
2015-08-20 17:38:03 -03:00
Georges Basile Stavracas Neto 9806d70e8f view: add interface
Nautilus is in the proccess of receiving a places view,
based on GtkFileChooser's one.

To be able to handle that, an abstraction layer is needed
between NautilusFilesView and NautilusWindowSlot, so we factor
out the common data between views.

Add the NautilusView interface, and make NautilusFilesView a
NautilusView implementation. Because of the new way we handle
search on the view side, the search logic is rewritten to match
the new expected behavior.

https://bugzilla.gnome.org/show_bug.cgi?id=753871
2015-08-20 17:32:49 -03:00
Georges Basile Stavracas Neto acf2f76b00 canvas-view: change state of 'keep-aligned' action
The last action assigned was 'sort', and then we immediately
try to change the 'keep-aligned' state, causing a bunch of
criticals when using the Desktop Icons.

Fix that by correctly ordering the actions and avoiding set
the state of the wrong action.
2015-08-20 08:41:07 -03:00
Carlos Soriano 6594207b30 toolbar: dont update operations when no necesary
We were looping with a timeout to make sure we don't miss
any operation that it's time remaning was not well calculated.

But we were not stoping this loop when all the operations were
took into account. So remove the timeout if all the operations
are being show, cancelled, or finished.

https://bugzilla.gnome.org/show_bug.cgi?id=753728
2015-08-20 00:50:40 +02:00
Carlos Soriano 3cd90961cb toolbar: improve operations button first feedback
Users weren't noticing that the button appeared, and tried
to perform the same operation again.
Try to catch their attention on the button with an animation
on it when the button appears.

https://bugzilla.gnome.org/show_bug.cgi?id=753728
2015-08-20 00:50:40 +02:00
Carlos Soriano d8c6ef7efb toolbar: don't update style when not needed
We were updating the operations button style always that
update_operations was called. Thing is that is not necesary,
and can cause some anoyances in patchs that are to come.

https://bugzilla.gnome.org/show_bug.cgi?id=753728
2015-08-20 00:50:40 +02:00
Carlos Soriano 1a8fd4cf01 toolbar: reduce operations button timeout to show it
And instead increase the timeout to hide the button to allow
not flash but don't take too much in provide feedback that
and operation is being done

https://bugzilla.gnome.org/show_bug.cgi?id=753728
2015-08-20 00:50:40 +02:00
Carlos Soriano b8d76f9aae toolbar: improve operations button attention style
Instead of using blue, use a white higligth with the same colors
as the current button class of adwaita.

https://bugzilla.gnome.org/show_bug.cgi?id=753728
2015-08-20 00:50:40 +02:00
Dušan Kazik b6d6ad2015 Updated Slovak translation 2015-08-19 11:13:11 +00:00
Gábor Kelemen 0d7c7db8ae Updated Hungarian translation 2015-08-19 09:57:13 +00:00
Daniel Mustieles 3ba8ebff13 Updated Spanish translation 2015-08-18 13:57:09 +02:00
Piotr Drąg 0ffaf0c753 Updated POTFILES.in 2015-08-17 21:15:17 +02:00
Georges Basile Stavracas Neto a96615f8f8 files-view: rename from NautilusView
NautilusView is the proposed name for the new
interface that will cover NautilusFilesView and
NautilusPlacesView.

The current NautilusView name, however, will crash
with the proposed interface name.

Fix that by changing the class name to NautilusFilesView.
As an easter egg, makes it match the current Nautilus
code style.
2015-08-17 09:27:46 -03:00
Carlos Soriano 271f45a5d3 canvas-view: translate coordinates for compute_relative_for
We have to use the relative coordinates wrt the view, not the ones
of the item inside the scrolled widnow itself.
2015-08-17 00:18:49 +02:00
Carlos Soriano 4d8dd8def1 view: remove popover on finalize 2015-08-17 00:18:49 +02:00
Carlos Soriano 73c1cdd7f1 view: check for duplicated files for renaming as well
I removed that part of the code. Also, now that both behaviours
between renaming and new folder are closer, simplify the code
and merge the common parts.
2015-08-17 00:18:49 +02:00
Georges Basile Stavracas Neto 84faf7473b view: handle zoom X11 events
All X11 custom keys are currently handled by NautilusWindow,
which performs a search on it's own action group as well as
the view's one to perform the corresponding action.

Since we're isolating NautilusView from other classes, the
search on the view's action group is undesired.

Fix that by making the view handle zoom-in and zoom-out actions,
instead of the window itself.

https://bugzilla.gnome.org/show_bug.cgi?id=753695
2015-08-16 16:02:15 -03:00
Piotr Drąg b0bfc7ad76 Updated POTFILES.in 2015-08-16 20:23:48 +02:00
Carlos Soriano 105481ac27 toolbar: clarify why let the old icon in view menu 2015-08-16 19:37:14 +02:00
Georges Basile Stavracas Neto 764b98f6f4 view: handle view menu
NautilusToolbar handles the view menu, requiring
direct access to the underlying view inside the
window slot.

Since we're wiping out every access to the underlying
view, we shouldn't access it from NautilusToolbar.

To fix that, makes the view handle the view widget.
Since we're making NautilusWindowSlot a wrapper, add
the necessary properties for it to expose view data
without exposing the view itself.

https://bugzilla.gnome.org/show_bug.cgi?id=753673
2015-08-16 19:32:52 +02:00
Carlos Soriano 328348c6f7 nautilus-view: use popover for renaming
Some users felt it quite disruptive to us a dialog, even
if the attention has to be on the name entry.
Also it's the way that GtkFileChooser implemented it
and it actually feels less disruptive and desigerns agreed
it works better.
So continue to use a dialog for the new folder creation, but use
a popover for renaming.
2015-08-16 14:53:54 +02:00
Felipe Braga edaa65f4ee Updated Brazilian Portuguese translation 2015-08-12 17:22:18 +00:00
Georges Basile Stavracas Neto ae96063471 window-slot: show window when view starts loading
NautilusView directly access NautilusWindow to make sure
the window is shown when the view starts loading, and not
before this.

Since we're restricting communication between NautilusView
and other widgets, the view shouldn't ask the window directly.

Fixed by making NautilusWindowSlot handle the visibility of the
window on NautilusView::begin-loading signal. Also, this patch
gets rid of an old code that updates the title of supposedly
hidden slots that were present or created before showing the
window. which is something doesn't happen anyomore.

https://bugzilla.gnome.org/show_bug.cgi?id=753356
2015-08-07 13:44:09 -03:00
Kjartan Maraas d0b5a408ee Updated Norwegian bokmål translation. 2015-08-07 11:48:23 +02:00
Aurimas Černius d04416df72 Updated Lithuanian translation 2015-08-06 22:44:18 +03:00
Piotr Drąg 9577319b0f Updated POTFILES.in 2015-08-05 03:59:31 +02:00
Georges Basile Stavracas Neto 5edca92bc5 pathbar: handle context menu
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
2015-08-04 11:08:46 -03:00
Akom Chotiphantawanon e0245b62b4 Updated Thai translation 2015-08-04 10:54:29 +07:00
Jordi Mas c9bd09c919 Update Catalan translation 2015-08-03 21:59:02 +02:00
Yosef Or Boczko 622e53f057 Updated Hebrew translation 2015-08-02 00:17:14 +03:00
Kjartan Maraas 2c6fd4729f Updated Norwegian bokmål translation. 2015-08-01 11:10:27 +02:00
Georges Basile Stavracas Neto 0c0cd2e7a7 window: remove old hack
NautilusWindow immediately displays the newly opened
tab or window and, for that to happen correctly, an
old hack is present.

This hack, however, added some unecessary complexity to
NautilusWindow code, and is completely obsolete nowadays.
It was needed to fix bug 679640, but seems like the real
cause of the bug was fixed and this hack does nothing,
appearently.

Remove the old hack and lets see if will continue to behave
properly.
2015-07-31 13:38:18 -03:00
Georges Basile Stavracas Neto 9c4f013e99 project: simplify focus chain
Nautilus classes add custom methods to grab the focus
differently according to the class.

The problem with this approach, however, is that we end
up with more code coupling, since it's necessary to include
more headers to use the custom grab methods.

To fix that, make classes override GtkWidget::grab_focus
method and remove the custom methods, so widgets can simply
call gtk_widget_grab_focus.
2015-07-31 13:38:13 -03:00
Georges Basile Stavracas Neto ba2da7b800 view: change show-hidden setting only when value differs
Commit 2e1ac98 introduced the new behavior of persistently
storing the show-hidden setting whenever it changes.

This, however, caused an update cycle where NautilusDirectory
tracked the show-hidden change and invalidates the mime types
of the files, sending the apropriate ::file-changed signals.
When NautilusView receives the signals, it unconditionally
updates the action states, which sets the show-hidden action
again, causing another change on the setting and re-triggering
the NautilusDirectory signals, which are detected by NautilusView
and perpetuating the cycle.

Fix that by only storing the show-hidden setting when it
differs from the current one.
2015-07-31 13:38:10 -03:00
Georges Basile Stavracas Neto 1c6e0485bd view: manage the floating bar
NautilusWindowSlot currently manages the floating bar,
requiring access to the underlying model of NautilusView
and making the code even more coupled and adding more
complexity to the codebase.

Fix that by delegating the management of the floating
bar to NautilusView itself, and turn NautilusView a
GtkOverlay subclass in order to facilitate the transition.
2015-07-31 13:36:44 -03:00
Georges Basile Stavracas Neto 74b68bcb4d view: manage empty states
NautilusWindowSlot is the class responsible for managing
the empty views, causing even more code coupling and
blurring the lines of functionality of each class. Also,
it requires that the slot access the underlying model
behind NautilusView, something we're avoiding in order
to get Nautilus ready for future modifications.

Fix that by delegating to NautilusView the responsability
to manage the empty views, and not NautilusWindowSlot.
2015-07-31 13:36:40 -03:00
Alexandre Franke 9e13523478 Bump gtk_minver for GtkPlacesSidebar.populate-all 2015-07-30 15:38:01 +02:00
Dušan Kazik 71dc0256c3 Updated Slovak translation 2015-07-27 08:00:05 +00:00
Dimitris Spingos cd1b9b1f96 Updated Greek translation 2015-07-27 12:40:46 +03:00
Marek Černocký 0179882f59 Updated Czech translation 2015-07-25 13:33:57 +02:00
Pedro Albuquerque 9a23a80d8f Updated Portuguese translation 2015-07-25 08:26:53 +00:00
Dušan Kazik a703e1d0f2 Updated Slovak translation 2015-07-25 06:03:59 +00:00
Carlos Soriano bc51c3c598 window-slot: plug memory leak 2015-07-24 22:10:49 +02:00
Carlos Soriano 046df3892b window-slot: use allow_stop instead of busy
I put a new attribute, but allow_stop is actually meaning the
view is busy. So use that attribute and adjust its behaviour
a little to fix some corner cases.
2015-07-24 22:00:45 +02:00
Carlos Soriano e945cc6b0d window: use official name for cursor progress 2015-07-24 16:39:51 +02:00