~ubuntu-branches/ubuntu/lucid/ardour/lucid-proposed

« back to all changes in this revision

Viewing changes to libs/sigc++2/sigc++/slot.h

  • Committer: Bazaar Package Importer
  • Author(s): Luke Yelavich
  • Date: 2008-07-29 11:27:04 UTC
  • mfrom: (1.1.15 upstream)
  • Revision ID: james.westby@ubuntu.com-20080729112704-x1rmgb4tjotjyu5u
Tags: 1:2.5-0ubuntu1
* New upstream release.
* debian/patches/s390-FTBFS.patch: Dropped, as it fails to apply, and
  Ubuntu doesn't concern itself with s390.
* debian/control:
  - Fix package description, thanks to the patch in Debian bug #485892.
  - Metadata cleanup and sync control/control.in files.
  - Add libaubio-dev to Build-Depends.

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
#define _SIGC_MACROS_SLOTHM4_
7
7
 
8
8
#include <sigc++/functors/slot.h>
9
 
 
10
 
#ifndef LIBSIGC_DISABLE_DEPRECATED
11
 
 
12
 
namespace SigC {
13
 
 
14
 
// SlotN
15
 
/** Converts an arbitrary functor to a unified type which is opaque.
16
 
 * Slot0 itself is a functor or to be more precise a closure. It contains
17
 
 * a single, arbitrary functor (or closure) that is executed in operator()().
18
 
 *
19
 
 * The template arguments determine the function signature of operator()():
20
 
 * - @e T_return The return type of operator()().
21
 
 *
22
 
 * To use simply assign the slot to the desired functor. If the functor
23
 
 * is not compatible with the parameter list defined with the template
24
 
 * arguments compiler errors are triggered. When called the slot
25
 
 * will invoke the functor with minimal copies.
26
 
 * block() and unblock() can be used to block the functor's invocation
27
 
 * from operator()() temporarily.
28
 
 *
29
 
 * @par Example:
30
 
 *   @code
31
 
 *   #include <sigc++/slot.h>
32
 
 *   void foo(int) {}
33
 
 *   SigC::Slot1<void, long> s = SigC::slot(&foo);
34
 
 *   s(19);
35
 
 *   @endcode
36
 
 *
37
 
 * @deprecated Use the unnumbered template sigc::slot instead.
38
 
 * @ingroup compat
39
 
 */
40
 
template <class T_return>
41
 
class Slot0
42
 
  : public ::sigc::slot<T_return>
43
 
{
44
 
public:
45
 
  typedef ::sigc::slot<T_return> parent_type;
46
 
 
47
 
  /// Constructs an empty slot.
48
 
  Slot0() {}
49
 
 
50
 
  /** Constructs a slot from an arbitrary functor.
51
 
   * @param _A_func The desired functor the new slot should be assigned to.
52
 
   */
53
 
  template <class T_functor>
54
 
  Slot0(const T_functor& _A_func)
55
 
    : ::sigc::slot<T_return>(_A_func) {}
56
 
 
57
 
  /** Constructs a slot, copying an existing one.
58
 
   * @param src The existing slot to copy.
59
 
   */
60
 
  Slot0(const parent_type& src)
61
 
    : parent_type(src) {}
62
 
 
63
 
  /** Overrides this slot making a copy from another slot.
64
 
   * @param src The slot from which to make a copy.
65
 
   * @return @p this.
66
 
   */
67
 
  Slot0& operator=(const parent_type& src)
68
 
    { parent_type::operator=(src); return *this; }
69
 
};
70
 
 
71
 
/** Converts an arbitrary functor to a unified type which is opaque.
72
 
 * Slot1 itself is a functor or to be more precise a closure. It contains
73
 
 * a single, arbitrary functor (or closure) that is executed in operator()().
74
 
 *
75
 
 * The template arguments determine the function signature of operator()():
76
 
 * - @e T_return The return type of operator()().
77
 
 * - @e T_arg1 Argument type used in the definition of operator()().
78
 
 *
79
 
 * To use simply assign the slot to the desired functor. If the functor
80
 
 * is not compatible with the parameter list defined with the template
81
 
 * arguments compiler errors are triggered. When called the slot
82
 
 * will invoke the functor with minimal copies.
83
 
 * block() and unblock() can be used to block the functor's invocation
84
 
 * from operator()() temporarily.
85
 
 *
86
 
 * @par Example:
87
 
 *   @code
88
 
 *   #include <sigc++/slot.h>
89
 
 *   void foo(int) {}
90
 
 *   SigC::Slot1<void, long> s = SigC::slot(&foo);
91
 
 *   s(19);
92
 
 *   @endcode
93
 
 *
94
 
 * @deprecated Use the unnumbered template sigc::slot instead.
95
 
 * @ingroup compat
96
 
 */
97
 
template <class T_return, class T_arg1>
98
 
class Slot1
99
 
