general: Rename to Loupe

Sets the codename, binary name, and app ID name to Loupe.
The user-visible name is still Image Viewer.
This commit is contained in:
Christopher Davis 2021-09-28 17:44:26 -07:00
parent 9833c1edc0
commit cced598239
25 changed files with 76 additions and 76 deletions

View file

@ -110,7 +110,7 @@ impl IvApplication {
glib::Object::new(&[
("application-id", &config::APP_ID.to_string()),
("flags", &gio::ApplicationFlags::HANDLES_OPEN),
("resource-base-path", &"/org/gnome/ImageViewer/".to_string()),
("resource-base-path", &"/org/gnome/Loupe/".to_string()),
])
.unwrap()
}
@ -198,6 +198,6 @@ impl IvApplication {
}
pub fn show_help(&self) {
gtk::show_uri(self.active_window().as_ref(), "help:gnome-image-viewer", 0);
gtk::show_uri(self.active_window().as_ref(), "help:loupe", 0);
}
}

View file

@ -34,10 +34,10 @@ fn main() {
pretty_env_logger::init();
setlocale(LocaleCategory::LcAll, "");
bindtextdomain("gnome-image-viewer", config::LOCALEDIR).unwrap();
textdomain("gnome-image-viewer").unwrap();
bindtextdomain("loupe", config::LOCALEDIR).unwrap();
textdomain("loupe").unwrap();
let res = gio::Resource::load(config::PKGDATADIR.to_owned() + "/gnome-image-viewer.gresource")
let res = gio::Resource::load(config::PKGDATADIR.to_owned() + "/loupe.gresource")
.expect("Could not load resources");
gio::resources_register(&res);

View file

@ -39,7 +39,7 @@ mod imp {
use glib::subclass;
#[derive(Debug, Default, CompositeTemplate)]
#[template(resource = "/org/gnome/ImageViewer/gtk/image_view.ui")]
#[template(resource = "/org/gnome/Loupe/gtk/image_view.ui")]
pub struct IvImageView {
#[template_child]
pub picture: TemplateChild<gtk::Picture>,

View file

@ -46,7 +46,7 @@ mod imp {
// we'd need to have a `new()` function in the
// `impl ObjectSubclass for $TYPE` section.
#[derive(Default, Debug, CompositeTemplate)]
#[template(resource = "/org/gnome/ImageViewer/gtk/window.ui")]
#[template(resource = "/org/gnome/Loupe/gtk/window.ui")]
pub struct IvWindow {
// Template children are used with the
// TemplateChild<T> wrapper, where T is the
@ -121,7 +121,7 @@ mod imp {
.set_icon_name(Some(&format!("{}-symbolic", config::APP_ID)));
// Set help overlay
let builder = gtk::Builder::from_resource("/org/gnome/ImageViewer/gtk/help_overlay.ui");
let builder = gtk::Builder::from_resource("/org/gnome/Loupe/gtk/help_overlay.ui");
let help_overlay = builder.object("help_overlay").unwrap();
obj.set_help_overlay(Some(&help_overlay));