~ubuntu-branches/ubuntu/saucy/qt-gstreamer/saucy-proposed

« back to all changes in this revision

Viewing changes to src/QGlib/gen.cpp

  • Committer: Package Import Robot
  • Author(s): Felix Geyer
  • Date: 2012-06-15 15:03:26 UTC
  • mfrom: (1.1.5 sid)
  • Revision ID: package-import@ubuntu.com-20120615150326-pkmdog620pkytcgt
Tags: 0.10.2-2ubuntu1
* Merge from Debian unstable, remaining changes:
  - Enable unit tests.
    + Build-depend on gstreamer0.10-plugins-base.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
// Autogenerated by the QtGStreamer helper code generator - DO NOT EDIT
 
2
/*
 
3
    Copyright (C) 2010 George Kiagiadakis <kiagiadakis.george@gmail.com>
 
4
    Copyright (C) 2010 Collabora Ltd.
 
5
      @author George Kiagiadakis <george.kiagiadakis@collabora.co.uk>
 
6
 
 
7
    This library is free software; you can redistribute it and/or modify
 
8
    it under the terms of the GNU Lesser General Public License as published
 
9
    by the Free Software Foundation; either version 2.1 of the License, or
 
10
    (at your option) any later version.
 
11
 
 
12
    This program is distributed in the hope that it will be useful,
 
13
    but WITHOUT ANY WARRANTY; without even the implied warranty of
 
14
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
15
    GNU Lesser General Public License for more details.
 
16
 
 
17
    You should have received a copy of the GNU Lesser General Public License
 
18
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
19
*/
 
20
 
 
21
#define INCLUDED_FROM_CODEGEN
 
22
#include <boost/static_assert.hpp>
 
23
 
 
24
#define REGISTER_TYPE_IMPLEMENTATION(T, GTYPE) \
 
25
    namespace QGlib { \
 
26
        GetTypeImpl<T>::operator Type() { return (GTYPE); } \
 
27
    }
 
28
 
 
29
#include <glib-object.h>
 
30
#include "QGlib/init.h"
 
31
 
 
32
#include "QGlib/signal.h"
 
33
 
 
34
namespace QGlib {
 
35
    BOOST_STATIC_ASSERT(static_cast<int>(Signal::RunFirst) == static_cast<int>(G_SIGNAL_RUN_FIRST));
 
36
    BOOST_STATIC_ASSERT(static_cast<int>(Signal::RunLast) == static_cast<int>(G_SIGNAL_RUN_LAST));
 
37
    BOOST_STATIC_ASSERT(static_cast<int>(Signal::RunCleanup) == static_cast<int>(G_SIGNAL_RUN_CLEANUP));
 
38
    BOOST_STATIC_ASSERT(static_cast<int>(Signal::NoRecurse) == static_cast<int>(G_SIGNAL_NO_RECURSE));
 
39
    BOOST_STATIC_ASSERT(static_cast<int>(Signal::Detailed) == static_cast<int>(G_SIGNAL_DETAILED));
 
40
    BOOST_STATIC_ASSERT(static_cast<int>(Signal::Action) == static_cast<int>(G_SIGNAL_ACTION));
 
41
    BOOST_STATIC_ASSERT(static_cast<int>(Signal::NoHooks) == static_cast<int>(G_SIGNAL_NO_HOOKS));
 
42
}
 
43
 
 
44
#include "QGlib/type.h"
 
45
 
 
46
REGISTER_TYPE_IMPLEMENTATION(QGlib::Type,G_TYPE_GTYPE)
 
47
 
 
48
namespace QGlib {
 
49
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Invalid) == static_cast<int>(G_TYPE_INVALID));
 
50
    BOOST_STATIC_ASSERT(static_cast<int>(Type::None) == static_cast<int>(G_TYPE_NONE));
 
51
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Interface) == static_cast<int>(G_TYPE_INTERFACE));
 
52
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Char) == static_cast<int>(G_TYPE_CHAR));
 
53
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Uchar) == static_cast<int>(G_TYPE_UCHAR));
 
54
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Boolean) == static_cast<int>(G_TYPE_BOOLEAN));
 
55
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Int) == static_cast<int>(G_TYPE_INT));
 
56
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Uint) == static_cast<int>(G_TYPE_UINT));
 
57
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Long) == static_cast<int>(G_TYPE_LONG));
 
58
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Ulong) == static_cast<int>(G_TYPE_ULONG));
 
59
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Int64) == static_cast<int>(G_TYPE_INT64));
 
60
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Uint64) == static_cast<int>(G_TYPE_UINT64));
 
61
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Enum) == static_cast<int>(G_TYPE_ENUM));
 
62
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Flags) == static_cast<int>(G_TYPE_FLAGS));
 
63
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Float) == static_cast<int>(G_TYPE_FLOAT));
 
64
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Double) == static_cast<int>(G_TYPE_DOUBLE));
 
