ibus-daemon: Move global variables into separated files.

This commit is contained in:
Peng Huang 2012-01-11 20:41:16 -05:00
Родитель 05af2cf443
Коммит ab6b68c2d2
2 изменённых файлов: 77 добавлений и 0 удалений

35
bus/global.c Normal file
Просмотреть файл

@ -0,0 +1,35 @@
/* -*- mode: C; c-basic-offset: 4; indent-tabs-mode: nil; -*- */
/* vim:set et sts=4: */
/* ibus - The Input Bus
* Copyright (C) 2008-2010 Peng Huang <shawn.p.huang@gmail.com>
* Copyright (C) 2008-2010 Red Hat, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#include "global.h"
gchar **g_argv = NULL;
gchar *g_address = "unix:tmpdir=/tmp";
gchar *g_cache = "auto";
gboolean g_mempro = FALSE;
gboolean g_verbose = FALSE;
gint g_gdbus_timeout = 5000;
#ifdef G_THREADS_ENABLED
gint g_monitor_timeout = 0;
#endif

42
bus/global.h Normal file
Просмотреть файл

@ -0,0 +1,42 @@
/* vim:set et sts=4: */
/* ibus - The Input Bus
* Copyright (C) 2008-2010 Peng Huang <shawn.p.huang@gmail.com>
* Copyright (C) 2008-2010 Red Hat, Inc.
* Copyright (c) 2010 Google, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library 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
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the
* Free Software Foundation, Inc., 59 Temple Place - Suite 330,
* Boston, MA 02111-1307, USA.
*/
#ifndef __BUS_GLOBAL_H_
#define __BUS_GLOBAL_H_
#include <glib.h>
G_BEGIN_DECLS
extern gchar **g_argv;
extern gchar *g_address;
extern gchar *g_cache;
extern gboolean g_mempro;
extern gboolean g_verbose;
extern gint g_gdbus_timeout;
#ifdef G_THREADS_ENABLED
extern gint g_monitor_timeout;
#endif
G_END_DECLS
#endif