~ubuntu-branches/ubuntu/precise/telepathy-mission-control-5/precise

« back to all changes in this revision

Viewing changes to mission-control-plugins/request-policy.h

Tags: upstream-5.5.2
ImportĀ upstreamĀ versionĀ 5.5.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* Mission Control plugin API - ChannelRequest policy hook.
 
2
 *
 
3
 * Copyright (C) 2009 Nokia Corporation
 
4
 * Copyright (C) 2009 Collabora Ltd.
 
5
 *
 
6
 * This library is free software; you can redistribute it and/or
 
7
 * modify it under the terms of the GNU Lesser General Public
 
8
 * License as published by the Free Software Foundation; either
 
9
 * version 2.1 of the License, or (at your option) any later version.
 
10
 *
 
11
 * This library is distributed in the hope that it will be useful,
 
12
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
13
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
14
 * Lesser General Public License for more details.
 
15
 *
 
16
 * You should have received a copy of the GNU Lesser General Public
 
17
 * License along with this library; if not, write to the Free Software
 
18
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 
19
 */
 
20
 
 
21
#ifndef MCP_REQUEST_POLICY_H
 
22
#define MCP_REQUEST_POLICY_H
 
23
 
 
24
#ifndef _MCP_IN_MISSION_CONTROL_PLUGINS_H
 
25
#error Use <mission-control-plugins/mission-control-plugins.h> instead
 
26
#endif
 
27
 
 
28
#include <mission-control-plugins/request.h>
 
29
 
 
30
G_BEGIN_DECLS
 
31
 
 
32
/* API for plugins to implement */
 
33
 
 
34
typedef struct _McpRequestPolicy McpRequestPolicy;
 
35
typedef struct _McpRequestPolicyIface McpRequestPolicyIface;
 
36
 
 
37
#define MCP_TYPE_REQUEST_POLICY \
 
38
  (mcp_request_policy_get_type ())
 
39
#define MCP_REQUEST_POLICY(o) \
 
40
  (G_TYPE_CHECK_INSTANCE_CAST ((o), MCP_TYPE_REQUEST_POLICY, McpRequestPolicy))
 
41
#define MCP_IS_REQUEST_POLICY(o) \
 
42
  (G_TYPE_CHECK_INSTANCE_TYPE ((o), MCP_TYPE_REQUEST_POLICY))
 
43
#define MCP_REQUEST_POLICY_GET_IFACE(o) \
 
44
  (G_TYPE_INSTANCE_GET_INTERFACE ((o), MCP_TYPE_REQUEST_POLICY, \
 
45
                                  McpRequestPolicyIface))
 
46
 
 
47
GType mcp_request_policy_get_type (void) G_GNUC_CONST;
 
48
 
 
49
/* virtual methods */
 
50
void mcp_request_policy_check (McpRequestPolicy *policy, McpRequest *request);
 
51
 
 
52
/* vtable manipulation - the vtable is private to allow for expansion */
 
53
void mcp_request_policy_iface_implement_check (McpRequestPolicyIface *iface,
 
54
    void (*impl) (McpRequestPolicy *, McpRequest *));
 
55
 
 
56
G_END_DECLS
 
57
 
 
58
#endif