diff --git a/toys/mug/Makefile.am b/toys/mug/Makefile.am index dbda9666..e0b6881b 100644 --- a/toys/mug/Makefile.am +++ b/toys/mug/Makefile.am @@ -1,4 +1,4 @@ -## Copyright (C) 2008-2013 Dirk-Jan C. Binnema +## Copyright (C) 2008-2017 Dirk-Jan C. Binnema ## ## This program is free software; you can redistribute it and/or modify ## it under the terms of the GNU General Public License as published by @@ -19,8 +19,8 @@ include $(top_srcdir)/gtest.mk # enforce compiling this dir first before decending into tests/ SUBDIRS= . -AM_CPPFLAGS=-I${top_srcdir} -I${top_srcdir}/lib $(GTK_CFLAGS) $(WEBKIT_CFLAGS) \ - -DICONDIR='"$(icondir)"' -DMUGDIR='"$(abs_srcdir)"' \ +AM_CPPFLAGS=-I${top_srcdir} -I${top_srcdir}/lib $(GTK_CFLAGS) $(WEBKIT_CFLAGS) \ + -DICONDIR='"$(icondir)"' -DMUGDIR='"$(abs_srcdir)"' \ -DGSEAL_ENABLE # remove -DGTK_DISABLE_DEPRECATED for now, since it breaks 3.10+ compilation @@ -28,63 +28,66 @@ AM_CPPFLAGS=-I${top_srcdir} -I${top_srcdir}/lib $(GTK_CFLAGS) $(WEBKIT_CFLAGS) \ # don't use -Werror, as it might break on other compilers # use -Wno-unused-parameters, because some callbacks may not # really need all the params they get -AM_CFLAGS=-Wall -Wextra -Wno-unused-parameter -Wdeclaration-after-statement -AM_CXXFLAGS=-Wall -Wextra -Wno-unused-parameter +AM_CFLAGS= \ + $(WARN_CFLAGS) \ + -Wno-redundant-decls \ + -Wno-deprecated-declarations \ + -Wno-switch-enum -noinst_PROGRAMS= \ +AM_CXXFLAGS=$(WARN_CXXFLAGS) + +noinst_PROGRAMS= \ mug # note, mug.cc is '.cc' only because libmu must explicitly # be linked as c++, not c. -mug_SOURCES= \ - mug.c \ - mug-msg-list-view.c \ - mug-msg-list-view.h \ - mug-msg-view.h \ - mug-msg-view.c \ - mug-query-bar.h \ - mug-query-bar.c \ - mug-shortcuts.c \ - mug-shortcuts.h \ +mug_SOURCES= \ + mug.c \ + mug-msg-list-view.c \ + mug-msg-list-view.h \ + mug-msg-view.h \ + mug-msg-view.c \ + mug-query-bar.h \ + mug-query-bar.c \ + mug-shortcuts.c \ + mug-shortcuts.h \ dummy.cc # we need to use dummy.cc to enforce c++ linking... -BUILT_SOURCES= \ +BUILT_SOURCES= \ dummy.cc dummy.cc: touch dummy.cc -DISTCLEANFILES= \ +DISTCLEANFILES= \ $(BUILT_SOURCES) - -mug_LDADD= \ - ${top_builddir}/lib/libmu.la \ - libmuwidgets.la \ +mug_LDADD= \ + ${top_builddir}/lib/libmu.la \ + libmuwidgets.la \ ${GTK_LIBS} - -noinst_LTLIBRARIES= \ +noinst_LTLIBRARIES= \ libmuwidgets.la -libmuwidgets_la_SOURCES= \ - mu-widget-util.h \ - mu-widget-util.c \ - mu-msg-attach-view.c \ - mu-msg-attach-view.h \ - mu-msg-body-view.c \ - mu-msg-body-view.h \ - mu-msg-header-view.c \ - mu-msg-header-view.h \ - mu-msg-view.h \ +libmuwidgets_la_SOURCES= \ + mu-widget-util.h \ + mu-widget-util.c \ + mu-msg-attach-view.c \ + mu-msg-attach-view.h \ + mu-msg-body-view.c \ + mu-msg-body-view.h \ + mu-msg-header-view.c \ + mu-msg-header-view.h \ + mu-msg-view.h \ mu-msg-view.c -libmuwidgets_la_LIBADD= \ - ${top_builddir}/lib/libmu.la \ - ${GTK_LIBS} \ - ${WEBKIT_LIBS} \ +libmuwidgets_la_LIBADD= \ + ${top_builddir}/lib/libmu.la \ + ${GTK_LIBS} \ + ${WEBKIT_LIBS} \ ${GIO_LIBS} -EXTRA_DIST= \ +EXTRA_DIST= \ mug.svg diff --git a/toys/mug/mu-msg-body-view.c b/toys/mug/mu-msg-body-view.c index 43b26f88..c98fa9af 100644 --- a/toys/mug/mu-msg-body-view.c +++ b/toys/mug/mu-msg-body-view.c @@ -1,5 +1,5 @@ /* -** Copyright (C) 2011-2013 Dirk-Jan C. Binnema +** Copyright (C) 2011-2017 Dirk-Jan C. Binnema ** ** This program is free software; you can redistribute it and/or modify it ** under the terms of the GNU General Public License as published by the @@ -51,8 +51,8 @@ struct _MuMsgBodyViewPrivate { ViewMode _view_mode; }; #define MU_MSG_BODY_VIEW_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE((o), \ - MU_TYPE_MSG_BODY_VIEW, \ - MuMsgBodyViewPrivate)) + MU_TYPE_MSG_BODY_VIEW, \ + MuMsgBodyViewPrivate)) /* globals */ static WebKitWebViewClass *parent_class = NULL; @@ -319,7 +319,7 @@ mu_msg_body_view_new (void) } -void +static void set_html (MuMsgBodyView *self, const char* html) { g_return_if_fail (MU_IS_MSG_BODY_VIEW(self)); diff --git a/toys/mug/mu-msg-header-view.c b/toys/mug/mu-msg-header-view.c index c23c767f..028b93b9 100644 --- a/toys/mug/mu-msg-header-view.c +++ b/toys/mug/mu-msg-header-view.c @@ -42,8 +42,8 @@ struct _MuMsgHeaderViewPrivate { GtkWidget *_grid; }; #define MU_MSG_HEADER_VIEW_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE((o), \ - MU_TYPE_MSG_HEADER_VIEW, \ - MuMsgHeaderViewPrivate)) + MU_TYPE_MSG_HEADER_VIEW, \ + MuMsgHeaderViewPrivate)) /* globals */ static GtkBoxClass *parent_class = NULL; @@ -142,7 +142,7 @@ add_row (GtkWidget *grid, guint row, const char* fieldname, const char *value, } -GtkWidget * +static GtkWidget* get_grid (MuMsg *msg) { GtkWidget *grid; diff --git a/toys/mug/mug.c b/toys/mug/mug.c index 6903b714..c6b15052 100644 --- a/toys/mug/mug.c +++ b/toys/mug/mug.c @@ -1,5 +1,5 @@ /* -** Copyright (C) 2010-2013 Dirk-Jan C. Binnema +** Copyright (C) 2010-2017 Dirk-Jan C. Binnema ** ** This program is free software; you can redistribute it and/or modify it ** under the terms of the GNU General Public License as published by the @@ -110,7 +110,7 @@ tool_button (const char *name) icon = gtk_image_new_from_icon_name (name, GTK_ICON_SIZE_SMALL_TOOLBAR); - + return gtk_menu_tool_button_new (icon, NULL); } @@ -331,8 +331,8 @@ mug_main_area (MugData * mugdata) return mainarea; } -GtkWidget * -mug_shell (MugData * mugdata) +static GtkWidget* +mug_shell (MugData *mugdata) { GtkWidget *vbox;