diff options
Diffstat (limited to 'mate-screenshot/src')
-rw-r--r-- | mate-screenshot/src/Makefile.am | 22 | ||||
-rw-r--r-- | mate-screenshot/src/screenshot-dialog.c | 4 |
2 files changed, 20 insertions, 6 deletions
diff --git a/mate-screenshot/src/Makefile.am b/mate-screenshot/src/Makefile.am index 9ae05a73..e5104cbd 100644 --- a/mate-screenshot/src/Makefile.am +++ b/mate-screenshot/src/Makefile.am @@ -4,11 +4,20 @@ AM_CPPFLAGS = \ -I. \ -I$(srcdir) \ -DMATELOCALEDIR=\""$(prefix)/$(DATADIRNAME)/locale"\" \ - -DUIDIR=\""$(datadir)/mate-screenshot"\" + $(NULL) bin_PROGRAMS = mate-screenshot -mate_screenshot_SOURCES = \ +BUILT_SOURCES = \ + screenshot-resources.c \ + screenshot-resources.h \ + $(NULL) + +nodist_mate_screenshot_SOURCES = \ + $(BUILT_SOURCES) \ + $(NULL) + +mate_screenshot_SOURCES = \ mate-screenshot.c \ screenshot-dialog.c \ screenshot-dialog.h \ @@ -32,7 +41,7 @@ mate_screenshot_CFLAGS = \ mate_screenshot_LDFLAGS = -export-dynamic -mate_screenshot_LDADD = \ +mate_screenshot_LDADD = \ $(XSHAPE_LIBS) \ $(GLIB_LIBS) \ $(GIO_LIBS) \ @@ -41,6 +50,13 @@ mate_screenshot_LDADD = \ $(GTK_LIBS) \ -lm +screenshot-resources.h screenshot-resources.c: $(srcdir)/../data/org.mate.screenshot.gresource.xml Makefile $(shell $(GLIB_COMPILE_RESOURCES) --generate-dependencies --sourcedir $(srcdir)/../data $(srcdir)/../data/org.mate.screenshot.gresource.xml) + $(AM_V_GEN) XMLLINT=$(XMLLINT) $(GLIB_COMPILE_RESOURCES) --target $@ --sourcedir $(srcdir)/../data --generate --c-name screenshot $< + +CLEANFILES = \ + $(BUILT_SOURCES) \ + $(NULL) + install-exec-local: rm -f $(DESTDIR)$(bindir)/mate-panel-screenshot ln -s mate-screenshot $(DESTDIR)$(bindir)/mate-panel-screenshot diff --git a/mate-screenshot/src/screenshot-dialog.c b/mate-screenshot/src/screenshot-dialog.c index f9450582..854ae3e4 100644 --- a/mate-screenshot/src/screenshot-dialog.c +++ b/mate-screenshot/src/screenshot-dialog.c @@ -181,7 +181,6 @@ screenshot_dialog_new (GdkPixbuf *screenshot, GFile *tmp_file; GFile *parent_file; GError *error = NULL; - guint res; tmp_file = g_file_new_for_uri (initial_uri); parent_file = g_file_get_parent (tmp_file); @@ -194,11 +193,10 @@ screenshot_dialog_new (GdkPixbuf *screenshot, dialog = g_new0 (ScreenshotDialog, 1); dialog->ui = gtk_builder_new (); - res = gtk_builder_add_from_file (dialog->ui, UIDIR "/mate-screenshot.ui", &error); dialog->screenshot = screenshot; - if (res == 0) + if (gtk_builder_add_from_resource (dialog->ui, "/org/mate/screenshot/mate-screenshot.ui", &error) == 0) { GtkWidget *dialog; dialog = gtk_message_dialog_new (NULL, 0, |