| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently we have this menu structure:
------------------------------
1. New Folder/New Tab/Bookmark
------------------------------
2. Zoom controls
------------------------------
3. Undo/Redo
------------------------------
4. Sort options
------------------------------
5. Other view related controls
------------------------------
The view creates 2-5, contained in a single GtkWidget - which is then
passed to the toolbar via the enclosing window slot. The problem is that
3 shouldn't be created or managed by the view as the controls in that
section of the menu are not related to the view. We'd like to move this
responsibility back to the toolbar, but that would mean the view must
pass multiple menu sections back to the toolbar (as 3 is in the middle
of the other view controls).
This change allows the view to pass multiple sections back to the
toolbar, using the new NautilusToolbarMenuSections structure. The files
view now passes 2 as a separate section to 3-5 (3 will be moved out of
the view in a future commit).
https://bugzilla.gnome.org/show_bug.cgi?id=764632
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We need to special case the other locations view when using that
location, since it's not a files-view and doesn't support several things
that we usually support, like the changes between icon view and list
view.
Also we specifically special case its creation in window slot and we
disable few actions that are not available on it.
This patch creates a other locations slot, which will handle all of it.
The class that is responsible of creating one type of slot or another is
the window, and will use a vfunc that will request whether the slot
handles a location or not and will act accordingly.
In upcoming patches we will move all the special casing of this and the
desktop in the window slot to its respective subclasses now that we have
everything ready.
https://bugzilla.gnome.org/show_bug.cgi?id=712620
|
|
|
|
|
|
|
|
|
|
| |
We would want in subclasses of nautilus window slot to have a way to
create custom views, like for instance, the desktop.
To allow it, make a vfunc for the creation of views that subclasses can
override.
https://bugzilla.gnome.org/show_bug.cgi?id=712620
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=712620
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
| |
Expose the search function on the whole stack.
We will need it for searches from the gnome-shell provider.
https://bugzilla.gnome.org/show_bug.cgi?id=762076
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is another step towards the isolation of the management
of the direcotories, views, slots and windows.
The current situation had a few issues:
- the comunication of changes in the model was done in a
bidirectional way. So for example, sometimes the view updates
directly the slot, sometimes directly the window, and sometimes
the window was listening to changes on the model and updating the slot,
view, or model itself. Problem with this is, encapsulation is wrong,
the code paths are confusing, and the public API exposed is big.
- public API is big, so even if sometimes if convenient to not do the
same thing twice, having public API that is actually covered by the GLib
or Gtk API doesn't worth it, if the complexity of the API grows too much.
In Nautilus case, specifically on the slot, we were allowing all kind of
convenient API, but it was behaving differently depending on small connotations.
- management was not encapsulated. So the window was modifyng the model, or
doing actions that belongs to the slot or the view. The same thing for the slot
and the view, and similarly for the application and the window. For example,
we were handling the flag for creating new windows on a specific window,
instead of relying on the application management. Similar cases for the slot
and the view.
- there were multiple code paths for opening a location. This is one of the
biggest changes on the patch. We were exposing API to open a location in every
component, and we were using that API from other components above or below the
hierarchy randomly. So for example the view was using the opening location
API from the slot, the window, and the application; but with the same pourpose,
opening a location in the active window.
- API was not explicit. For example sometimes we wanted to open
a location in the current active window, but somtimes it was implicit and
sometimes not, and to be safe we were making it explicit on the caller.
- we were using mutiple code paths with the same intention. This is related
to the previous one, the intention in every caller was not clear.
This patch tries to improve the situation, also thinking on the future
rework of the views and separation of the desktop handling.
The patch applies the following rules:
- If the API is provided somehow by nautilus-file or Glib or Gtk, don't
add new API. Custom API is fine if it is used inside the component itself,
since the added complexity for tracking code paths is not that important.
- Use one way communication, from the top level to the innermost component.
In case that the component needs top level features, ask the most top level.
A specific example, the view provides opening a new window with a selection.
Although encapsulation is good, there is not a good way to avoid the dance
from the model to the view to the slot to the window to the application.
So instead of that, allow a quick shorcut only communicating to the top most
level. In this way, the code path is always the same (therefore much easier to
debug or to change code) and encapsulation is preserved.
- don't break encapsulation. Only allow management of the component to the component
itself or its parent. So for example, the slot is the one that manages errors on what
happens in the slot itself.
Exception to this is the application, that needs access to all the hierarchy for
specific situations. For example for updating the dbus locations or to discern
between a desktop window or a common window.
- if two way communication is needed, listen changes through properties.
We have been moving to properties lately, since it clearer and cleaner and
allow a few features that are useful like listening to its changes withouth
explicit API for it. This allows to bind properties in a clean way throuh the
hierarchy and not breaking the encapsulation.
In this patch most of the ground work is done, and some things are remaining
like moving all the loading of the location to the view instead of the slot.
Even if it is convenient to have some management on the slot to share between
the views, some views don't use models at all, or they are not common
files, like the other-locations, and this breaks the situation. At some point
what we want for the files-view is having a common model API, that can be on top
of nautilus-file or in nautilus-file itself.
With this patch, a serie of improvements can be done now, and they will
come in future patches.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
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
|
|
|
|
|
|
|
|
|
|
|
| |
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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Nautilus opens the location notified by GtkPlacesSidebar
without further interaction with it.
With that, when a location fails to open, Nautilus goes
back to the previous valid location but, because of we're
not interacting with the sidebar after the failure, the
sidebar was not updated to match these changes, i.e. kept
the old invalid row selected.
To fix it, set the previous valid location to the sidebar
as well if there's some error loading a location.
https://bugzilla.gnome.org/show_bug.cgi?id=734755
|
|
|
|
|
|
|
|
|
| |
Refresh the nautilus menus in the view (context menus) and the menus in
the toolbar, changin as well in the path the UI of the toolbar to match
mockups.
In the way, port to GAction and GMenu every action and menu of nautilus
and some clean ups thanks to this port.
|
| |
|
|
|
|
|
|
| |
Fix a case where entering a directory from the search results would not
take the query editor down, and refactor some code around the state
synchronization between the two objects.
|
|
|
|
|
| |
Cleanup and rearrange typedefs to avoid the need for a separate types
header.
|
|
|
|
|
| |
Now that we got rid of nautilus-window-manage-views, move all the
private data in NautilusWindowSlot outside of the public struct.
|
|
|
|
|
|
|
|
| |
Move all the code related to loading a new slot from
nautilus-window-manage-views.c to nautilus-window-slot.c or
nautilus-window.c; then restructure loading to avoid having the view
call back into the window.
Instead, use the begin-loading and end-loading signals on the view.
|
|
|
|
|
|
|
| |
Move all the code relative to it in NautilusWindowSlot, and make the
relative object members private.
https://bugzilla.gnome.org/show_bug.cgi?id=684218
|
|
|
|
| |
Add api to preempt the current load and force a reload.
|
|
|
|
|
| |
Turn the window construct-only property into a construct property, and
add a setter method.
|
|
|
|
|
| |
This method was used to make the window panes active on focus click, but
it's not needed anymore.
|
|
|
|
|
|
| |
Go to home instead.
https://bugzilla.gnome.org/show_bug.cgi?id=666985
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This patch does three things:
- It adds API to the floating bar to have primary and details labels
instead of a single label. The primary label is ellipsized separately
from the details, so it makes a good fit for a filename.
- Modifies the code setting status messages in NautilusView to split
them into two separate strings
- Removes obsolete code in NautilusView and NautilusWindowSlot that was
setting long statuses for the old non-floating statusbar
https://bugzilla.gnome.org/show_bug.cgi?id=660695
|
|
|
|
|
|
|
| |
This avoids problems with using symbolic icons in the window titles
and with icons not updating.
https://bugzilla.gnome.org/show_bug.cgi?id=652212
|
| |
|
|
|
|
|
| |
Instead of relying on search engines returning the exact result set for
an empty query. This is also faster.
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=679900
|
|
|
|
|
|
|
|
| |
Save vertical space by integrating the search bar
with the query editor. This makes it less visually
disruptive when a search becomes active.
https://bugzilla.gnome.org/show_bug.cgi?id=679900
|
|
|
|
|
|
| |
This reverts commit 79e915b6fad372878d79a52f814017600ccb3884.
See https://bugzilla.gnome.org/show_bug.cgi?id=679640
|
|
|
|
|
| |
Use gtk_widget_get_visible() instead of an additional member for
NautilusWindowSlot, since it's a widget now.
|
| |
|
|
|
|
|
|
|
|
|
| |
Extra Pane mode was somewhat useful before GNOME 3 had side by side window mode.
The combination of panes and tabs is just too much. It is inconsistent
with the file chooser and doesn't work well with touch. We would like to
add a more explicit copy/move feature shortly.
https://bugzilla.gnome.org/show_bug.cgi?id=676858
|
|
|
|
|
| |
We don't want to have similar but slightly different code paths;
consolidate use of NautilusWindowOpenFlags everywhere and simplify code.
|
|
|
|
| |
Simplifies management of the slot quite a bit.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Don't pack them in a frame+eventbox, but just use the GtkBox.
|
|
|
|
| |
It will appear only if loading takes more than 500ms.
|
| |
|
| |
|
|
|
|
| |
The mode is now always decided by the GSettings preference.
|
|
|
|
|
| |
Don't roundtrip through NautilusWindowSlot, as that's what it would do
anyway.
|
|
|
|
| |
Why on earth should it be somewhere else?
|
|
|
|
|
| |
It's not that useful now that nautilus is not a long running application
anymore.
|
| |
|
|
|
|
|
| |
Use them in a consistent way, so to cleanup the previous
GFile/NautilusFile confusion.
|