[gnome-todo] project: Reorganize files
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-todo] project: Reorganize files
- Date: Tue, 11 Dec 2018 22:49:24 +0000 (UTC)
commit 8f1c9736764a6ccaa20e098f320928f52e2d14e5
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Tue Dec 11 20:41:12 2018 -0200
project: Reorganize files
* Move .ui files to src/ and match their respective .c filenames
* Reorganize plugins a bit
data/icons/icons.gresource.xml | 11 +++
data/todo.gresource.xml | 94 ----------------------
meson.build | 12 +++
plugins/meson.build | 5 ++
plugins/plugins.gresource.xml | 57 +++++++++++++
po/POTFILES.in | 30 +++----
src/gtd-initial-setup-window.c | 2 +-
.../gtd-initial-setup-window.ui | 0
src/gtd-plugin-dialog-row.c | 2 +-
.../plugin-row.ui => src/gtd-plugin-dialog-row.ui | 0
src/gtd-plugin-dialog.c | 2 +-
.../plugin-dialog.ui => src/gtd-plugin-dialog.ui | 0
src/gtd-task-list-panel.c | 2 +-
.../gtd-task-list-panel.ui | 0
src/gtd-window.c | 2 +-
data/ui/window.ui => src/gtd-window.ui | 0
src/meson.build | 48 ++++++++---
src/notification/gtd-notification-widget.c | 2 +-
.../notification/gtd-notification-widget.ui | 0
src/provider/gtd-provider-popover.c | 2 +-
.../provider/gtd-provider-popover.ui | 0
src/provider/gtd-provider-row.c | 2 +-
.../provider/gtd-provider-row.ui | 0
src/provider/gtd-provider-selector.c | 2 +-
.../provider/gtd-provider-selector.ui | 0
src/sidebar/gtd-sidebar-list-row.c | 2 +-
.../sidebar/gtd-sidebar-list-row.ui | 0
src/sidebar/gtd-sidebar-panel-row.c | 2 +-
.../sidebar/gtd-sidebar-panel-row.ui | 0
src/sidebar/gtd-sidebar-provider-row.c | 2 +-
.../sidebar/gtd-sidebar-provider-row.ui | 0
src/sidebar/gtd-sidebar.c | 2 +-
data/ui/sidebar.ui => src/sidebar/gtd-sidebar.ui | 0
src/task-list-view/gtd-dnd-row.c | 2 +-
.../task-list-view/gtd-dnd-row.ui | 0
src/task-list-view/gtd-edit-pane.c | 2 +-
.../task-list-view/gtd-edit-pane.ui | 0
src/task-list-view/gtd-new-task-row.c | 2 +-
.../task-list-view/gtd-new-task-row.ui | 0
src/task-list-view/gtd-task-list-popover.c | 2 +-
.../task-list-view/gtd-task-list-popover.ui | 0
src/task-list-view/gtd-task-list-view.c | 2 +-
.../task-list-view/gtd-task-list-view.ui | 0
src/task-list-view/gtd-task-row.c | 2 +-
.../task-list-view/gtd-task-row.ui | 0
{data => src}/theme/Adwaita.css | 0
src/todo.gresource.xml | 29 +++++++
src/{ => widgets}/gtd-empty-list-widget.c | 2 +-
src/{ => widgets}/gtd-empty-list-widget.h | 0
.../widgets/gtd-empty-list-widget.ui | 0
50 files changed, 187 insertions(+), 139 deletions(-)
---
diff --git a/data/icons/icons.gresource.xml b/data/icons/icons.gresource.xml
new file mode 100644
index 0000000..fa89008
--- /dev/null
+++ b/data/icons/icons.gresource.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<gresources>
+ <!-- Icons -->
+ <gresource prefix="/org/gnome/todo/icons">
+ <file preprocess="xml-stripblanks"
alias="scalable/actions/drag-handle-symbolic.svg">hicolor/symbolic/actions/drag-handle-symbolic.svg</file>
+ <file preprocess="xml-stripblanks"
alias="scalable/actions/view-tasks-all-symbolic.svg">hicolor/symbolic/actions/view-tasks-all-symbolic.svg</file>
+ <file preprocess="xml-stripblanks"
alias="scalable/actions/view-tasks-today-symbolic.svg">hicolor/symbolic/actions/view-tasks-today-symbolic.svg</file>
+ <file preprocess="xml-stripblanks"
alias="scalable/actions/view-tasks-unscheduled-symbolic.svg">hicolor/symbolic/actions/view-tasks-unscheduled-symbolic.svg</file>
+ <file preprocess="xml-stripblanks"
alias="scalable/actions/view-tasks-week-symbolic.svg">hicolor/symbolic/actions/view-tasks-week-symbolic.svg</file>
+ </gresource>
+</gresources>
diff --git a/meson.build b/meson.build
index fc7ec14..0e73d02 100644
--- a/meson.build
+++ b/meson.build
@@ -130,6 +130,11 @@ endif
add_project_arguments(common_flags + compiler_flags, language: 'c')
+
+#######################
+# Shared dependencies #
+#######################
+
glib_dep = dependency('glib-2.0', version: '>= 2.58.0')
gtk_dep = dependency('gtk+-4.0', version: '>= 3.92.0')
@@ -143,6 +148,11 @@ gnome_todo_deps = [
cc.find_library('m', required: true)
]
+
+#######
+# VCS #
+#######
+
vcs_identifier_h = vcs_tag(
input: configure_file(
output: 'config.h.in',
@@ -172,7 +182,9 @@ src_inc = include_directories(
)
data_dir = join_paths(meson.source_root(), 'data')
+icons_dir = join_paths(data_dir, 'icons')
po_dir = join_paths(meson.source_root(), 'po')
+plugins_dir = join_paths(meson.source_root(), 'plugins')
subdir('build-aux')
subdir('plugins')
diff --git a/plugins/meson.build b/plugins/meson.build
index c40f7c9..ac912a1 100644
--- a/plugins/meson.build
+++ b/plugins/meson.build
@@ -31,3 +31,8 @@ endif
if get_option('todoist_plugin')
subdir('todoist')
endif
+
+plugins_dep = declare_dependency(
+ link_with: plugins_libs,
+ link_args: plugins_ldflags,
+)
diff --git a/plugins/plugins.gresource.xml b/plugins/plugins.gresource.xml
new file mode 100644
index 0000000..e937fe4
--- /dev/null
+++ b/plugins/plugins.gresource.xml
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<gresources>
+ <!--All Tasks -->
+ <gresource prefix="/org/gnome/todo">
+ <file
alias="plugins/all-tasks-panel/all-tasks-panel.plugin">all-tasks-panel/all-tasks-panel.plugin</file>
+ </gresource>
+
+ <!--Background-->
+ <gresource prefix="/org/gnome/todo">
+ <file alias="plugins/background/background.plugin">background/background.plugin</file>
+ <file compressed="true" alias="ui/background/preferences.ui">background/ui/preferences.ui</file>
+ </gresource>
+
+ <!--Dark theme-->
+ <gresource prefix="/org/gnome/todo">
+ <file alias="plugins/dark-theme/dark-theme.plugin">dark-theme/dark-theme.plugin</file>
+ </gresource>
+
+ <!--EDS Plugin-->
+ <gresource prefix="/org/gnome/todo">
+ <file alias="plugins/eds/eds.plugin">eds/eds.plugin</file>
+ </gresource>
+
+ <!--Next Week panel-->
+ <gresource prefix="/org/gnome/todo">
+ <file
alias="plugins/next-week-panel/scheduled-panel.plugin">next-week-panel/next-week-panel.plugin</file>
+ <file compressed="true"
alias="theme/next-week-panel/Adwaita.css">next-week-panel/theme/Adwaita.css</file>
+ </gresource>
+
+ <!--Night Light-->
+ <gresource prefix="/org/gnome/todo">
+ <file alias="plugins/night-light/night-light.plugin">night-light/night-light.plugin</file>
+ </gresource>
+
+ <!--Scheduled panel-->
+ <gresource prefix="/org/gnome/todo">
+ <file
alias="plugins/scheduled-panel/scheduled-panel.plugin">scheduled-panel/scheduled-panel.plugin</file>
+ <file compressed="true"
alias="theme/scheduled-panel/Adwaita.css">scheduled-panel/theme/Adwaita.css</file>
+ </gresource>
+
+ <!--Today panel-->
+ <gresource prefix="/org/gnome/todo">
+ <file alias="plugins/today-panel/today-panel.plugin">today-panel/today-panel.plugin</file>
+ <file compressed="true" alias="theme/today-panel/Adwaita.css">today-panel/theme/Adwaita.css</file>
+ </gresource>
+
+ <!--Todo.Txt-->
+ <gresource prefix="/org/gnome/todo">
+ <file alias="plugins/todo-txt/todo-txt.plugin">todo-txt/todo-txt.plugin</file>
+ </gresource>
+
+ <!--Todoist-->
+ <gresource prefix="/org/gnome/todo">
+ <file alias="plugins/todoist/todoist.plugin">todoist/todoist.plugin</file>
+ <file compressed="true" alias="ui/todoist/preferences.ui">todoist/ui/preferences.ui</file>
+ </gresource>
+</gresources>
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 1ffbd7c..879f512 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -2,20 +2,6 @@
data/appdata/org.gnome.Todo.appdata.xml.in
data/org.gnome.Todo.desktop.in
data/org.gnome.todo.gschema.xml
-data/ui/edit-pane.ui
-data/ui/empty-list.ui
-data/ui/initial-setup.ui
-data/ui/list-view.ui
-data/ui/new-task-row.ui
-data/ui/plugin-dialog.ui
-data/ui/provider-popover.ui
-data/ui/provider-row.ui
-data/ui/provider-selector.ui
-data/ui/sidebar-list-row.ui
-data/ui/sidebar-provider-row.ui
-data/ui/task-list-panel.ui
-data/ui/task-row.ui
-data/ui/window.ui
plugins/all-tasks-panel/gtd-all-tasks-panel.c
plugins/background/gtd-plugin-background.c
plugins/background/org.gnome.todo.background.gschema.xml
@@ -37,12 +23,26 @@ plugins/todo-txt/gtd-todo-txt-parser.c
plugins/todo-txt/org.gnome.todo.txt.gschema.xml
plugins/unscheduled-panel/unscheduled-panel/__init__.py
src/gtd-application.c
-src/gtd-empty-list-widget.c
+src/gtd-initial-setup-window.ui
+src/gtd-plugin-dialog.ui
src/gtd-plugin-dialog-row.c
+src/gtd-task-list-panel.ui
src/gtd-window.c
+src/gtd-window.ui
src/main.c
+src/provider/gtd-provider-popover.ui
+src/provider/gtd-provider-row.ui
+src/provider/gtd-provider-selector.ui
src/sidebar/gtd-sidebar-list-row.c
+src/sidebar/gtd-sidebar-list-row.ui
+src/sidebar/gtd-sidebar-provider-row.ui
src/task-list-view/gtd-edit-pane.c
+src/task-list-view/gtd-edit-pane.ui
src/task-list-view/gtd-new-task-row.c
+src/task-list-view/gtd-new-task-row.ui
src/task-list-view/gtd-task-list-view.c
+src/task-list-view/gtd-task-list-view.ui
src/task-list-view/gtd-task-row.c
+src/task-list-view/gtd-task-row.ui
+src/widgets/gtd-empty-list-widget.c
+src/widgets/gtd-empty-list-widget.ui
diff --git a/src/gtd-initial-setup-window.c b/src/gtd-initial-setup-window.c
index 3f7d4de..672ca19 100644
--- a/src/gtd-initial-setup-window.c
+++ b/src/gtd-initial-setup-window.c
@@ -217,7 +217,7 @@ gtd_initial_setup_window_class_init (GtdInitialSetupWindowClass *klass)
GTD_TYPE_MANAGER,
G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/initial-setup.ui");
+ gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/gtd-initial-setup.ui");
gtk_widget_class_bind_template_child_private (widget_class, GtdInitialSetupWindow, cancel_button);
gtk_widget_class_bind_template_child_private (widget_class, GtdInitialSetupWindow, done_button);
diff --git a/data/ui/initial-setup.ui b/src/gtd-initial-setup-window.ui
similarity index 100%
rename from data/ui/initial-setup.ui
rename to src/gtd-initial-setup-window.ui
diff --git a/src/gtd-plugin-dialog-row.c b/src/gtd-plugin-dialog-row.c
index ecd082a..480acbb 100644
--- a/src/gtd-plugin-dialog-row.c
+++ b/src/gtd-plugin-dialog-row.c
@@ -222,7 +222,7 @@ gtd_plugin_dialog_row_class_init (GtdPluginDialogRowClass *klass)
PEAS_TYPE_PLUGIN_INFO,
GTD_TYPE_ACTIVATABLE);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/plugin-row.ui");
+ gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/gtd-plugin-dialog-row.ui");
gtk_widget_class_bind_template_child (widget_class, GtdPluginDialogRow, description_label);
gtk_widget_class_bind_template_child (widget_class, GtdPluginDialogRow, error_image);
diff --git a/data/ui/plugin-row.ui b/src/gtd-plugin-dialog-row.ui
similarity index 100%
rename from data/ui/plugin-row.ui
rename to src/gtd-plugin-dialog-row.ui
diff --git a/src/gtd-plugin-dialog.c b/src/gtd-plugin-dialog.c
index d38320a..b28924c 100644
--- a/src/gtd-plugin-dialog.c
+++ b/src/gtd-plugin-dialog.c
@@ -186,7 +186,7 @@ gtd_plugin_dialog_class_init (GtdPluginDialogClass *klass)
{
GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/plugin-dialog.ui");
+ gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/gtd-plugin-dialog.ui");
gtk_widget_class_bind_template_child (widget_class, GtdPluginDialog, back_button);
gtk_widget_class_bind_template_child (widget_class, GtdPluginDialog, extension_list_placeholder);
diff --git a/data/ui/plugin-dialog.ui b/src/gtd-plugin-dialog.ui
similarity index 100%
rename from data/ui/plugin-dialog.ui
rename to src/gtd-plugin-dialog.ui
diff --git a/src/gtd-task-list-panel.c b/src/gtd-task-list-panel.c
index 208e8bc..47ba0b4 100644
--- a/src/gtd-task-list-panel.c
+++ b/src/gtd-task-list-panel.c
@@ -326,7 +326,7 @@ gtd_task_list_panel_class_init (GtdTaskListPanelClass *klass)
g_object_class_override_property (object_class, PROP_SUBTITLE, "subtitle");
g_object_class_override_property (object_class, PROP_TITLE, "title");
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/task-list-panel.ui");
+ gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/gtd-task-list-panel.ui");
gtk_widget_class_bind_template_child (widget_class, GtdTaskListPanel, colors_flowbox);
gtk_widget_class_bind_template_child (widget_class, GtdTaskListPanel, popover);
diff --git a/data/ui/task-list-panel.ui b/src/gtd-task-list-panel.ui
similarity index 100%
rename from data/ui/task-list-panel.ui
rename to src/gtd-task-list-panel.ui
diff --git a/src/gtd-window.c b/src/gtd-window.c
index 1815da9..f8c2688 100644
--- a/src/gtd-window.c
+++ b/src/gtd-window.c
@@ -587,7 +587,7 @@ gtd_window_class_init (GtdWindowClass *klass)
g_type_ensure (GTD_TYPE_NOTIFICATION_WIDGET);
g_type_ensure (GTD_TYPE_SIDEBAR);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/window.ui");
+ gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/gtd-window.ui");
gtk_widget_class_bind_template_child (widget_class, GtdWindow, cancel_selection_button);
gtk_widget_class_bind_template_child (widget_class, GtdWindow, gear_menu_button);
diff --git a/data/ui/window.ui b/src/gtd-window.ui
similarity index 100%
rename from data/ui/window.ui
rename to src/gtd-window.ui
diff --git a/src/meson.build b/src/meson.build
index 206fba5..5168b43 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -1,4 +1,13 @@
+################
+# Dependencies #
+################
+
+gtd_deps = gnome_todo_deps + [
+ plugins_dep,
+]
+
+
################
# Header files #
################
@@ -59,10 +68,10 @@ sources = files(
'task-list-view/gtd-task-list-view.c',
'task-list-view/gtd-task-row.c',
'widgets/gtd-color-button.c',
+ 'widgets/gtd-empty-list-widget.c',
'widgets/gtd-expandable-entry.c',
'widgets/gtd-row-header.c',
'gtd-application.c',
- 'gtd-empty-list-widget.c',
'gtd-initial-setup-window.c',
'gtd-object.c',
'gtd-plugin-dialog.c',
@@ -77,13 +86,33 @@ sources = files(
'main.c'
)
+
+#############
+# Resources #
+#############
+
sources += gnome.compile_resources(
'gtd-resources',
- join_paths(data_dir, 'todo.gresource.xml'),
- source_dir: [ data_dir, join_paths(meson.build_root(), 'plugins') ],
- c_name: 'todo',
+ 'todo.gresource.xml',
+ c_name: 'todo',
+ export: true,
+)
+
+sources += gnome.compile_resources(
+ 'gtd-plugin-resources',
+ join_paths(plugins_dir, 'plugins.gresource.xml'),
+ source_dir: [ plugins_dir, join_paths(meson.build_root(), 'plugins') ],
+ c_name: 'todo_plugins',
dependencies: plugins_confs,
- export: true
+ export: true,
+)
+
+sources += gnome.compile_resources(
+ 'gtd-icon-resources',
+ join_paths(icons_dir, 'icons.gresource.xml'),
+ source_dir: [ icons_dir ],
+ c_name: 'todo_icons',
+ export: true,
)
enum = 'gtd-enum-types'
@@ -117,7 +146,7 @@ cflags = [
'-DUI_DATA_DIR="@0@"'.format(join_paths(gnome_todo_pkgdatadir, 'style'))
]
-ldflags = [ '-Wl,--export-dynamic' ] + plugins_ldflags
+ldflags = [ '-Wl,--export-dynamic' ]
#########
@@ -146,9 +175,8 @@ gnome_todo = executable(
meson.project_name(),
sources,
include_directories: incs,
- dependencies: gnome_todo_deps,
+ dependencies: gtd_deps,
c_args: cflags,
- link_with: plugins_libs,
link_args: ldflags,
install: true,
install_dir: gnome_todo_bindir
@@ -165,14 +193,14 @@ libgtd = shared_library(
version: libversion,
soversion: soversion,
include_directories: incs,
- dependencies: gnome_todo_deps,
+ dependencies: gtd_deps,
c_args: cflags
)
libgtd_dep = declare_dependency(
link_with: libgtd,
include_directories: src_inc,
- dependencies: gnome_todo_deps
+ dependencies: gtd_deps
)
diff --git a/src/notification/gtd-notification-widget.c b/src/notification/gtd-notification-widget.c
index d687300..b78efa3 100644
--- a/src/notification/gtd-notification-widget.c
+++ b/src/notification/gtd-notification-widget.c
@@ -203,7 +203,7 @@ gtd_notification_widget_class_init (GtdNotificationWidgetClass *klass)
object_class->finalize = gtd_notification_widget_finalize;
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/notification.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/notification/gtd-notification-widget.ui");
gtk_widget_class_bind_template_child (widget_class, GtdNotificationWidget, secondary_button);
gtk_widget_class_bind_template_child (widget_class, GtdNotificationWidget, spinner);
diff --git a/data/ui/notification.ui b/src/notification/gtd-notification-widget.ui
similarity index 100%
rename from data/ui/notification.ui
rename to src/notification/gtd-notification-widget.ui
diff --git a/src/provider/gtd-provider-popover.c b/src/provider/gtd-provider-popover.c
index 963199e..55a7621 100644
--- a/src/provider/gtd-provider-popover.c
+++ b/src/provider/gtd-provider-popover.c
@@ -190,7 +190,7 @@ gtd_provider_popover_class_init (GtdProviderPopoverClass *klass)
g_type_ensure (GTD_TYPE_PROVIDER_SELECTOR);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/provider-popover.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/provider/gtd-provider-popover.ui");
gtk_widget_class_bind_template_child (widget_class, GtdProviderPopover, change_location_button);
gtk_widget_class_bind_template_child (widget_class, GtdProviderPopover, location_provider_image);
diff --git a/data/ui/provider-popover.ui b/src/provider/gtd-provider-popover.ui
similarity index 100%
rename from data/ui/provider-popover.ui
rename to src/provider/gtd-provider-popover.ui
diff --git a/src/provider/gtd-provider-row.c b/src/provider/gtd-provider-row.c
index 82107b0..d9a0107 100644
--- a/src/provider/gtd-provider-row.c
+++ b/src/provider/gtd-provider-row.c
@@ -153,7 +153,7 @@ gtd_provider_row_class_init (GtdProviderRowClass *klass)
G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/provider-row.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/provider/gtd-provider-row.ui");
gtk_widget_class_bind_template_child_private (widget_class, GtdProviderRow, icon);
gtk_widget_class_bind_template_child_private (widget_class, GtdProviderRow, name);
diff --git a/data/ui/provider-row.ui b/src/provider/gtd-provider-row.ui
similarity index 100%
rename from data/ui/provider-row.ui
rename to src/provider/gtd-provider-row.ui
diff --git a/src/provider/gtd-provider-selector.c b/src/provider/gtd-provider-selector.c
index be6169c..0ed0099 100644
--- a/src/provider/gtd-provider-selector.c
+++ b/src/provider/gtd-provider-selector.c
@@ -491,7 +491,7 @@ gtd_provider_selector_class_init (GtdProviderSelectorClass *klass)
FALSE,
G_PARAM_READWRITE));
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/provider-selector.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/provider/gtd-provider-selector.ui");
gtk_widget_class_bind_template_child (widget_class, GtdProviderSelector, exchange_stub_row);
gtk_widget_class_bind_template_child (widget_class, GtdProviderSelector, google_stub_row);
diff --git a/data/ui/provider-selector.ui b/src/provider/gtd-provider-selector.ui
similarity index 100%
rename from data/ui/provider-selector.ui
rename to src/provider/gtd-provider-selector.ui
diff --git a/src/sidebar/gtd-sidebar-list-row.c b/src/sidebar/gtd-sidebar-list-row.c
index 4ddfd62..3d51619 100644
--- a/src/sidebar/gtd-sidebar-list-row.c
+++ b/src/sidebar/gtd-sidebar-list-row.c
@@ -442,7 +442,7 @@ gtd_sidebar_list_row_class_init (GtdSidebarListRowClass *klass)
g_object_class_install_properties (object_class, N_PROPS, properties);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/sidebar-list-row.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/sidebar/gtd-sidebar-list-row.ui");
gtk_widget_class_bind_template_child (widget_class, GtdSidebarListRow, color_icon);
gtk_widget_class_bind_template_child (widget_class, GtdSidebarListRow, menu);
diff --git a/data/ui/sidebar-list-row.ui b/src/sidebar/gtd-sidebar-list-row.ui
similarity index 100%
rename from data/ui/sidebar-list-row.ui
rename to src/sidebar/gtd-sidebar-list-row.ui
diff --git a/src/sidebar/gtd-sidebar-panel-row.c b/src/sidebar/gtd-sidebar-panel-row.c
index 2b28dc6..63861c1 100644
--- a/src/sidebar/gtd-sidebar-panel-row.c
+++ b/src/sidebar/gtd-sidebar-panel-row.c
@@ -150,7 +150,7 @@ gtd_sidebar_panel_row_class_init (GtdSidebarPanelRowClass *klass)
g_object_class_install_properties (object_class, N_PROPS, properties);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/sidebar-panel-row.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/sidebar/gtd-sidebar-panel-row.ui");
gtk_widget_class_bind_template_child (widget_class, GtdSidebarPanelRow, panel_icon);
gtk_widget_class_bind_template_child (widget_class, GtdSidebarPanelRow, subtitle_label);
diff --git a/data/ui/sidebar-panel-row.ui b/src/sidebar/gtd-sidebar-panel-row.ui
similarity index 100%
rename from data/ui/sidebar-panel-row.ui
rename to src/sidebar/gtd-sidebar-panel-row.ui
diff --git a/src/sidebar/gtd-sidebar-provider-row.c b/src/sidebar/gtd-sidebar-provider-row.c
index fddb446..9ebfefd 100644
--- a/src/sidebar/gtd-sidebar-provider-row.c
+++ b/src/sidebar/gtd-sidebar-provider-row.c
@@ -249,7 +249,7 @@ gtd_sidebar_provider_row_class_init (GtdSidebarProviderRowClass *klass)
g_object_class_install_properties (object_class, N_PROPS, properties);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/sidebar-provider-row.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/sidebar/gtd-sidebar-provider-row.ui");
gtk_widget_class_bind_template_child (widget_class, GtdSidebarProviderRow, loading_label);
gtk_widget_class_bind_template_child (widget_class, GtdSidebarProviderRow, provider_label);
diff --git a/data/ui/sidebar-provider-row.ui b/src/sidebar/gtd-sidebar-provider-row.ui
similarity index 100%
rename from data/ui/sidebar-provider-row.ui
rename to src/sidebar/gtd-sidebar-provider-row.ui
diff --git a/src/sidebar/gtd-sidebar.c b/src/sidebar/gtd-sidebar.c
index 5619adf..0aea533 100644
--- a/src/sidebar/gtd-sidebar.c
+++ b/src/sidebar/gtd-sidebar.c
@@ -514,7 +514,7 @@ gtd_sidebar_class_init (GtdSidebarClass *klass)
//g_object_class_install_properties (object_class, N_PROPS, properties);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/sidebar.ui");
+ gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/sidebar/gtd-sidebar.ui");
gtk_widget_class_bind_template_child (widget_class, GtdSidebar, listbox);
gtk_widget_class_bind_template_callback (widget_class, on_listbox_row_activated_cb);
diff --git a/data/ui/sidebar.ui b/src/sidebar/gtd-sidebar.ui
similarity index 100%
rename from data/ui/sidebar.ui
rename to src/sidebar/gtd-sidebar.ui
diff --git a/src/task-list-view/gtd-dnd-row.c b/src/task-list-view/gtd-dnd-row.c
index e4a6d5a..1ba983c 100644
--- a/src/task-list-view/gtd-dnd-row.c
+++ b/src/task-list-view/gtd-dnd-row.c
@@ -140,7 +140,7 @@ gtd_dnd_row_class_init (GtdDndRowClass *klass)
g_object_class_install_properties (object_class, N_PROPS, properties);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/dnd-row.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/task-list-view/gtd-dnd-row.ui");
gtk_widget_class_bind_template_child (widget_class, GtdDndRow, box);
gtk_widget_class_bind_template_child (widget_class, GtdDndRow, frame);
diff --git a/data/ui/dnd-row.ui b/src/task-list-view/gtd-dnd-row.ui
similarity index 100%
rename from data/ui/dnd-row.ui
rename to src/task-list-view/gtd-dnd-row.ui
diff --git a/src/task-list-view/gtd-edit-pane.c b/src/task-list-view/gtd-edit-pane.c
index 37bf927..d45f8cd 100644
--- a/src/task-list-view/gtd-edit-pane.c
+++ b/src/task-list-view/gtd-edit-pane.c
@@ -475,7 +475,7 @@ gtd_edit_pane_class_init (GtdEditPaneClass *klass)
GTD_TYPE_TASK);
/* template class */
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/edit-pane.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/task-list-view/gtd-edit-pane.ui");
gtk_widget_class_bind_template_child (widget_class, GtdEditPane, calendar);
gtk_widget_class_bind_template_child (widget_class, GtdEditPane, date_label);
diff --git a/data/ui/edit-pane.ui b/src/task-list-view/gtd-edit-pane.ui
similarity index 100%
rename from data/ui/edit-pane.ui
rename to src/task-list-view/gtd-edit-pane.ui
diff --git a/src/task-list-view/gtd-new-task-row.c b/src/task-list-view/gtd-new-task-row.c
index 12db224..0afe21e 100644
--- a/src/task-list-view/gtd-new-task-row.c
+++ b/src/task-list-view/gtd-new-task-row.c
@@ -260,7 +260,7 @@ gtd_new_task_row_class_init (GtdNewTaskRowClass *klass)
G_TYPE_NONE,
0);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/new-task-row.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/task-list-view/gtd-new-task-row.ui");
gtk_widget_class_bind_template_child (widget_class, GtdNewTaskRow, entry);
gtk_widget_class_bind_template_child (widget_class, GtdNewTaskRow, tasklist_popover);
diff --git a/data/ui/new-task-row.ui b/src/task-list-view/gtd-new-task-row.ui
similarity index 100%
rename from data/ui/new-task-row.ui
rename to src/task-list-view/gtd-new-task-row.ui
diff --git a/src/task-list-view/gtd-task-list-popover.c b/src/task-list-view/gtd-task-list-popover.c
index f084c64..03142ad 100644
--- a/src/task-list-view/gtd-task-list-popover.c
+++ b/src/task-list-view/gtd-task-list-popover.c
@@ -225,7 +225,7 @@ gtd_task_list_popover_class_init (GtdTaskListPopoverClass *klass)
GTD_TYPE_TASK_LIST,
G_PARAM_READABLE | G_PARAM_STATIC_STRINGS);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/task-list-popover.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/task-list-view/gtd-task-list-popover.ui");
gtk_widget_class_bind_template_child (widget_class, GtdTaskListPopover, listbox);
gtk_widget_class_bind_template_child (widget_class, GtdTaskListPopover, search_entry);
diff --git a/data/ui/task-list-popover.ui b/src/task-list-view/gtd-task-list-popover.ui
similarity index 100%
rename from data/ui/task-list-popover.ui
rename to src/task-list-view/gtd-task-list-popover.ui
diff --git a/src/task-list-view/gtd-task-list-view.c b/src/task-list-view/gtd-task-list-view.c
index 2402e93..f2988b5 100644
--- a/src/task-list-view/gtd-task-list-view.c
+++ b/src/task-list-view/gtd-task-list-view.c
@@ -1119,7 +1119,7 @@ gtd_task_list_view_class_init (GtdTaskListViewClass *klass)
TRUE,
G_PARAM_READWRITE));
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/list-view.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/task-list-view/gtd-task-list-view.ui");
gtk_widget_class_bind_template_child_private (widget_class, GtdTaskListView, due_date_sizegroup);
gtk_widget_class_bind_template_child_private (widget_class, GtdTaskListView, listbox);
diff --git a/data/ui/list-view.ui b/src/task-list-view/gtd-task-list-view.ui
similarity index 100%
rename from data/ui/list-view.ui
rename to src/task-list-view/gtd-task-list-view.ui
diff --git a/src/task-list-view/gtd-task-row.c b/src/task-list-view/gtd-task-row.c
index ab74e18..53bae82 100644
--- a/src/task-list-view/gtd-task-row.c
+++ b/src/task-list-view/gtd-task-row.c
@@ -638,7 +638,7 @@ gtd_task_row_class_init (GtdTaskRowClass *klass)
G_TYPE_NONE,
0);
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/task-row.ui");
+ gtk_widget_class_set_template_from_resource (widget_class,
"/org/gnome/todo/ui/task-list-view/gtd-task-row.ui");
gtk_widget_class_bind_template_child (widget_class, GtdTaskRow, content_box);
gtk_widget_class_bind_template_child (widget_class, GtdTaskRow, dnd_box);
diff --git a/data/ui/task-row.ui b/src/task-list-view/gtd-task-row.ui
similarity index 100%
rename from data/ui/task-row.ui
rename to src/task-list-view/gtd-task-row.ui
diff --git a/data/theme/Adwaita.css b/src/theme/Adwaita.css
similarity index 100%
rename from data/theme/Adwaita.css
rename to src/theme/Adwaita.css
diff --git a/src/todo.gresource.xml b/src/todo.gresource.xml
new file mode 100644
index 0000000..0b725ce
--- /dev/null
+++ b/src/todo.gresource.xml
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<gresources>
+ <gresource prefix="/org/gnome/todo/ui">
+ <file compressed="true" preprocess="xml-stripblanks">notification/gtd-notification-widget.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">provider/gtd-provider-popover.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">provider/gtd-provider-row.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">provider/gtd-provider-selector.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">sidebar/gtd-sidebar.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">sidebar/gtd-sidebar-list-row.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">sidebar/gtd-sidebar-panel-row.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">sidebar/gtd-sidebar-provider-row.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">task-list-view/gtd-dnd-row.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">task-list-view/gtd-edit-pane.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">task-list-view/gtd-new-task-row.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">task-list-view/gtd-task-list-popover.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">task-list-view/gtd-task-list-view.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">task-list-view/gtd-task-row.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">widgets/gtd-empty-list-widget.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">gtd-initial-setup-window.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">gtd-plugin-dialog.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">gtd-plugin-dialog-row.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">gtd-task-list-panel.ui</file>
+ <file compressed="true" preprocess="xml-stripblanks">gtd-window.ui</file>
+ </gresource>
+
+ <gresource prefix="/org/gnome/todo">
+ <file compressed="true">theme/Adwaita.css</file>
+ </gresource>
+</gresources>
diff --git a/src/gtd-empty-list-widget.c b/src/widgets/gtd-empty-list-widget.c
similarity index 98%
rename from src/gtd-empty-list-widget.c
rename to src/widgets/gtd-empty-list-widget.c
index 6abecd5..8e4f1cd 100644
--- a/src/gtd-empty-list-widget.c
+++ b/src/widgets/gtd-empty-list-widget.c
@@ -120,7 +120,7 @@ gtd_empty_list_widget_class_init (GtdEmptyListWidgetClass *klass)
object_class->get_property = gtd_empty_list_widget_get_property;
object_class->set_property = gtd_empty_list_widget_set_property;
- gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/empty-list.ui");
+ gtk_widget_class_set_template_from_resource (widget_class, "/org/gnome/todo/ui/widgets/gtd-empty-list.ui");
gtk_widget_class_bind_template_child (widget_class, GtdEmptyListWidget, icon);
gtk_widget_class_bind_template_child (widget_class, GtdEmptyListWidget, subtitle_label);
diff --git a/src/gtd-empty-list-widget.h b/src/widgets/gtd-empty-list-widget.h
similarity index 100%
rename from src/gtd-empty-list-widget.h
rename to src/widgets/gtd-empty-list-widget.h
diff --git a/data/ui/empty-list.ui b/src/widgets/gtd-empty-list-widget.ui
similarity index 100%
rename from data/ui/empty-list.ui
rename to src/widgets/gtd-empty-list-widget.ui
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]