  : public ::sigc::slot<T_return, T_arg1>
100
 
{
101
 
public:
102
 
  typedef ::sigc::slot<T_return, T_arg1> parent_type;
103
 
 
104
 
  /// Constructs an empty slot.
105
 
  Slot1() {}
106
 
 
107
 
  /** Constructs a slot from an arbitrary functor.
108
 
   * @param _A_func The desired functor the new slot should be assigned to.
109
 
   */
110
 
  template <class T_functor>
111
 
  Slot1(const T_functor& _A_func)
112
 
    : ::sigc::slot<T_return, T_arg1>(_A_func) {}
113
 
 
114
 
  /** Constructs a slot, copying an existing one.
115
 
   * @param src The existing slot to copy.
116
 
   */
117
 
  Slot1(const parent_type& src)
118
 
    : parent_type(src) {}
119
 
 
120
 
  /** Overrides this slot making a copy from another slot.
121
 
   * @param src The slot from which to make a copy.
122
 
   * @return @p this.
123
 
   */
124
 
  Slot1& operator=(const parent_type& src)
125
 
    { parent_type::operator=(src); return *this; }
126
 
};
127
 
 
128
 
/** Converts an arbitrary functor to a unified type which is opaque.
129
 
 * Slot2 itself is a functor or to be more precise a closure. It contains
130
 
 * a single, arbitrary functor (or closure) that is executed in operator()().
131
 
 *
132
 
 * The template arguments determine the function signature of operator()():
133
 
 * - @e T_return The return type of operator()().
134
 
 * - @e T_arg1 Argument type used in the definition of operator()().
135
 
 * - @e T_arg2 Argument type used in the definition of operator()().
136
 
 *
137
 
 * To use simply assign the slot to the desired functor. If the functor
138
 
 * is not compatible with the parameter list defined with the template
139
 
 * arguments compiler errors are triggered. When called the slot
140
 
 * will invoke the functor with minimal copies.
141
 
 * block() and unblock() can be used to block the functor's invocation
142
 
 * from operator()() temporarily.
143
 
 *
144
 
 * @par Example:
145
 
 *   @code
146
 
 *   #include <sigc++/slot.h>
147
 
 *   void foo(int) {}
148
 
 *   SigC::Slot1<void, long> s = SigC::slot(&foo);
149
 
 *   s(19);
150
 
 *   @endcode
151
 
 *
152
 
 * @deprecated Use the unnumbered template sigc::slot instead.
153
 
 * @ingroup compat
154
 
 */
155
 
template <class T_return, class T_arg1,class T_arg2>
156
 
class Slot2
157
 
