summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefano Karapetsas <[email protected]>2015-09-04 11:08:48 +0200
committerStefano Karapetsas <[email protected]>2015-09-04 11:08:48 +0200
commitae166272bb8a52e08fc8750069a1c273177d48ea (patch)
tree204471195b02809749127965f23db3be1bffd236
parentde87cfc36812298c0d8ad76079cc09e4b7f80aa9 (diff)
parent03f942ae10a7b210dda3e1d9989868ca48d6688d (diff)
downloadatril-ae166272bb8a52e08fc8750069a1c273177d48ea.tar.bz2
atril-ae166272bb8a52e08fc8750069a1c273177d48ea.tar.xz
Merge pull request #156 from monsta/stuff
some minor cleanup (mostly from upstream)
-rw-r--r--backend/comics/comics-document.c2
-rw-r--r--backend/dvi/mdvi-lib/bitmap.c2
-rw-r--r--backend/dvi/mdvi-lib/sp-epsf.c2
-rw-r--r--backend/dvi/mdvi-lib/tfmfile.c3
-rw-r--r--backend/pdf/ev-poppler.cc15
-rw-r--r--backend/xps/xps-document.c1
-rw-r--r--[-rwxr-xr-x]libview/ev-view.h0
7 files changed, 4 insertions, 21 deletions
diff --git a/backend/comics/comics-document.c b/backend/comics/comics-document.c
index da872ffb..2601d356 100644
--- a/backend/comics/comics-document.c
+++ b/backend/comics/comics-document.c
@@ -889,7 +889,7 @@ comics_document_init (ComicsDocument *comics_document)
/* Returns a list of file extensions supported by gdk-pixbuf */
static GSList*
-get_supported_image_extensions()
+get_supported_image_extensions(void)
{
GSList *extensions = NULL;
GSList *formats = gdk_pixbuf_get_formats ();
diff --git a/backend/dvi/mdvi-lib/bitmap.c b/backend/dvi/mdvi-lib/bitmap.c
index 6edec1df..4417a75b 100644
--- a/backend/dvi/mdvi-lib/bitmap.c
+++ b/backend/dvi/mdvi-lib/bitmap.c
@@ -131,7 +131,6 @@ BITMAP *bitmap_convert_lsb8(Uchar *bits, int w, int h, int stride)
int i;
Uchar *unit;
register Uchar *curr;
- Uchar *end;
int bytes;
DEBUG((DBG_BITMAP_OPS, "convert LSB %dx%d@8 -> bitmap\n", w, h));
@@ -141,7 +140,6 @@ BITMAP *bitmap_convert_lsb8(Uchar *bits, int w, int h, int stride)
/* this is the number of bytes in the original bitmap */
bytes = ROUND(w, 8);
unit = (Uchar *)bm->data;
- end = unit + bm->stride;
curr = bits;
/* we try to do this as fast as we can */
for(i = 0; i < h; i++) {
diff --git a/backend/dvi/mdvi-lib/sp-epsf.c b/backend/dvi/mdvi-lib/sp-epsf.c
index 703a9c8c..4f1b49cb 100644
--- a/backend/dvi/mdvi-lib/sp-epsf.c
+++ b/backend/dvi/mdvi-lib/sp-epsf.c
@@ -79,7 +79,6 @@ static char *parse_epsf_special(EpsfBox *box, char **ret,
#define NKEYS (sizeof(keys) / sizeof(keys[0]))
char *ptr;
char *filename;
- int quoted;
double value[NKEYS];
Uchar present[NKEYS];
Buffer buffer;
@@ -121,7 +120,6 @@ static char *parse_epsf_special(EpsfBox *box, char **ret,
buff_init(&buffer);
buff_add(&buffer, "@beginspecial ", 0);
- quoted = 0;
while(*ptr) {
const char *keyname;
char *val;
diff --git a/backend/dvi/mdvi-lib/tfmfile.c b/backend/dvi/mdvi-lib/tfmfile.c
index 8c2a30b2..c23d9fe0 100644
--- a/backend/dvi/mdvi-lib/tfmfile.c
+++ b/backend/dvi/mdvi-lib/tfmfile.c
@@ -298,7 +298,7 @@ error:
static int ofm1_load_file(FILE *in, TFMInfo *info)
{
- int lf, lh, bc, ec, nw, nh, nd;
+ int lh, bc, ec, nw, nh, nd;
int nco, ncw, npc;
int i;
int n;
@@ -310,7 +310,6 @@ static int ofm1_load_file(FILE *in, TFMInfo *info)
TFMChar *tch;
TFMChar *end;
- lf = fuget4(in);
lh = fuget4(in);
bc = fuget4(in);
ec = fuget4(in);
diff --git a/backend/pdf/ev-poppler.cc b/backend/pdf/ev-poppler.cc
index 5f34a9b3..ea496951 100644
--- a/backend/pdf/ev-poppler.cc
+++ b/backend/pdf/ev-poppler.cc
@@ -379,7 +379,6 @@ static cairo_surface_t *
pdf_document_render (EvDocument *document,
EvRenderContext *rc)
{
- PdfDocument *pdf_document;
PopplerPage *poppler_page;
double width_points, height_points;
gint width, height;
@@ -632,7 +631,6 @@ pdf_document_get_info (EvDocument *document)
PopplerPageMode mode;
PopplerViewerPreferences view_prefs;
PopplerPermissions permissions;
- EvPage *page;
char *metadata;
gboolean linearized;
@@ -1351,12 +1349,10 @@ pdf_document_images_get_image_mapping (EvDocumentImages *document_images,
EvPage *page)
{
GList *retval = NULL;
- PdfDocument *pdf_document;
PopplerPage *poppler_page;
GList *mapping_list;
GList *list;
- pdf_document = PDF_DOCUMENT (document_images);
poppler_page = POPPLER_PAGE (page->backend_page);
mapping_list = poppler_page_get_image_mapping (poppler_page);
@@ -1591,7 +1587,6 @@ pdf_document_file_exporter_begin (EvFileExporter *exporter,
PdfDocument *pdf_document = PDF_DOCUMENT (exporter);
PdfPrintContext *ctx;
#ifdef HAVE_CAIRO_PRINT
- gdouble width, height;
cairo_surface_t *surface = NULL;
#endif
@@ -1855,8 +1850,6 @@ pdf_document_print_print_page (EvDocumentPrint *document,
EvPage *page,
cairo_t *cr)
{
- PdfDocument *pdf_document = PDF_DOCUMENT (document);
-
poppler_page_render_for_printing (POPPLER_PAGE (page->backend_page), cr);
}
@@ -2110,6 +2103,7 @@ pdf_document_page_transition_iface_init (EvDocumentTransitionInterface *iface)
}
/* Forms */
+#if 0
static void
pdf_document_get_crop_box (EvDocument *document,
int page,
@@ -2127,6 +2121,7 @@ pdf_document_get_crop_box (EvDocument *document,
rect->y1 = poppler_rect.y1;
rect->y2 = poppler_rect.y2;
}
+#endif
static EvFormField *
ev_form_field_from_poppler_field (PopplerFormField *poppler_field)
@@ -2599,7 +2594,6 @@ ev_annot_from_poppler_annot (PopplerAnnot *poppler_annot,
break;
case POPPLER_ANNOT_FILE_ATTACHMENT: {
PopplerAnnotFileAttachment *poppler_annot_attachment;
- EvAnnotationAttachment *ev_annot_attachment;
PopplerAttachment *poppler_attachment;
gchar *data = NULL;
gsize size;
@@ -2830,8 +2824,6 @@ pdf_document_annotations_add_annotation (EvDocumentAnnotations *document_annotat
gdouble height;
PopplerColor poppler_color;
GdkColor color;
- time_t utime;
- gchar *modified;
gchar *name;
pdf_document = PDF_DOCUMENT (document_annotations);
@@ -3203,7 +3195,6 @@ static void
pdf_document_layers_show_layer (EvDocumentLayers *document,
EvLayer *layer)
{
- PdfDocument *pdf_document = PDF_DOCUMENT (document);
PopplerLayer *poppler_layer;
poppler_layer = POPPLER_LAYER (g_object_get_data (G_OBJECT (layer), "poppler-layer"));
@@ -3214,7 +3205,6 @@ static void
pdf_document_layers_hide_layer (EvDocumentLayers *document,
EvLayer *layer)
{
- PdfDocument *pdf_document = PDF_DOCUMENT (document);
PopplerLayer *poppler_layer;
poppler_layer = POPPLER_LAYER (g_object_get_data (G_OBJECT (layer), "poppler-layer"));
@@ -3225,7 +3215,6 @@ static gboolean
pdf_document_layers_layer_is_visible (EvDocumentLayers *document,
EvLayer *layer)
{
- PdfDocument *pdf_document = PDF_DOCUMENT (document);
PopplerLayer *poppler_layer;
poppler_layer = POPPLER_LAYER (g_object_get_data (G_OBJECT (layer), "poppler-layer"));
diff --git a/backend/xps/xps-document.c b/backend/xps/xps-document.c
index fc3c15c3..53073e42 100644
--- a/backend/xps/xps-document.c
+++ b/backend/xps/xps-document.c
@@ -424,7 +424,6 @@ xps_document_links_get_links (EvDocumentLinks *document_links,
ev_link_mapping = g_new (EvMapping, 1);
gxps_link_get_area (xps_link, &area);
target = gxps_link_get_target (xps_link);
- gxps_link_get_area (xps_link, &area);
ev_link_mapping->data = ev_link_from_target (xps_document, target);
ev_link_mapping->area.x1 = area.x;
diff --git a/libview/ev-view.h b/libview/ev-view.h
index 0a9e1718..0a9e1718 100755..100644
--- a/libview/ev-view.h
+++ b/libview/ev-view.h