annotate src/gtk/sigccompat.h @ 8:08a8e09ca414

add files required by automake
author Robert McIntyre <rlm@mit.edu>
date Sat, 03 Mar 2012 10:54:39 -0600
parents f9f4f1b99eed
children
rev   line source
rlm@1 1 // -*- C++ -*-
rlm@1 2 // VisualBoyAdvance - Nintendo Gameboy/GameboyAdvance (TM) emulator.
rlm@1 3 // Copyright (C) 1999-2003 Forgotten
rlm@1 4 // Copyright (C) 2004 Forgotten and the VBA development team
rlm@1 5
rlm@1 6 // This program is free software; you can redistribute it and/or modify
rlm@1 7 // it under the terms of the GNU General Public License as published by
rlm@1 8 // the Free Software Foundation; either version 2, or(at your option)
rlm@1 9 // any later version.
rlm@1 10 //
rlm@1 11 // This program is distributed in the hope that it will be useful,
rlm@1 12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
rlm@1 13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
rlm@1 14 // GNU General Public License for more details.
rlm@1 15 //
rlm@1 16 // You should have received a copy of the GNU General Public License
rlm@1 17 // along with this program; if not, write to the Free Software Foundation,
rlm@1 18 // Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
rlm@1 19
rlm@1 20 #ifndef __VBA_SIGCCOMPAT_H__
rlm@1 21 #define __VBA_SIGCCOMPAT_H__
rlm@1 22
rlm@1 23 #undef LIBSIGC_DISABLE_DEPRECATED
rlm@1 24 #include <sigc++/bind.h>
rlm@1 25 #include <sigc++/connection.h>
rlm@1 26
rlm@1 27 #include <sigc++/slot.h>
rlm@1 28 #include <sigc++/object.h>
rlm@1 29 #include <sigc++/functors/mem_fun.h>
rlm@1 30
rlm@1 31 namespace SigC
rlm@1 32 {
rlm@1 33
rlm@1 34 using namespace sigc;
rlm@1 35
rlm@1 36 template <class T_return, class T_obj1, class T_obj2>
rlm@1 37 inline slot0<T_return>
rlm@1 38 slot( T_obj1& _A_obj, T_return (T_obj2::*_A_func)() )
rlm@1 39 { return ::sigc::bound_mem_functor0<T_return, T_obj2>
rlm@1 40 (dynamic_cast< T_obj1&>(_A_obj), _A_func); }
rlm@1 41
rlm@1 42 template <class T_return, class T_arg1, class T_obj1, class T_obj2>
rlm@1 43 inline slot1<T_return, T_arg1>
rlm@1 44 slot( T_obj1& _A_obj, T_return (T_obj2::*_A_func)(T_arg1) )
rlm@1 45 { return ::sigc::bound_mem_functor1<T_return, T_obj2, T_arg1>
rlm@1 46 (dynamic_cast< T_obj1&>(_A_obj), _A_func); }
rlm@1 47
rlm@1 48 template <class T_return, class T_arg1,class T_arg2, class T_obj1, class T_obj2>
rlm@1 49 inline slot2<T_return, T_arg1,T_arg2>
rlm@1 50 slot( T_obj1& _A_obj, T_return (T_obj2::*_A_func)(T_arg1,T_arg2) )
rlm@1 51 { return ::sigc::bound_mem_functor2<T_return, T_obj2, T_arg1,T_arg2>
rlm@1 52 (dynamic_cast< T_obj1&>(_A_obj), _A_func); }
rlm@1 53
rlm@1 54 } // namespace SigC
rlm@1 55
rlm@1 56
rlm@1 57 #endif // __VBA_SIGCCOMPAT_H__