  : public ::sigc::slot<T_return, T_arg1,T_arg2>
158
 
{
159
 
public:
160
 
  typedef ::sigc::slot<T_return, T_arg1,T_arg2> parent_type;
161
 
 
162
 
  /// Constructs an empty slot.
163
 
  Slot2() {}
164
 
 
165
 
  /** Constructs a slot from an arbitrary functor.
166
 
   * @param _A_func The desired functor the new slot should be assigned to.
167
 
   */
168
 
  template <class T_functor>
169
 
  Slot2(const T_functor& _A_func)
170
 
    : ::sigc::slot<T_return, T_arg1,T_arg2>(_A_func) {}
171
 
 
172
 
  /** Constructs a slot, copying an existing one.
173
 
   * @param src The existing slot to copy.
174
 
   */
175
 
  Slot2(const parent_type& src)
176
 
    : parent_type(src) {}
177
 
 
178
 
  /** Overrides this slot making a copy from another slot.
179
 
   * @param src The slot from which to make a copy.
180
 
   * @return @p this.
181
 
   */
182
 
  Slot2& operator=(const parent_type& src)
183
 
    { parent_type::operator=(src); return *this; }
184
 
};
185
 
 
186
 
/** Converts an arbitrary functor to a unified type which is opaque.
187
 
 * Slot3 itself is a functor or to be more precise a closure. It contains
188
 
 * a single, arbitrary functor (or closure) that is executed in operator()().
189
 
 *
190
 
 * The template arguments determine the function signature of operator()():
191
 
 * - @e T_return The return type of operator()().
192
 
 * - @e T_arg1 Argument type used in the definition of operator()().
193
 
 * - @e T_arg2 Argument type used in the definition of operator()().
194
 
 * - @e T_arg3 Argument type used in the definition of operator()().
195
 
 *
196
 
 * To use simply assign the slot to the desired functor. If the functor
197
 
 * is not compatible with the parameter list defined with the template
198
 
 * arguments compiler errors are triggered. When called the slot
199
 
 * will invoke the functor with minimal copies.
200
 
 * block() and unblock() can be used to block the functor's invocation
201
 
 * from operator()() temporarily.
202
 
 *
203
 
 * @par Example:
204
 
 *   @code
205
 
 *   #include <sigc++/slot.h>
206
 
 *   void foo(int) {}
207
 
 *   SigC::Slot1<void, long> s = SigC::slot(&foo);
208
 
 *   s(19);
209
 
 *   @endcode
210
 
 *
211
 
 * @deprecated Use the unnumbered template sigc::slot instead.
212
 
 * @ingroup compat
213
 
 */
214
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3>
215
 
class Slot3
216
 
  : public ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3>
217
 
{
218
 
public:
219
 
  typedef ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3> parent_type;
220
 
 
221
 
  /// Constructs an empty slot.
222
 
  Slot3() {}
223
 
 
224
 
  /** Constructs a slot from an arbitrary functor.
225
 
   * @param _A_func The desired functor the new slot should be assigned to.
226
 
   */
227
 
  template <class T_functor>
228
 
  Slot3(const T_functor& _A_func)
229
 
    : ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3>(_A_func) {}
230
 
 
231
 
  /** Constructs a slot, copying an existing one.
232
 
   * @param src The existing slot to copy.
233
 
   */
234
 
  Slot3(const parent_type& src)
235
 
    : parent_type(src) {}
236
 
 
237
 
  /** Overrides this slot making a copy from another slot.
238
 
   * @param src The slot from which to make a copy.
239
 
   * @return @p this.
240
 
   */
241
 
  Slot3& operator=(const parent_type& src)
242
 
    { parent_type::operator=(src); return *this; }
243
 
};
244
 
 
245
 
/** Converts an arbitrary functor to a unified type which is opaque.
246
 
 * Slot4 itself is a functor or to be more precise a closure. It contains
247
 
 * a single, arbitrary functor (or closure) that is executed in operator()().
248
 
 *
249
 
 * The template arguments determine the function signature of operator()():
250
 
 * - @e T_return The return type of operator()().
251
 
 * - @e T_arg1 Argument type used in the definition of operator()().
252
 
 * - @e T_arg2 Argument type used in the definition of operator()().
253
 
 * - @e T_arg3 Argument type used in the definition of operator()().
254
 
 * - @e T_arg4 Argument type used in the definition of operator()().
255
 
 *
256
 
 * To use simply assign the slot to the desired functor. If the functor
257
 
 * is not compatible with the parameter list defined with the template
258
 
 * arguments compiler errors are triggered. When called the slot
259
 
 * will invoke the functor with minimal copies.
260
 
 * block() and unblock() can be used to block the functor's invocation
261
 
 * from operator()() temporarily.
262
 
 *
263
 
 * @par Example:
264
 
 *   @code
265
 
 *   #include <sigc++/slot.h>
266
 
 *   void foo(int) {}
267
 
 *   SigC::Slot1<void, long> s = SigC::slot(&foo);
268
 
 *   s(19);
269
 
 *   @endcode
270
 
 *
271
 
 * @deprecated Use the unnumbered template sigc::slot instead.
272
 
 * @ingroup compat
273
 
 */
274
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3,class T_arg4>
275
 
class Slot4
276
 
