Commit 8762e136 authored by Tristan Matthews's avatar Tristan Matthews

refactor some code out of sflphone_const.h

parent 8855870a
......@@ -32,7 +32,7 @@ sflphone_client_gnome_SOURCES = \
noinst_HEADERS = actions.h sflnotify.h mainwindow.h dialpad.h codeclist.h \
reqaccount.h sflphone_const.h uimanager.h \
accountlist.h sliders.h statusicon.h callable_obj.h conference_obj.h \
shortcuts.h eel-gconf-extensions.h logger.h imwindow.h
shortcuts.h eel-gconf-extensions.h logger.h imwindow.h unused.h
sflphone_client_gnome_LDADD = $(DBUSGLIB_LIBS) $(LIBNOTIFY_LIBS) $(NOTIFY_LIBS) $(SFLPHONEGTK_LIBS) $(X11_LIBS) \
$(GTK_LIBS) $(GLIB_LIBS) $(WEBKIT_LIBS) $(LIBGNOMEUI_LIBS) $(GNOMEDOCUTILS_LIBS) $(LD_LIBS)
......
......@@ -29,8 +29,9 @@
* as that of the covered work.
*/
#include <accountlist.h>
#include <actions.h>
#include "accountlist.h"
#include "actions.h"
#include "unused.h"
static GQueue * accountQueue;
......
......@@ -50,6 +50,7 @@
#include "audioconf.h"
#include "dbus/dbus.h"
#include "utils.h"
#include "unused.h"
/**
* TODO: tidy this up
......
......@@ -36,6 +36,7 @@
#include "actions.h"
#include "mainwindow.h"
#include "utils.h"
#include "unused.h"
#include "logger.h"
#include <string.h>
#include <libgnome/gnome-help.h>
......
......@@ -30,6 +30,7 @@
#include "addressbook-config.h"
#include "dbus.h"
#include "unused.h"
#include "logger.h"
#include "searchbar.h"
#include "contacts/addrbookfactory.h"
......
......@@ -30,6 +30,7 @@
#include <string.h>
#include "unused.h"
#include "assistant.h"
#include "logger.h"
#include "dbus.h"
......
......@@ -36,6 +36,7 @@
#include "dbus/dbus.h"
#include "uimanager.h"
#include "mainwindow.h"
#include "unused.h"
/* FIXME: these should be in a struct rather than at file scope */
static GtkListStore *pluginlist;
......
......@@ -48,6 +48,7 @@
#include "hooks-config.h"
#include "audioconf.h"
#include "uimanager.h"
#include "unused.h"
#include "mainwindow.h"
/**
......
......@@ -30,6 +30,7 @@
#include "shortcuts-config.h"
#include "shortcuts.h"
#include "unused.h"
#include "logger.h"
#include <gdk/gdkx.h>
......
......@@ -31,8 +31,8 @@
#include "calllist.h"
#include "calltab.h"
#include "calltree.h"
#include "unused.h"
#include "logger.h"
#include "contacts/searchbar.h"
#include "eel-gconf-extensions.h"
static
......
......@@ -36,6 +36,7 @@
#include <glib/gprintf.h>
#include "eel-gconf-extensions.h"
#include "unused.h"
#include "dbus.h"
#include "calltab.h"
#include "logger.h"
......
......@@ -28,10 +28,11 @@
* as that of the covered work.
*/
#include <history.h>
#include <string.h>
#include <searchbar.h>
#include <calltab.h>
#include "history.h"
#include "searchbar.h"
#include "calltab.h"
#include "unused.h"
static GtkTreeModel *history_filter;
static GtkEntry *history_searchbar_widget;
......
......@@ -36,6 +36,7 @@
#include "calltab.h"
#include "dbus.h"
#include "logger.h"
#include "unused.h"
#include "config/addressbook-config.h"
#include "contacts/addressbook.h"
#include "contacts/addrbookfactory.h"
......
......@@ -46,6 +46,7 @@
#include "dbus.h"
#include "actions.h"
#include "unused.h"
#include "widget/imwidget.h"
......
......@@ -31,6 +31,7 @@
#include "dialpad.h"
#include "actions.h"
#include "calltab.h"
#include "unused.h"
/**
* button pressed event
......
......@@ -32,6 +32,28 @@
#ifdef __cplusplus
BEGIN_EXTERN_C
#endif
/**
* Gconf
*/
#define CONF_PREFIX "/apps/sflphone-client-gnome"
#define CONF_MAIN_WINDOW_WIDTH CONF_PREFIX "/state/window_width"
#define CONF_MAIN_WINDOW_HEIGHT CONF_PREFIX "/state/window_height"
#define CONF_MAIN_WINDOW_POSITION_X CONF_PREFIX "/state/window_position_x"
#define CONF_MAIN_WINDOW_POSITION_Y CONF_PREFIX "/state/window_position_y"
#define CONF_IM_WINDOW_WIDTH CONF_PREFIX "/state/im_width"
#define CONF_IM_WINDOW_HEIGHT CONF_PREFIX "/state/im_height"
#define CONF_IM_WINDOW_POSITION_X CONF_PREFIX "/state/im_position_x"
#define CONF_IM_WINDOW_POSITION_Y CONF_PREFIX "/state/im_position_y"
/** Show/Hide the dialpad */
#define CONF_SHOW_DIALPAD CONF_PREFIX "/state/dialpad"
#define SHOW_VOLUME_CONTROLS CONF_PREFIX "/state/volume_controls"
#define SHOW_STATUSICON CONF_PREFIX "/state/statusicon"
#define NOTIFY_ALL CONF_PREFIX "/state/notify_all"
#define START_HIDDEN CONF_PREFIX "/state/start_hidden"
#define POPUP_ON_CALL CONF_PREFIX "/state/popup"
#define HISTORY_ENABLED CONF_PREFIX "/state/history"
#define INSTANT_MESSAGING_ENABLED CONF_PREFIX "/state/instant_messaging"
#define EEL_GCONF_UNDEFINED_CONNECTION 0
......
......@@ -32,11 +32,12 @@
#include "config.h"
#include "eel-gconf-extensions.h"
#include "sflphone_const.h"
#include "logger.h"
#include "imwindow.h"
#include "unused.h"
#include "contacts/calltab.h"
#include "contacts/calltab.h"
#include "sflphone_const.h"
#include <sys/stat.h>
/** Local variables */
......
......@@ -46,6 +46,7 @@
#include "widget/gtkscrollbook.h"
#include "widget/minidialog.h"
#include "uimanager.h"
#include "unused.h"
#include "config/audioconf.h"
#include <sys/stat.h>
......
......@@ -55,11 +55,6 @@
#define IP2IP "IP2IP"
/** Warnings unused variables **/
#define UNUSED_VAR(var) (void*)var
#define UNUSED __attribute__((__unused__))
#define IP2IP_PROFILE "IP2IP"
#define ACCOUNT_ID "Account.id"
......@@ -170,26 +165,4 @@
/** Desktop notifications - Time before to close the notification*/
#define __TIMEOUT_TIME 18000 // 30 secondes
/**
* Gconf
*/
#define CONF_PREFIX "/apps/sflphone-client-gnome"
#define CONF_MAIN_WINDOW_WIDTH CONF_PREFIX "/state/window_width"
#define CONF_MAIN_WINDOW_HEIGHT CONF_PREFIX "/state/window_height"
#define CONF_MAIN_WINDOW_POSITION_X CONF_PREFIX "/state/window_position_x"
#define CONF_MAIN_WINDOW_POSITION_Y CONF_PREFIX "/state/window_position_y"
#define CONF_IM_WINDOW_WIDTH CONF_PREFIX "/state/im_width"
#define CONF_IM_WINDOW_HEIGHT CONF_PREFIX "/state/im_height"
#define CONF_IM_WINDOW_POSITION_X CONF_PREFIX "/state/im_position_x"
#define CONF_IM_WINDOW_POSITION_Y CONF_PREFIX "/state/im_position_y"
/** Show/Hide the dialpad */
#define CONF_SHOW_DIALPAD CONF_PREFIX "/state/dialpad"
#define SHOW_VOLUME_CONTROLS CONF_PREFIX "/state/volume_controls"
#define SHOW_STATUSICON CONF_PREFIX "/state/statusicon"
#define NOTIFY_ALL CONF_PREFIX "/state/notify_all"
#define START_HIDDEN CONF_PREFIX "/state/start_hidden"
#define POPUP_ON_CALL CONF_PREFIX "/state/popup"
#define HISTORY_ENABLED CONF_PREFIX "/state/history"
#define INSTANT_MESSAGING_ENABLED CONF_PREFIX "/state/instant_messaging"
#endif
......@@ -46,6 +46,7 @@
#include "sflphone_const.h"
#include "dbus.h"
#include "actions.h"
#include "unused.h"
static void
ungrab_key(guint key, GdkModifierType mask, const GdkWindow *root);
......
......@@ -36,6 +36,7 @@
#include "statusicon.h"
#include "eel-gconf-extensions.h"
#include "logger.h"
#include "unused.h"
static GtkStatusIcon *status;
static GtkWidget *show_menu_item, *hangup_menu_item;
......
......@@ -45,6 +45,7 @@
#include "eel-gconf-extensions.h"
#include "config/audioconf.h"
#include "unused.h"
#include "uimanager.h"
#include "statusicon.h"
......
/*
* Copyright (C) 2004, 2005, 2006, 2008, 2009, 2010, 2011 Savoir-Faire Linux Inc.
* Author: Tristan Matthews <tristan.matthews@savoirfairelinux.com>
*
* 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 Free Software Foundation; either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*
* Additional permission under GNU GPL version 3 section 7:
*
* If you modify this program, or any covered work, by linking or
* combining it with the OpenSSL project's OpenSSL library (or a
* modified version of that library), containing parts covered by the
* terms of the OpenSSL or SSLeay licenses, Savoir-Faire Linux Inc.
* grants you additional permission to convey the resulting work.
* Corresponding Source for a non-source form of such a combination
* shall include the source code for the parts of OpenSSL used as well
* as that of the covered work.
*/
#ifndef UNUSED_H_
#define UNUSED __attribute__((__unused__))
#endif /* UNUSED_H_ */
......@@ -25,6 +25,7 @@
*/
#include "gtkscrollbook.h"
#include "unused.h"
#include "sflphone_const.h"
static void pidgin_scroll_book_init(PidginScrollBook *scroll_book);
......
......@@ -31,13 +31,13 @@
#include "logger.h"
#include "imwidget.h"
#include "dbus.h"
#include "unused.h"
#include "icons/icon_factory.h"
#include "contacts/calltab.h"
#include "contacts/conferencelist.h"
#include <JavaScriptCore/JavaScript.h>
#include <gdk/gdkkeysyms.h>
#include <gtk/gtk.h>
#include "sflphone_const.h"
#define WEBKIT_DIR "file://" DATA_DIR "/webkit/"
......
......@@ -24,6 +24,7 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
*/
#include <gtk/gtk.h>
#include "unused.h"
#include "sflphone_const.h"
#include "minidialog.h"
......
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