65
    BOOST_STATIC_ASSERT(static_cast<int>(Type::String) == static_cast<int>(G_TYPE_STRING));
 
66
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Pointer) == static_cast<int>(G_TYPE_POINTER));
 
67
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Boxed) == static_cast<int>(G_TYPE_BOXED));
 
68
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Param) == static_cast<int>(G_TYPE_PARAM));
 
69
    BOOST_STATIC_ASSERT(static_cast<int>(Type::Object) == static_cast<int>(G_TYPE_OBJECT));
 
70
}
 
71
 
 
72
#include "QGlib/global.h"
 
73
 
 
74
#include "QGlib/refpointer.h"
 
75
 
 
76
#include "QGlib/string_p.h"
 
77
 
 
78
#include "QGlib/error.h"
 
79
 
 
80
#include "QGlib/object.h"
 
81
 
 
82
REGISTER_TYPE_IMPLEMENTATION(QGlib::Object,G_TYPE_OBJECT)
 
83
 
 
84
REGISTER_TYPE_IMPLEMENTATION(QGlib::Interface,G_TYPE_INTERFACE)
 
85
 
 
86
namespace QGlib {
 
87
  QGlib::RefCountedObject *Object_new(void *instance)
 
88
  {
 
89
    QGlib::Object *cppClass = new QGlib::Object;
 
90
    cppClass->m_object = instance;
 
91
    return cppClass;
 
92
  }
 
93
} //namespace QGlib
 
94
 
 
95
namespace QGlib {
 
96
  QGlib::RefCountedObject *Interface_new(void *instance)
 
97
  {
 
98
    QGlib::Interface *cppClass = new QGlib::Interface;
 
99
    cppClass->m_object = instance;
 
100
    return cppClass;
 
101
  }
 
102
} //namespace QGlib
 
103
 
 
104
#include "QGlib/value.h"
 
105
 
 
106
REGISTER_TYPE_IMPLEMENTATION(QGlib::Value,G_TYPE_VALUE)
 
107
 
 
108
#include "QGlib/connect.h"
 
109
 
 
110
 
 
111
#include "QGlib/quark.h"
 
112
 
 
113
#include "QGlib/wrap.h"
 
114
 
 
115
#include "QGlib/paramspec.h"
 
116
 
 
117
REGISTER_TYPE_IMPLEMENTATION(QGlib::ParamSpec,G_TYPE_PARAM)
 
118
 
 
119
REGISTER_TYPE_IMPLEMENTATION(QGlib::ParamSpec::ParamFlags,G_TYPE_PARAM_FLAGS)
 
120
 
 
121
namespace QGlib {
 
122
  QGlib::RefCountedObject *ParamSpec_new(void *instance)
 
123
  {
 
124
    QGlib::ParamSpec *cppClass = new QGlib::ParamSpec;
 
125
    cppClass->m_object = instance;
 
126
    return cppClass;
 
127
  }
 
128
} //namespace QGlib
 
129
 
 
130
namespace QGlib {
 
131
    BOOST_STATIC_ASSERT(static_cast<int>(ParamSpec::Readable) == static_cast<int>(G_PARAM_READABLE));
 
132
    BOOST_STATIC_ASSERT(static_cast<int>(ParamSpec::Writable) == static_cast<int>(G_PARAM_WRITABLE));
 
133
    BOOST_STATIC_ASSERT(static_cast<int>(ParamSpec::ReadWrite) == static_cast<int>(G_PARAM_READWRITE));
 
134
    BOOST_STATIC_ASSERT(static_cast<int>(ParamSpec::Construct) == static_cast<int>(G_PARAM_CONSTRUCT));
 
135
    BOOST_STATIC_ASSERT(static_cast<int>(ParamSpec::ConstructOnly) == static_cast<int>(G_PARAM_CONSTRUCT_ONLY));
 
136
    BOOST_STATIC_ASSERT(static_cast<int>(ParamSpec::LaxValidation) == static_cast<int>(G_PARAM_LAX_VALIDATION));
 
137
    BOOST_STATIC_ASSERT(static_cast<int>(ParamSpec::Deprecated) == static_cast<int>(G_PARAM_DEPRECATED));
 
138
}
 
139
 
 
140
namespace QGlib {
 
141
namespace Private {
 
142
  void registerWrapperConstructors()
 
143
  {
 
144
    QGlib::Quark q = g_quark_from_static_string("QGlib__wrapper_constructor");
 
145
    QGlib::GetType<Object>().setQuarkData(q, reinterpret_cast<void*>(&Object_new));
 
146
    QGlib::GetType<Interface>().setQuarkData(q, reinterpret_cast<void*>(&Interface_new));
 
147
    QGlib::GetType<ParamSpec>().setQuarkData(q, reinterpret_cast<void*>(&ParamSpec_new));
 
148
  }
 
149
} //namespace Private
 
150
} //namespace QGlib
 
151