  : public ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4>
277
 
{
278
 
public:
279
 
  typedef ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4> parent_type;
280
 
 
281
 
  /// Constructs an empty slot.
282
 
  Slot4() {}
283
 
 
284
 
  /** Constructs a slot from an arbitrary functor.
285
 
   * @param _A_func The desired functor the new slot should be assigned to.
286
 
   */
287
 
  template <class T_functor>
288
 
  Slot4(const T_functor& _A_func)
289
 
    : ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4>(_A_func) {}
290
 
 
291
 
  /** Constructs a slot, copying an existing one.
292
 
   * @param src The existing slot to copy.
293
 
   */
294
 
  Slot4(const parent_type& src)
295
 
    : parent_type(src) {}
296
 
 
297
 
  /** Overrides this slot making a copy from another slot.
298
 
   * @param src The slot from which to make a copy.
299
 
   * @return @p this.
300
 
   */
301
 
  Slot4& operator=(const parent_type& src)
302
 
    { parent_type::operator=(src); return *this; }
303
 
};
304
 
 
305
 
/** Converts an arbitrary functor to a unified type which is opaque.
306
 
 * Slot5 itself is a functor or to be more precise a closure. It contains
307
 
 * a single, arbitrary functor (or closure) that is executed in operator()().
308
 
 *
309
 
 * The template arguments determine the function signature of operator()():
310
 
 * - @e T_return The return type of operator()().
311
 
 * - @e T_arg1 Argument type used in the definition of operator()().
312
 
 * - @e T_arg2 Argument type used in the definition of operator()().
313
 
 * - @e T_arg3 Argument type used in the definition of operator()().
314
 
 * - @e T_arg4 Argument type used in the definition of operator()().
315
 
 * - @e T_arg5 Argument type used in the definition of operator()().
316
 
 *
317
 
 * To use simply assign the slot to the desired functor. If the functor
318
 
 * is not compatible with the parameter list defined with the template
319
 
 * arguments compiler errors are triggered. When called the slot
320
 
 * will invoke the functor with minimal copies.
321
 
 * block() and unblock() can be used to block the functor's invocation
322
 
 * from operator()() temporarily.
323
 
 *
324
 
 * @par Example:
325
 
 *   @code
326
 
 *   #include <sigc++/slot.h>
327
 
 *   void foo(int) {}
328
 
 *   SigC::Slot1<void, long> s = SigC::slot(&foo);
329
 
 *   s(19);
330
 
 *   @endcode
331
 
 *
332
 
 * @deprecated Use the unnumbered template sigc::slot instead.
333
 
 * @ingroup compat
334
 
 */
335
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3,class T_arg4,class T_arg5>
336
 
class Slot5
337
 
