~muktupavels/compiz/gwd-improve-metacity

« back to all changes in this revision

Viewing changes to include/core/actionbindings.h

  • Committer: smspillaz
  • Date: 2012-01-24 08:24:18 UTC
  • Revision ID: sam.spilsbury@canonical.com-20120124082418-mzu4mtmrgvsupbm4
Revert things accidentally pushed to lp:compiz-core

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/*
2
 
 * Copyright © 2005 Novell, Inc.
3
 
 *
4
 
 * Permission to use, copy, modify, distribute, and sell this software
5
 
 * and its documentation for any purpose is hereby granted without
6
 
 * fee, provided that the above copyright notice appear in all copies
7
 
 * and that both that copyright notice and this permission notice
8
 
 * appear in supporting documentation, and that the name of
9
 
 * Novell, Inc. not be used in advertising or publicity pertaining to
10
 
 * distribution of the software without specific, written prior permission.
11
 
 * Novell, Inc. makes no representations about the suitability of this
12
 
 * software for any purpose. It is provided "as is" without express or
13
 
 * implied warranty.
14
 
 *
15
 
 * NOVELL, INC. DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
16
 
 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
17
 
 * NO EVENT SHALL NOVELL, INC. BE LIABLE FOR ANY SPECIAL, INDIRECT OR
18
 
 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
19
 
 * OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
20
 
 * NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION
21
 
 * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
22
 
 *
23
 
 * Author: David Reveman <davidr@novell.com>
24
 
 */
25
 
 
26
 
#ifndef _COMPIZ_ACTIONBINDINGS_H
27
 
#define _COMPIZ_ACTIONBINDINGS_H
28
 
 
29
 
#include <boost/noncopyable.hpp>
30
 
 
31
 
class CompAction;
32
 
 
33
 
namespace compiz
34
 
{
35
 
namespace actions
36
 
{
37
 
 
38
 
class ActionBindingsInterface :
39
 
    boost::noncopyable
40
 
{
41
 
    public:
42
 
 
43
 
        virtual ~ActionBindingsInterface () = 0;
44
 
 
45
 
        bool addAction (CompAction *a) { return registerAction (a); }
46
 
        void removeAction (CompAction *a) { return unregisterAction (a); }
47
 
 
48
 
        static ActionBindingsInterface *
49
 
        Default ();
50
 
 
51
 
        static void
52
 
        SetDefault (ActionBindingsInterface *def);
53
 
 
54
 
    protected:
55
 
 
56
 
        ActionBindingsInterface ();
57
 
 
58
 
        virtual bool registerAction (CompAction *) = 0;
59
 
        virtual void unregisterAction (CompAction *) = 0;
60
 
 
61
 
};
62
 
} // namespace actions
63
 
} // namespace compiz
64
 
 
65
 
#endif
66
 
 
67