summaryrefslogtreecommitdiffstats
path: root/src/nautilus-view-model.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 17:39:48 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 17:39:48 +0000
commit3ade071f273aaa973e44bf95d6b1d4913a18f03b (patch)
treee2f99d267ae18427645404f215b984afbe73098d /src/nautilus-view-model.h
parentInitial commit. (diff)
downloadnautilus-3ade071f273aaa973e44bf95d6b1d4913a18f03b.tar.xz
nautilus-3ade071f273aaa973e44bf95d6b1d4913a18f03b.zip
Adding upstream version 43.2.upstream/43.2upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--src/nautilus-view-model.h34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/nautilus-view-model.h b/src/nautilus-view-model.h
new file mode 100644
index 0000000..839c6d2
--- /dev/null
+++ b/src/nautilus-view-model.h
@@ -0,0 +1,34 @@
+#pragma once
+
+#include <glib.h>
+#include "nautilus-file.h"
+#include "nautilus-view-item.h"
+
+G_BEGIN_DECLS
+
+#define NAUTILUS_TYPE_VIEW_MODEL (nautilus_view_model_get_type())
+
+G_DECLARE_FINAL_TYPE (NautilusViewModel, nautilus_view_model, NAUTILUS, VIEW_MODEL, GObject)
+
+NautilusViewModel * nautilus_view_model_new (void);
+
+GtkSorter *nautilus_view_model_get_sorter (NautilusViewModel *self);
+void nautilus_view_model_set_sorter (NautilusViewModel *self,
+ GtkSorter *sorter);
+NautilusViewItem * nautilus_view_model_get_item_from_file (NautilusViewModel *self,
+ NautilusFile *file);
+GQueue * nautilus_view_model_get_items_from_files (NautilusViewModel *self,
+ GQueue *files);
+/* Don't use inside a loop, use nautilus_view_model_remove_all_items instead. */
+void nautilus_view_model_remove_item (NautilusViewModel *self,
+ NautilusViewItem *item);
+void nautilus_view_model_remove_all_items (NautilusViewModel *self);
+/* Don't use inside a loop, use nautilus_view_model_add_items instead. */
+void nautilus_view_model_add_item (NautilusViewModel *self,
+ NautilusViewItem *item);
+void nautilus_view_model_add_items (NautilusViewModel *self,
+ GQueue *items);
+guint nautilus_view_model_get_index (NautilusViewModel *self,
+ NautilusViewItem *item);
+
+G_END_DECLS