  : public ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5>
338
 
{
339
 
public:
340
 
  typedef ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5> parent_type;
341
 
 
342
 
  /// Constructs an empty slot.
343
 
  Slot5() {}
344
 
 
345
 
  /** Constructs a slot from an arbitrary functor.
346
 
   * @param _A_func The desired functor the new slot should be assigned to.
347
 
   */
348
 
  template <class T_functor>
349
 
  Slot5(const T_functor& _A_func)
350
 
    : ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5>(_A_func) {}
351
 
 
352
 
  /** Constructs a slot, copying an existing one.
353
 
   * @param src The existing slot to copy.
354
 
   */
355
 
  Slot5(const parent_type& src)
356
 
    : parent_type(src) {}
357
 
 
358
 
  /** Overrides this slot making a copy from another slot.
359
 
   * @param src The slot from which to make a copy.
360
 
   * @return @p this.
361
 
   */
362
 
  Slot5& operator=(const parent_type& src)
363
 
    { parent_type::operator=(src); return *this; }
364
 
};
365
 
 
366
 
/** Converts an arbitrary functor to a unified type which is opaque.
367
 
 * Slot6 itself is a functor or to be more precise a closure. It contains
368
 
 * a single, arbitrary functor (or closure) that is executed in operator()().
369
 
 *
370
 
 * The template arguments determine the function signature of operator()():
371
 
 * - @e T_return The return type of operator()().
372
 
 * - @e T_arg1 Argument type used in the definition of operator()().
373
 
 * - @e T_arg2 Argument type used in the definition of operator()().
374
 
 * - @e T_arg3 Argument type used in the definition of operator()().
375
 
 * - @e T_arg4 Argument type used in the definition of operator()().
376
 
 * - @e T_arg5 Argument type used in the definition of operator()().
377
 
 * - @e T_arg6 Argument type used in the definition of operator()().
378
 
 *
379
 
 * To use simply assign the slot to the desired functor. If the functor
380
 
 * is not compatible with the parameter list defined with the template
381
 
 * arguments compiler errors are triggered. When called the slot
382
 
 * will invoke the functor with minimal copies.
383
 
 * block() and unblock() can be used to block the functor's invocation
384
 
 * from operator()() temporarily.
385
 
 *
386
 
 * @par Example:
387
 
 *   @code
388
 
 *   #include <sigc++/slot.h>
389
 
 *   void foo(int) {}
390
 
 *   SigC::Slot1<void, long> s = SigC::slot(&foo);
391
 
 *   s(19);
392
 
 *   @endcode
393
 
 *
394
 
 * @deprecated Use the unnumbered template sigc::slot instead.
395
 
 * @ingroup compat
396
 
 */
397
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3,class T_arg4,class T_arg5,class T_arg6>
398
 
class Slot6
399
 
  : public ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6>
400
 
{
401
 
public:
402
 
  typedef ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6> parent_type;
403
 
 
404
 
  /// Constructs an empty slot.
405
 
  Slot6() {}
406
 
 
407
 
  /** Constructs a slot from an arbitrary functor.
408
 
   * @param _A_func The desired functor the new slot should be assigned to.
409
 
   */
410
 
  template <class T_functor>
411
 
  Slot6(const T_functor& _A_func)
412
 
    : ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6>(_A_func) {}
413
 
 
414
 
  /** Constructs a slot, copying an existing one.
415
 
   * @param src The existing slot to copy.
416
 
   */
417
 
  Slot6(const parent_type& src)
418
 
    : parent_type(src) {}
419
 
 
420
 
  /** Overrides this slot making a copy from another slot.
421
 
   * @param src The slot from which to make a copy.
422
 
   * @return @p this.
423
 
   */
424
 
  Slot6& operator=(const parent_type& src)
425
 
    { parent_type::operator=(src); return *this; }
426
 
};
427
 
 
428
 
/** Converts an arbitrary functor to a unified type which is opaque.
429
 
 * Slot7 itself is a functor or to be more precise a closure. It contains
430
 
 * a single, arbitrary functor (or closure) that is executed in operator()().
431
 
 *
432
 
 * The template arguments determine the function signature of operator()():
433
 
 * - @e T_return The return type of operator()().
434
 
 * - @e T_arg1 Argument type used in the definition of operator()().
435
 
 * - @e T_arg2 Argument type used in the definition of operator()().
436
 
 * - @e T_arg3 Argument type used in the definition of operator()().
437
 
 * - @e T_arg4 Argument type used in the definition of operator()().
438
 
 * - @e T_arg5 Argument type used in the definition of operator()().
439
 
 * - @e T_arg6 Argument type used in the definition of operator()().
440
 
 * - @e T_arg7 Argument type used in the definition of operator()().
441
 
 *
442
 
 * To use simply assign the slot to the desired functor. If the functor
443
 
 * is not compatible with the parameter list defined with the template
444
 
 * arguments compiler errors are triggered. When called the slot
445
 
 * will invoke the functor with minimal copies.
446
 
 * block() and unblock() can be used to block the functor's invocation
447
 
 * from operator()() temporarily.
448
 
 *
449
 
 * @par Example:
450
 
 *   @code
451
 
 *   #include <sigc++/slot.h>
452
 
 *   void foo(int) {}
453
 
 *   SigC::Slot1<void, long> s = SigC::slot(&foo);
454
 
 *   s(19);
455
 
 *   @endcode
456
 
 *
457
 
 * @deprecated Use the unnumbered template sigc::slot instead.
458
 
 * @ingroup compat
459
 
 */
460
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3,class T_arg4,class T_arg5,class T_arg6,class T_arg7>
461
 
class Slot7
462
 
