Commit 284c3c67 authored by Jens Georg's avatar Jens Georg

Reorganize source tree

 * Move everything data into data
 * Move all icons into one common place
 * Rename desktop and appdata files to org.gnome.Shotwell
 * Drop GConf migrator (broken anyway since ages)
parent a164ff45
...@@ -4,4 +4,3 @@ import apport.hookutils ...@@ -4,4 +4,3 @@ import apport.hookutils
def add_info(report): def add_info(report):
log_file = os.path.expanduser('~/.cache/shotwell/shotwell.log') log_file = os.path.expanduser('~/.cache/shotwell/shotwell.log')
apport.hookutils.attach_file_if_exists(report, log_file, 'shotwell.log') apport.hookutils.attach_file_if_exists(report, log_file, 'shotwell.log')
install_data(files('org.yorba.shotwell-extras.gschema.xml',
'org.yorba.shotwell.gschema.xml'),
install_dir : join_paths(get_option('datadir'), 'glib-2.0', 'schemas'))
gnome.compile_schemas()
...@@ -92,4 +92,3 @@ ...@@ -92,4 +92,3 @@
</schema> </schema>
</schemalist> </schemalist>
...@@ -831,4 +831,3 @@ ...@@ -831,4 +831,3 @@
</schema> </schema>
</schemalist> </schemalist>
icondir = join_paths(get_option('datadir'), 'icons/hicolor')
install_subdir('hicolor/16x16', install_dir : icondir)
install_subdir('hicolor/22x22', install_dir : icondir)
install_subdir('hicolor/24x24', install_dir : icondir)
install_subdir('hicolor/32x32', install_dir : icondir)
install_subdir('hicolor/48x48', install_dir : icondir)
install_subdir('hicolor/256x256', install_dir : icondir)
install_subdir('hicolor/symbolic', install_dir : icondir)
if get_option('install-apport-hook')
subdir('apport')
endif
subdir('gsettings')
subdir('icons')
podir = join_paths('..', 'po') podir = join_paths('..', 'po')
i18n.merge_file(input : 'shotwell.appdata.xml.in', i18n.merge_file(input : 'org.gnome.Shotwell.appdata.xml.in',
output : 'shotwell.appdata.xml', output : 'org.gnome.Shotwell.appdata.xml',
po_dir : join_paths('..', 'po'), po_dir : join_paths('..', 'po'),
type : 'xml', type : 'xml',
install: true, install: true,
install_dir : join_paths(get_option('datadir'), 'metainfo')) install_dir : join_paths(get_option('datadir'), 'metainfo'))
i18n.merge_file(input : 'shotwell.desktop.in', i18n.merge_file(input : 'org.gnome.Shotwell.desktop.in',
output: 'shotwell.desktop', output: 'org.gnome.Shotwell.desktop',
po_dir : podir, po_dir : podir,
type : 'desktop', type : 'desktop',
install : true, install : true,
install_dir : join_paths(get_option('datadir'), 'applications')) install_dir : join_paths(get_option('datadir'), 'applications'))
i18n.merge_file(input : 'shotwell-viewer.desktop.in', i18n.merge_file(input : 'org.gnome.Shotwell-Viewer.desktop.in',
output: 'shotwell-viewer.desktop', output: 'org.gnome.Shotwell-Viewer.desktop',
po_dir : podir, po_dir : podir,
type : 'desktop', type : 'desktop',
install : true, install : true,
install_dir : join_paths(get_option('datadir'), 'applications')) install_dir : join_paths(get_option('datadir'), 'applications'))
install_data(['org.yorba.shotwell-extras.gschema.xml', shotwell_resources = gnome.compile_resources('shotwell-resources',
'org.yorba.shotwell.gschema.xml'], 'org.gnome.Shotwell.gresource.xml')
install_dir : join_paths(get_option('datadir'), 'glib-2.0', 'schemas'))
gnome.compile_schemas()
...@@ -4,7 +4,7 @@ Name=Shotwell Viewer ...@@ -4,7 +4,7 @@ Name=Shotwell Viewer
GenericName=Photo Viewer GenericName=Photo Viewer
Exec=shotwell %f Exec=shotwell %f
# Translators: Do NOT translate or transliterate this text (this is an icon file name)! # Translators: Do NOT translate or transliterate this text (this is an icon file name)!
Icon=shotwell Icon=org.gnome.Shotwell
Terminal=false Terminal=false
NoDisplay=true NoDisplay=true
Type=Application Type=Application
......
...@@ -7,7 +7,7 @@ Comment=Organize your photos ...@@ -7,7 +7,7 @@ Comment=Organize your photos
Keywords=album;camera;cameras;crop;edit;enhance;export;gallery;image;images;import;organize;photo;photographs;photos;picture;pictures;photography;print;publish;rotate;share;tags;video;facebook;flickr;picasa;youtube;piwigo; Keywords=album;camera;cameras;crop;edit;enhance;export;gallery;image;images;import;organize;photo;photographs;photos;picture;pictures;photography;print;publish;rotate;share;tags;video;facebook;flickr;picasa;youtube;piwigo;
Exec=shotwell %U Exec=shotwell %U
# Translators: Do NOT translate or transliterate this text (this is an icon file name)! # Translators: Do NOT translate or transliterate this text (this is an icon file name)!
Icon=shotwell Icon=org.gnome.Shotwell
Terminal=false Terminal=false
Type=Application Type=Application
MimeType=x-content/image-dcf; MimeType=x-content/image-dcf;
......
...@@ -33,35 +33,35 @@ ...@@ -33,35 +33,35 @@
<file preprocess="xml-stripblanks">ui/textentrydialog.ui</file> <file preprocess="xml-stripblanks">ui/textentrydialog.ui</file>
<file preprocess="xml-stripblanks">ui/trash.ui</file> <file preprocess="xml-stripblanks">ui/trash.ui</file>
<!-- Icons --> <!-- Icons -->
<file>icons/avatar-default-symbolic.svg</file> <file>icons/hicolor/scalable/actions/avatar-default-symbolic.svg</file>
<file>icons/image-missing.png</file> <file>icons/image-missing.png</file>
<file>icons/about-braunschweig.jpg</file> <file>icons/about-braunschweig.jpg</file>
<file>icons/crop-pivot-reticle-symbolic.svg</file> <file>icons/hicolor/scalable/actions/crop-pivot-reticle-symbolic.svg</file>
<file>icons/events-merge-symbolic.svg</file> <file>icons/hicolor/scalable/actions/events-merge-symbolic.svg</file>
<file>icons/filter-flagged-symbolic.svg</file> <file>icons/hicolor/scalable/actions/filter-flagged-symbolic.svg</file>
<file>icons/filter-flagged-disabled-symbolic.svg</file> <file>icons/hicolor/scalable/actions/filter-flagged-disabled-symbolic.svg</file>
<file>icons/filter-photos-symbolic.svg</file> <file>icons/hicolor/scalable/actions/filter-photos-symbolic.svg</file>
<file>icons/filter-photos-disabled-symbolic.svg</file> <file>icons/hicolor/scalable/actions/filter-photos-disabled-symbolic.svg</file>
<file>icons/filter-raw-symbolic.svg</file> <file>icons/hicolor/scalable/actions/filter-raw-symbolic.svg</file>
<file>icons/filter-raw-disabled-symbolic.svg</file> <file>icons/hicolor/scalable/actions/filter-raw-disabled-symbolic.svg</file>
<file>icons/filter-videos-disabled-symbolic.svg</file> <file>icons/hicolor/scalable/actions/filter-videos-disabled-symbolic.svg</file>
<file>icons/filter-videos-symbolic.svg</file> <file>icons/hicolor/scalable/actions/filter-videos-symbolic.svg</file>
<file>icons/image-crop-symbolic.svg</file> <file>icons/hicolor/scalable/actions/image-crop-symbolic.svg</file>
<file>icons/image-auto-adjust-symbolic.svg</file> <file>icons/hicolor/scalable/actions/image-auto-adjust-symbolic.svg</file>
<file>icons/image-adjust-color-symbolic.svg</file> <file>icons/hicolor/scalable/actions/image-adjust-color-symbolic.svg</file>
<file>icons/image-zoom-in-symbolic.svg</file> <file>icons/hicolor/scalable/actions/image-zoom-in-symbolic.svg</file>
<file>icons/image-zoom-out-symbolic.svg</file> <file>icons/hicolor/scalable/actions/image-zoom-out-symbolic.svg</file>
<file>icons/multiple-events-symbolic.svg</file> <file>icons/hicolor/scalable/actions/multiple-events-symbolic.svg</file>
<file>icons/multiple-tags-symbolic.svg</file> <file>icons/hicolor/scalable/actions/multiple-tags-symbolic.svg</file>
<file>icons/no-event-symbolic.svg</file> <file>icons/hicolor/scalable/actions/no-event-symbolic.svg</file>
<file>icons/noninterpretable-video.png</file> <file>icons/noninterpretable-video.png</file>
<file>icons/one-event-symbolic.svg</file> <file>icons/hicolor/scalable/actions/one-event-symbolic.svg</file>
<file>icons/one-tag-symbolic.svg</file> <file>icons/hicolor/scalable/actions/one-tag-symbolic.svg</file>
<file>icons/stock-eye-symbolic.svg</file> <file>icons/hicolor/scalable/actions/stock-eye-symbolic.svg</file>
<file preprocess="xml-stripblanks">icons/shotwell.svg</file> <file preprocess="xml-stripblanks">icons/hicolor/scalable/apps/org.gnome.Shotwell.svg</file>
<file>icons/shotwell-street.jpg</file> <file>icons/shotwell-street.jpg</file>
<file>icons/slideshow-extension-point.png</file> <file>icons/slideshow-extension-point.png</file>
<file>icons/straighten-symbolic.svg</file> <file>icons/hicolor/scalable/actions/straighten-symbolic.svg</file>
<file>misc/org.gnome.Shotwell.css</file> <file>themes/org.gnome.Shotwell.css</file>
</gresource> </gresource>
</gresources> </gresources>
...@@ -3,4 +3,3 @@ ...@@ -3,4 +3,3 @@
<accelerator name="LeaveFullscreen" action="LeaveFullscreen" /> <accelerator name="LeaveFullscreen" action="LeaveFullscreen" />
</ui> </ui>
...@@ -14,4 +14,3 @@ ...@@ -14,4 +14,3 @@
</section> </section>
</menu> </menu>
</interface> </interface>
...@@ -4,9 +4,6 @@ ...@@ -4,9 +4,6 @@
"runtime-version": "3.28", "runtime-version": "3.28",
"sdk": "org.gnome.Sdk", "sdk": "org.gnome.Sdk",
"command" : "shotwell", "command" : "shotwell",
"rename-desktop-file" : "shotwell.desktop",
"rename-icon" : "shotwell",
"rename-appdata-file" : "shotwell.appdata.xml",
"tags": [ "nightly" ], "tags": [ "nightly" ],
"desktop-file-name-prefix": "(Nightly) ", "desktop-file-name-prefix": "(Nightly) ",
"finish-args": [ "finish-args": [
......
...@@ -100,19 +100,10 @@ cairo = dependency('cairo') ...@@ -100,19 +100,10 @@ cairo = dependency('cairo')
valac = meson.get_compiler('vala') valac = meson.get_compiler('vala')
posix = valac.find_library('posix') posix = valac.find_library('posix')
shotwell_resources = gnome.compile_resources('shotwell-resources', subdir('data')
'org.gnome.Shotwell.gresource.xml')
subdir('src') subdir('src')
subdir('plugins') subdir('plugins')
subdir('po') subdir('po')
subdir('help') subdir('help')
subdir('misc')
subdir('thumbnailer') subdir('thumbnailer')
subdir('settings-migrator')
subdir('test') subdir('test')
subdir('app-icons')
if get_option('install-apport-hook')
subdir('apport')
endif
[org.yorba.shotwell.preferences.ui]
background-color = /apps/shotwell/preferences/ui/background_color
display-basic-properties = /apps/shotwell/preferences/ui/display_basic_properties
display-extended-properties = /apps/shotwell/preferences/ui/display_extended_properties
display-photo-ratings = /apps/shotwell/preferences/ui/display_photo_ratings
display-photo-tags = /apps/shotwell/preferences/ui/display_photo_tags
display-photo-titles = /apps/shotwell/preferences/ui/display_photo_titles
event-photos-sort-ascending = /apps/shotwell/preferences/ui/event_photos_sort_ascending
event-photos-sort-by = /apps/shotwell/preferences/ui/event_photos_sort_by
events-sort-ascending = /apps/shotwell/preferences/ui/events_sort_ascending
hide-photos-already-imported = /apps/shotwell/preferences/ui/hide_photos_already_imported
keep-relativity = /apps/shotwell/preferences/ui/keep_relativity
library-photos-sort-ascending = /apps/shotwell/preferences/ui/library_photos_sort_ascending
library-photos-sort-by = /apps/shotwell/preferences/ui/library_photos_sort_by
modify-originals = /apps/shotwell/preferences/ui/modify_originals
photo-thumbnail-scale = /apps/shotwell/preferences/ui/photo_thumbnail_scale
show-welcome-dialog = /apps/shotwell/preferences/ui/show_welcome_dialog
sidebar-position = /apps/shotwell/preferences/ui/pane_position
use-24-hour-time = /apps/shotwell/preferences/ui/twentyfour_hr_time
[org.yorba.shotwell.preferences.slideshow]
delay = /apps/shotwell/preferences/slideshow/delay
transition-delay = /apps/shotwell/preferences/slideshow_transition/delay
transition-effect-id = /apps/shotwell/preferences/slideshow_transition/name
show-title = /apps/shotwell/preferences/slideshow/show-title
[org.yorba.shotwell.preferences.window]
direct-height = /apps/shotwell/preferences/window/direct_height
direct-maximize = /apps/shotwell/preferences/window/direct_maximize
direct-width = /apps/shotwell/preferences/window/direct_width
library-height = /apps/shotwell/preferences/window/library_height
library-maximize = /apps/shotwell/preferences/window/library_maximize
library-width = /apps/shotwell/preferences/window/library_width
[org.yorba.shotwell.preferences.files]
auto-import = /apps/shotwell/preferences/files/auto_import
commit-metadata = /apps/shotwell/preferences/files/commit_metadata
directory-pattern = /apps/shotwell/preferences/files/directory_pattern
directory-pattern-custom = /apps/shotwell/preferences/files/directory_pattern_custom
import-dir = /apps/shotwell/preferences/files/import_dir
use-lowercase-filenames = /apps/shotwell/preferences/files/use_lowercase_filenames
raw-developer-default = /apps/shotwell/preferences/files/raw_developer_default
[org.yorba.shotwell.preferences.editing]
external-photo-editor = /apps/shotwell/preferences/editing/external_photo_editor
external-raw-editor = /apps/shotwell/preferences/editing/external_raw_editor
[org.yorba.shotwell.video]
interpreter-state-cookie = /apps/shotwell/video/interpreter_state_cookie
[org.yorba.shotwell.printing]
content-height = /apps/shotwell/printing/content_height
content-layout = /apps/shotwell/printing/content_layout
content-ppi = /apps/shotwell/printing/content_ppi
content-units = /apps/shotwell/printing/content_units
content-width = /apps/shotwell/printing/content_width
images-per-page = /apps/shotwell/printing/images_per_page_selection
match-aspect-ratio = /apps/shotwell/printing/match_aspect_ratio
print-titles = /apps/shotwell/printing/print_titles
size-selection = /apps/shotwell/printing/size_selection
titles-font = /apps/shotwell/printing/print_titles_font
[org.yorba.shotwell.sharing]
default-service = /apps/shotwell/sharing/default_service
last-used-service = /apps/shotwell/sharing/last_used_service
[org.yorba.shotwell.plugins.enable-state]
publishing-facebook = /apps/shotwell/plugins/org.yorba.shotwell.publishing.facebook/enabled
publishing-flickr = /apps/shotwell/plugins/org.yorba.shotwell.publishing.flickr/enabled
publishing-picasa = /apps/shotwell/plugins/org.yorba.shotwell.publishing.picasa/enabled
publishing-piwigo = /apps/shotwell/plugins/org.yorba.shotwell.publishing.piwigo/enabled
publishing-yandex-fotki = /apps/shotwell/plugins/org.yorba.shotwell.publishing.yandex-fotki/enabled
publishing-youtube = /apps/shotwell/plugins/org.yorba.shotwell.publishing.youtube/enabled
transitions-crumble = /apps/shotwell/plugins/org.yorba.shotwell.transitions.crumble/enabled
transitions-fade = /apps/shotwell/plugins/org.yorba.shotwell.transitions.fade/enabled
transitions-slide = /apps/shotwell/plugins/org.yorba.shotwell.transitions.slide/enabled
[org.yorba.shotwell.sharing.facebook]
uid = /apps/shotwell/sharing/facebook/uid
user-name = /apps/shotwell/sharing/facebook/user_name
default-size = /apps/shotwell/sharing/facebook/default_size
[org.yorba.shotwell.sharing.flickr]
default-size = /apps/shotwell/sharing/flickr/default_size
visibility = /apps/shotwell/sharing/flickr/visibility
[org.yorba.shotwell.sharing.picasa]
default-size = /apps/shotwell/sharing/picasa/default_size
last-album = /apps/shotwell/sharing/picasa/last_album
[org.yorba.shotwell.sharing.org-yorba-shotwell-publishing-piwigo]
url = /apps/shotwell/sharing/org.yorba.shotwell.publishing.piwigo/url
username = /apps/shotwell/sharing/org.yorba.shotwell.publishing.piwigo/username
password = /apps/shotwell/sharing/org.yorba.shotwell.publishing.piwigo/password
remember-password = /apps/shotwell/sharing/org.yorba.shotwell.publishing.piwigo/remember-password
last-category = /apps/shotwell/sharing/org.yorba.shotwell.publishing.piwigo/last-category
last-permission-level = /apps/shotwell/sharing/org.yorba.shotwell.publishing.piwigo/last-permission-level
[org.yorba.shotwell.sharing.org-yorba-shotwell-publishing-yandex-fotki]
auth-token = /apps/shotwell/sharing/org.yorba.shotwell.publishing.yandex-fotki/auth_token
[org.yorba.shotwell.sharing.youtube]
user-name = /apps/shotwell/sharing/youtube/user_name
auth-token = /apps/shotwell/sharing/youtube/auth_token
install_data('shotwell-settings-migrator',
install_mode : 'rwxr-xr-x',
install_dir : join_paths(get_option('libexecdir'), 'shotwell'))
#!/bin/sh
################################################################################
#
# Copyright 2016 Software Freedom Conservancy Inc.
#
# This software is licensed under the GNU LGPL (version 2.1 or later).
# See the COPYING file in this distribution.
#
# Helper script to copy settings data from /apps/shotwell/ to
# /org/yorba/shotwell/
#
# NOTE: this should only be run ONCE as part of the upgrade process; otherwise,
# any stale data in the old location may be inadvertently copied over again,
# overwriting newer data.
#
################################################################################
sec_since_epoch=`date +%s`
temp_file_path_prefix=/tmp/shotwell-migrate-settings-path-
temp_file_path=$temp_file_path_prefix$sec_since_epoch
# Copy from deprecated path...
dconf dump /apps/shotwell/ > $temp_file_path
# ...and into officially-blessed one.
dconf load /org/yorba/shotwell/ < $temp_file_path
# Clean out the stale paths...
dconf reset -f /apps/shotwell/
# temp file not needed anymore, zap it.
rm -f $temp_file_path
prefix=_PREFIX_
exec_prefix=${prefix}
libdir=${exec_prefix}/_LIB_
includedir=${prefix}/include
Name: Shotwell Plugin Development
Description: Headers for building Shotwell plugins
Requires: _REQUIREMENTS_
Version: _VERSION_
Cflags: -I${includedir}/shotwell
...@@ -413,7 +413,7 @@ public abstract class AppWindow : PageWindow { ...@@ -413,7 +413,7 @@ public abstract class AppWindow : PageWindow {
instance = this; instance = this;
title = Resources.APP_TITLE; title = Resources.APP_TITLE;
set_default_icon_name("shotwell"); set_default_icon_name("org.gnome.Shotwell");
// restore previous size and maximization state // restore previous size and maximization state
if (this is LibraryWindow) { if (this is LibraryWindow) {
...@@ -441,8 +441,11 @@ public abstract class AppWindow : PageWindow { ...@@ -441,8 +441,11 @@ public abstract class AppWindow : PageWindow {
add_actions (); add_actions ();
Gtk.CssProvider provider = new Gtk.CssProvider(); Gtk.CssProvider provider = new Gtk.CssProvider();
provider.load_from_resource("/org/gnome/Shotwell/misc/org.gnome.Shotwell.css"); provider.load_from_resource("/org/gnome/Shotwell/themes/org.gnome.Shotwell.css");
Gtk.StyleContext.add_provider_for_screen(Gdk.Screen.get_default(), provider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION); Gtk.StyleContext.add_provider_for_screen(Gdk.Screen.get_default(), provider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
var foo = Gtk.IconTheme.get_default();
foo.add_resource_path("/org/gnome/Shotwell/icons/hicolor");
} }
private const GLib.ActionEntry[] common_actions = { private const GLib.ActionEntry[] common_actions = {
......
...@@ -109,7 +109,7 @@ void library_exec(string[] mounts) { ...@@ -109,7 +109,7 @@ void library_exec(string[] mounts) {
progress_dialog.update_display_every(100); progress_dialog.update_display_every(100);
progress_dialog.set_minimum_on_screen_time_msec(250); progress_dialog.set_minimum_on_screen_time_msec(250);
try { try {
progress_dialog.icon = new Gdk.Pixbuf.from_resource("/org/gnome/Shotwell/icons/shotwell.svg"); progress_dialog.icon = new Gdk.Pixbuf.from_resource("/org/gnome/Shotwell/icons/hicolor/scalable/org.gnome.Shotwell.svg");
} catch (Error err) { } catch (Error err) {
debug("Warning - could not load application icon for loading window: %s", err.message); debug("Warning - could not load application icon for loading window: %s", err.message);
} }
...@@ -365,7 +365,7 @@ void main(string[] args) { ...@@ -365,7 +365,7 @@ void main(string[] args) {
// muck with the user's XDG_... directories, which is seriously frowned upon // muck with the user's XDG_... directories, which is seriously frowned upon
if (AppDirs.get_install_dir() == null) { if (AppDirs.get_install_dir() == null) {
GLib.Environment.set_variable("GSETTINGS_SCHEMA_DIR", AppDirs.get_lib_dir().get_path() + GLib.Environment.set_variable("GSETTINGS_SCHEMA_DIR", AppDirs.get_lib_dir().get_path() +
"/misc", true); "/data/gsettings", true);
} }
// init GTK (valac has already called g_threads_init()) // init GTK (valac has already called g_threads_init())
......
...@@ -246,7 +246,7 @@ executable('shotwell', ...@@ -246,7 +246,7 @@ executable('shotwell',
'--pkg', 'libexif', '--pkg', 'libexif',
'--pkg', 'misc', '--pkg', 'misc',
'--gresources', '--gresources',
join_paths(meson.source_root(), join_paths(meson.source_root(), 'data',
'org.gnome.Shotwell.gresource.xml') 'org.gnome.Shotwell.gresource.xml')
], ],
link_with: [sw_graphics_processor], link_with: [sw_graphics_processor],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment