[nautilus/wip/antoniof/flow-box-preparation: 66/68] general: Remove canvas view




commit 2d1deaac2dd12b0ba16446bfbf3498b266e60338
Author: António Fernandes <antoniof gnome org>
Date:   Sun Dec 12 17:59:39 2021 +0000

    general: Remove canvas view
    
    The new grid view has reached feature parity with the canvas, if we
    ignore drag-and-drop and clipboard support (which would need to be
    reimplemented in GTK 4 anyway) and performance scalability (which is
    a problem of GtkFlowBox and solvable by using GtkGridView in GTK 4).
    
    The canvas view relies on extensive custom implementation for layout,
    drawing, input handling, accessibility, etc., which would be too
    hard to port to in GT1K4.
    
    Furthermore, most of its features, such as support for manual sorting,
    haven't been used since the "icons on desktop" feature has been taken
    out from this app. We are actually using a swiss army knife for a job
    where we only need a single blade -- a simple pocketknife would do!
    
    Therefore, we say goodbye to this seasoned veteran widget, who has
    served us for 2 whole decades.

 eel/eel-canvas.c                     | 4153 ----------------------
 eel/eel-canvas.h                     |  497 ---
 eel/meson.build                      |    2 -
 po/POTFILES.in                       |    6 -
 src/meson.build                      |   13 -
 src/nautilus-canvas-container.c      | 6360 ----------------------------------
 src/nautilus-canvas-container.h      |  295 --
 src/nautilus-canvas-dnd.c            | 1833 ----------
 src/nautilus-canvas-dnd.h            |   56 -
 src/nautilus-canvas-item.c           | 2760 ---------------
 src/nautilus-canvas-item.h           |   90 -
 src/nautilus-canvas-private.h        |  223 --
 src/nautilus-canvas-view-container.c |  377 --
 src/nautilus-canvas-view-container.h |   35 -
 src/nautilus-canvas-view.c           | 1646 ---------
 src/nautilus-canvas-view.h           |   45 -
 src/nautilus-debug.c                 |    1 -
 src/nautilus-debug.h                 |   25 +-
 src/nautilus-dnd.c                   |    1 -
 src/nautilus-files-view.c            |    1 -
 src/nautilus-selection-canvas-item.c |  554 ---
 src/nautilus-selection-canvas-item.h |   62 -
 src/resources/css/Adwaita.css        |   12 -
 23 files changed, 12 insertions(+), 19035 deletions(-)