  : public ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6,T_arg7>
463
 
{
464
 
public:
465
 
  typedef ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6,T_arg7> parent_type;
466
 
 
467
 
  /// Constructs an empty slot.
468
 
  Slot7() {}
469
 
 
470
 
  /** Constructs a slot from an arbitrary functor.
471
 
   * @param _A_func The desired functor the new slot should be assigned to.
472
 
   */
473
 
  template <class T_functor>
474
 
  Slot7(const T_functor& _A_func)
475
 
    : ::sigc::slot<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6,T_arg7>(_A_func) {}
476
 
 
477
 
  /** Constructs a slot, copying an existing one.
478
 
   * @param src The existing slot to copy.
479
 
   */
480
 
  Slot7(const parent_type& src)
481
 
    : parent_type(src) {}
482
 
 
483
 
  /** Overrides this slot making a copy from another slot.
484
 
   * @param src The slot from which to make a copy.
485
 
   * @return @p this.
486
 
   */
487
 
  Slot7& operator=(const parent_type& src)
488
 
    { parent_type::operator=(src); return *this; }
489
 
};
490
 
 
491
 
 
492
 
 
493
 
#ifndef DOXYGEN_SHOULD_SKIP_THIS
494
 
/* gcc 3.2 reports a strange conflict between SigC::slot() and sigc::slot<>
495
 
 * when "using namespace SigC" and later using a slot(obj,func) overload
496
 
 * without the prefix "SigC::". Probably a compiler bug. I will investigate.
497
 
 *
498
 
 * This ugly hack avoids the error:
499
 
 */
500
 
// #define slot(...) make_slot(__VA_ARGS__) /* only works for gcc */
501
 
#endif
502
 
 
503
 
 
504
 
// slot()
505
 
/** Creates a functor of type SigC::Slot0 that wraps an existing non-member function.
506
 
 *
507
 
 * @param _A_func Pointer to function that should be wrapped.
508
 
 * @return Functor that executes _A_func on invokation.
509
 
 *
510
 
 * @deprecated Use sigc::ptr_fun() instead.
511
 
 * @ingroup compat
512
 
 */
513
 
template <class T_return>
514
 
inline Slot0<T_return>
515
 
slot(T_return (*_A_func)())
516
 
{ return Slot0<T_return>(_A_func); }
517
 
 
518
 
/** Creates a functor of type SigC::Slot1 that wraps an existing non-member function.
519
 
 *
520
 
 * @param _A_func Pointer to function that should be wrapped.
521
 
 * @return Functor that executes _A_func on invokation.
522
 
 *
523
 
 * @deprecated Use sigc::ptr_fun() instead.
524
 
 * @ingroup compat
525
 
 */
526
 
template <class T_return, class T_arg1>
527
 
inline Slot1<T_return, T_arg1>
528
 
slot(T_return (*_A_func)(T_arg1))
529
 
{ return Slot1<T_return, T_arg1>(_A_func); }
530
 
 
531
 
/** Creates a functor of type SigC::Slot2 that wraps an existing non-member function.
532
 
 *
533
 
 * @param _A_func Pointer to function that should be wrapped.
534
 
 * @return Functor that executes _A_func on invokation.
535
 
 *
536
 
 * @deprecated Use sigc::ptr_fun() instead.
537
 
 * @ingroup compat
538
 
 */
539
 
template <class T_return, class T_arg1,class T_arg2>
540
 
inline Slot2<T_return, T_arg1,T_arg2>
541
 
slot(T_return (*_A_func)(T_arg1,T_arg2))
542
 
{ return Slot2<T_return, T_arg1,T_arg2>(_A_func); }
543
 
 
544
 
/** Creates a functor of type SigC::Slot3 that wraps an existing non-member function.
545
 
 *
546
 
 * @param _A_func Pointer to function that should be wrapped.
547
 
 * @return Functor that executes _A_func on invokation.
548
 
 *
549
 
 * @deprecated Use sigc::ptr_fun() instead.
550
 
 * @ingroup compat
551
 
 */
552
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3>
553
 
inline Slot3<T_return, T_arg1,T_arg2,T_arg3>
554
 
slot(T_return (*_A_func)(T_arg1,T_arg2,T_arg3))
555
 
{ return Slot3<T_return, T_arg1,T_arg2,T_arg3>(_A_func); }
556
 
 
557
 
/** Creates a functor of type SigC::Slot4 that wraps an existing non-member function.
558
 
 *
559
 
 * @param _A_func Pointer to function that should be wrapped.
560
 
 * @return Functor that executes _A_func on invokation.
561
 
 *
562
 
 * @deprecated Use sigc::ptr_fun() instead.
563
 
 * @ingroup compat
564
 
 */
565
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3,class T_arg4>
566
 
inline Slot4<T_return, T_arg1,T_arg2,T_arg3,T_arg4>
567
 
slot(T_return (*_A_func)(T_arg1,T_arg2,T_arg3,T_arg4))
568
 
{ return Slot4<T_return, T_arg1,T_arg2,T_arg3,T_arg4>(_A_func); }
569
 
 
570
 
/** Creates a functor of type SigC::Slot5 that wraps an existing non-member function.
571
 
 *
572
 
 * @param _A_func Pointer to function that should be wrapped.
573
 
 * @return Functor that executes _A_func on invokation.
574
 
 *
575
 
 * @deprecated Use sigc::ptr_fun() instead.
576
 
 * @ingroup compat
577
 
 */
578
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3,class T_arg4,class T_arg5>
579
 
inline Slot5<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5>
580
 
slot(T_return (*_A_func)(T_arg1,T_arg2,T_arg3,T_arg4,T_arg5))
581
 
{ return Slot5<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5>(_A_func); }
582
 
 
583
 
/** Creates a functor of type SigC::Slot6 that wraps an existing non-member function.
584
 
 *
585
 
 * @param _A_func Pointer to function that should be wrapped.
586
 
 * @return Functor that executes _A_func on invokation.
587
 
 *
588
 
 * @deprecated Use sigc::ptr_fun() instead.
589
 
 * @ingroup compat
590
 
 */
591
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3,class T_arg4,class T_arg5,class T_arg6>
592
 
inline Slot6<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6>
593
 
slot(T_return (*_A_func)(T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6))
594
 
{ return Slot6<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6>(_A_func); }
595
 
 
596
 
/** Creates a functor of type SigC::Slot7 that wraps an existing non-member function.
597
 
 *
598
 
 * @param _A_func Pointer to function that should be wrapped.
599
 
 * @return Functor that executes _A_func on invokation.
600
 
 *
601
 
 * @deprecated Use sigc::ptr_fun() instead.
602
 
 * @ingroup compat
603
 
 */
604
 
template <class T_return, class T_arg1,class T_arg2,class T_arg3,class T_arg4,class T_arg5,class T_arg6,class T_arg7>
605
 
inline Slot7<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6,T_arg7>
606
 
slot(T_return (*_A_func)(T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6,T_arg7))
607
 
{ return Slot7<T_return, T_arg1,T_arg2,T_arg3,T_arg4,T_arg5,T_arg6,T_arg7>(_A_func); }
608
 
 
609
 
 
610
 
 
611
 
}
612
 
 
613
 
#endif
614
9
#endif /* _SIGC_MACROS_SLOTHM4_ */