~ubuntu-branches/ubuntu/trusty/gnome-control-center/trusty-proposed

« back to all changes in this revision

Viewing changes to panels/region/cc-region-keyboard-item.h

  • Committer: Package Import Robot
  • Author(s): Sebastien Bacher, Brian Murray
  • Date: 2014-02-26 19:21:03 UTC
  • Revision ID: package-import@ubuntu.com-20140226192103-eem23maw14t3w0jj
Tags: 1:3.6.3-0ubuntu52
* debian/patches/gcc_not_in_unity.patch:
  - don't list "Unity" in OnlyShowIn, other g-c-c and u-c-c entries get 
    duplicated in the Unity dash, when they both installed (lp: #1280872)
* debian/libgnome-control-center1.symbols,
  debian/patches/10_keyboard_layout_on_unity.patch,
  debian/patches/input-sources-text-entry.patch,
  debian/patches/sound_nua_panel.patch,
  debian/patches/unity_menus.patch,
  debian/patches/unity_notice_info.patch:
  - dropped some unity specific changes

[ Brian Murray ]
* debian/source_gnome-control-center.py: Do not pass an empty list
  of plugin packages to apport. (LP: #1237119)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* -*- Mode: C; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 8 -*-
2
 
 *
3
 
 * Copyright (C) 2011 Red Hat, Inc.
4
 
 *
5
 
 * This program is free software; you can redistribute it and/or modify
6
 
 * it under the terms of the GNU General Public License as published by
7
 
 * the Free Software Foundation; either version 2 of the License, or
8
 
 * (at your option) any later version.
9
 
 *
10
 
 * This program is distributed in the hope that it will be useful,
11
 
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
 
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13
 
 * GNU General Public License for more details.
14
 
 *
15
 
 * You should have received a copy of the GNU General Public License
16
 
 * along with this program; if not, write to the Free Software
17
 
 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
18
 
 *
19
 
 */
20
 
 
21
 
#ifndef __CC_REGION_KEYBOARD_ITEM_H
22
 
#define __CC_REGION_KEYBOARD_ITEM_H
23
 
 
24
 
#include <glib-object.h>
25
 
 
26
 
G_BEGIN_DECLS
27
 
 
28
 
#define CC_TYPE_REGION_KEYBOARD_ITEM         (cc_region_keyboard_item_get_type ())
29
 
#define CC_REGION_KEYBOARD_ITEM(o)           (G_TYPE_CHECK_INSTANCE_CAST ((o), CC_TYPE_REGION_KEYBOARD_ITEM, CcRegionKeyboardItem))
30
 
#define CC_REGION_KEYBOARD_ITEM_CLASS(k)     (G_TYPE_CHECK_CLASS_CAST((k), CC_TYPE_REGION_KEYBOARD_ITEM, CcRegionKeyboardItemClass))
31
 
#define CC_IS_REGION_KEYBOARD_ITEM(o)        (G_TYPE_CHECK_INSTANCE_TYPE ((o), CC_TYPE_REGION_KEYBOARD_ITEM))
32
 
#define CC_IS_REGION_KEYBOARD_ITEM_CLASS(k)  (G_TYPE_CHECK_CLASS_TYPE ((k), CC_TYPE_REGION_KEYBOARD_ITEM))
33
 
#define CC_REGION_KEYBOARD_ITEM_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), CC_TYPE_REGION_KEYBOARD_ITEM, CcRegionKeyboardItemClass))
34
 
 
35
 
typedef enum
36
 
{
37
 
  BINDING_GROUP_SYSTEM,
38
 
  BINDING_GROUP_APPS,
39
 
  BINDING_GROUP_SEPARATOR,
40
 
  BINDING_GROUP_USER,
41
 
} BindingGroupType;
42
 
 
43
 
typedef enum {
44
 
        CC_REGION_KEYBOARD_ITEM_TYPE_NONE = 0,
45
 
        CC_REGION_KEYBOARD_ITEM_TYPE_GSETTINGS_PATH,
46
 
        CC_REGION_KEYBOARD_ITEM_TYPE_GSETTINGS
47
 
} CcRegionKeyboardItemType;
48
 
 
49
 
typedef struct CcRegionKeyboardItemPrivate CcRegionKeyboardItemPrivate;
50
 
 
51
 
typedef struct
52
 
{
53
 
  GObject                parent;
54
 
  CcRegionKeyboardItemPrivate *priv;
55
 
 
56
 
  /* Move to priv */
57
 
  CcRegionKeyboardItemType type;
58
 
 
59
 
  /* common */
60
 
  /* FIXME move to priv? */
61
 
  guint keyval;
62
 
  guint keycode;
63
 
  GdkModifierType mask;
64
 
  BindingGroupType group;
65
 
  GtkTreeModel *model;
66
 
  char *description;
67
 
  char *gettext_package;
68
 
  char *binding;
69
 
  gboolean editable;
70
 
 
71
 
  /* GSettings path */
72
 
  char *gsettings_path;
73
 
  gboolean desc_editable;
74
 
  char *command;
75
 
  gboolean cmd_editable;
76
 
 
77
 
  /* GSettings */
78
 
  char *schema;
79
 
  char *key;
80
 
  GSettings *settings;
81
 
} CcRegionKeyboardItem;
82
 
 
83
 
typedef struct
84
 
{
85
 
  GObjectClass   parent_class;
86
 
} CcRegionKeyboardItemClass;
87
 
 
88
 
GType                  cc_region_keyboard_item_get_type                 (void);
89
 
 
90
 
CcRegionKeyboardItem * cc_region_keyboard_item_new                      (CcRegionKeyboardItemType  type);
91
 
gboolean               cc_region_keyboard_item_load_from_gsettings_path (CcRegionKeyboardItem     *item,
92
 
                                                                         const char               *path,
93
 
                                                                         gboolean                  reset);
94
 
gboolean               cc_region_keyboard_item_load_from_gsettings      (CcRegionKeyboardItem     *item,
95
 
                                                                         const char               *description,
96
 
                                                                         const char               *schema,
97
 
                                                                         const char               *key);
98
 
 
99
 
const char *           cc_region_keyboard_item_get_description          (CcRegionKeyboardItem     *item);
100
 
const char *           cc_region_keyboard_item_get_binding              (CcRegionKeyboardItem     *item);
101
 
const char *           cc_region_keyboard_item_get_command              (CcRegionKeyboardItem     *item);
102
 
 
103
 
gboolean               cc_region_keyboard_item_equal                    (CcRegionKeyboardItem     *a,
104
 
                                                                         CcRegionKeyboardItem     *b);
105
 
 
106
 
G_END_DECLS
107
 
 
108
 
#endif /* __CC_REGION_KEYBOARD_ITEM_H */