---
diff --git a/eel/meson.build b/eel/meson.build
index e5fa7465d..8f88a9bad 100644
--- a/eel/meson.build
+++ b/eel/meson.build
@@ -1,8 +1,6 @@
 libeel_2_sources = [
   'eel-art-extensions.h',
   'eel-art-extensions.c',
-  'eel-canvas.h',
-  'eel-canvas.c',
   'eel-debug.h',
   'eel-debug.c',
   'eel-glib-extensions.h',
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 825b8769b..b0d229b14 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -4,7 +4,6 @@ data/nautilus-autorun-software.desktop.in
 data/org.gnome.Nautilus.appdata.xml.in.in
 data/org.gnome.Nautilus.desktop.in.in
 data/org.gnome.nautilus.gschema.xml
-eel/eel-canvas.c
 eel/eel-gtk-extensions.c
 eel/eel-stock-dialogs.c
 eel/eel-vfs-extensions.c
@@ -23,11 +22,6 @@ src/nautilus-autorun-software.c
 src/nautilus-batch-rename-dialog.c
 src/nautilus-batch-rename-dialog.h
 src/nautilus-bookmark.c
-src/nautilus-canvas-container.c
-src/nautilus-canvas-dnd.c
-src/nautilus-canvas-item.c
-src/nautilus-canvas-view.c
-src/nautilus-canvas-view-container.c
 src/nautilus-clipboard.c
 src/nautilus-column-chooser.c
 src/nautilus-column-utilities.c
diff --git a/src/meson.build b/src/meson.build
index dac467d54..20865fff4 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -72,10 +72,6 @@ libnautilus_sources = [
   'nautilus-application.h',
   'nautilus-bookmark-list.c',
   'nautilus-bookmark-list.h',
-  'nautilus-canvas-view.c',
-  'nautilus-canvas-view.h',
-  'nautilus-canvas-view-container.c',
-  'nautilus-canvas-view-container.h',
   'nautilus-dbus-manager.c',
   'nautilus-dbus-manager.h',
   'nautilus-error-reporting.c',
@@ -147,13 +143,6 @@ libnautilus_sources = [
   'nautilus-x-content-bar.h',
   'nautilus-bookmark.c',
   'nautilus-bookmark.h',
-  'nautilus-canvas-container.c',
-  'nautilus-canvas-container.h',
-  'nautilus-canvas-dnd.c',
-  'nautilus-canvas-dnd.h',
-  'nautilus-canvas-item.c',
-  'nautilus-canvas-item.h',
-  'nautilus-canvas-private.h',
   'nautilus-clipboard.c',
   'nautilus-clipboard.h',
   'nautilus-column-chooser.c',
@@ -234,8 +223,6 @@ libnautilus_sources = [
   'nautilus-search-engine-simple.h',
   'nautilus-search-hit.c',
   'nautilus-search-hit.h',
-  'nautilus-selection-canvas-item.c',
-  'nautilus-selection-canvas-item.h',
   'nautilus-signaller.h',
   'nautilus-signaller.c',
   'nautilus-query.c',
diff --git a/src/nautilus-debug.c b/src/nautilus-debug.c
index d189a6f9a..bbf76567c 100644
--- a/src/nautilus-debug.c
+++ b/src/nautilus-debug.c
@@ -41,7 +41,6 @@ static GDebugKey keys[] =
     { "DBus", NAUTILUS_DEBUG_DBUS },
     { "DirectoryView", NAUTILUS_DEBUG_DIRECTORY_VIEW },
     { "File", NAUTILUS_DEBUG_FILE },
-    { "CanvasContainer", NAUTILUS_DEBUG_CANVAS_CONTAINER },
     { "IconView", NAUTILUS_DEBUG_GRID_VIEW },
     { "ListView", NAUTILUS_DEBUG_LIST_VIEW },
     { "Mime", NAUTILUS_DEBUG_MIME },
diff --git a/src/nautilus-debug.h b/src/nautilus-debug.h
index c277f37a5..9322a8d62 100644
--- a/src/nautilus-debug.h
+++ b/src/nautilus-debug.h
@@ -35,19 +35,18 @@ typedef enum {
   NAUTILUS_DEBUG_DBUS = 1 << 4,
   NAUTILUS_DEBUG_DIRECTORY_VIEW = 1 << 5,
   NAUTILUS_DEBUG_FILE = 1 << 6,
-  NAUTILUS_DEBUG_CANVAS_CONTAINER = 1 << 7,
-  NAUTILUS_DEBUG_GRID_VIEW = 1 << 8,
-  NAUTILUS_DEBUG_LIST_VIEW = 1 << 9,
-  NAUTILUS_DEBUG_MIME = 1 << 10,
-  NAUTILUS_DEBUG_PLACES = 1 << 11,
-  NAUTILUS_DEBUG_PREVIEWER = 1 << 12,
-  NAUTILUS_DEBUG_SMCLIENT = 1 << 13,
-  NAUTILUS_DEBUG_WINDOW = 1 << 14,
-  NAUTILUS_DEBUG_UNDO = 1 << 15,
-  NAUTILUS_DEBUG_SEARCH = 1 << 16,
-  NAUTILUS_DEBUG_SEARCH_HIT = 1 << 17,
-  NAUTILUS_DEBUG_THUMBNAILS = 1 << 18,
-  NAUTILUS_DEBUG_TAG_MANAGER = 1 << 19,
+  NAUTILUS_DEBUG_GRID_VIEW = 1 << 7,
+  NAUTILUS_DEBUG_LIST_VIEW = 1 << 8,
+  NAUTILUS_DEBUG_MIME = 1 << 9,
+  NAUTILUS_DEBUG_PLACES = 1 << 10,
+  NAUTILUS_DEBUG_PREVIEWER = 1 << 11,
+  NAUTILUS_DEBUG_SMCLIENT = 1 << 12,
+  NAUTILUS_DEBUG_WINDOW = 1 << 13,
+  NAUTILUS_DEBUG_UNDO = 1 << 14,
+  NAUTILUS_DEBUG_SEARCH = 1 << 15,
+  NAUTILUS_DEBUG_SEARCH_HIT = 1 << 16,
+  NAUTILUS_DEBUG_THUMBNAILS = 1 << 17,
+  NAUTILUS_DEBUG_TAG_MANAGER = 1 << 18,
 } DebugFlags;
 
 void nautilus_debug_set_flags (DebugFlags flags);
diff --git a/src/nautilus-dnd.c b/src/nautilus-dnd.c
index 067bc27ec..7b7a1ba2b 100644
--- a/src/nautilus-dnd.c
+++ b/src/nautilus-dnd.c
@@ -32,7 +32,6 @@
 #include <gtk/gtk.h>
 #include <glib/gi18n.h>
 #include "nautilus-file-utilities.h"
-#include "nautilus-canvas-dnd.h"
 #include <src/nautilus-list-view-dnd.h>
 #include <stdio.h>
 #include <string.h>
diff --git a/src/nautilus-files-view.c b/src/nautilus-files-view.c
index 6167b1686..d90b961cc 100644
--- a/src/nautilus-files-view.c
+++ b/src/nautilus-files-view.c
@@ -51,7 +51,6 @@
 #include "nautilus-application.h"
 #include "nautilus-batch-rename-dialog.h"
 #include "nautilus-batch-rename-utilities.h"
-#include "nautilus-canvas-view.h"
 #include "nautilus-clipboard.h"
 #include "nautilus-compress-dialog-controller.h"
 #include "nautilus-directory.h"
diff --git a/src/resources/css/Adwaita.css b/src/resources/css/Adwaita.css
index 968794388..0e2f302f0 100644
--- a/src/resources/css/Adwaita.css
+++ b/src/resources/css/Adwaita.css
@@ -8,18 +8,6 @@
     opacity: 0.50;
 }
 
-.nautilus-canvas-item {
-    border-radius: 5px;
-}
-
-.nautilus-canvas-item.dim-label {
-    color: mix (@theme_fg_color, @theme_bg_color, 0.50);
-}
-
-.nautilus-canvas-item.dim-label:selected {
-    color: mix (@theme_selected_fg_color, @theme_selected_bg_color, 0.20);
-}
-
 /* Toolbar */
 
 /* Here we use the .button background-image colors from Adwaita, but ligthen them,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]