diff options
author | Martin Schulze <teebaum@cvs.gnome.org> | 2004-02-13 16:53:20 +0000 |
---|---|---|
committer | Martin Schulze <teebaum@src.gnome.org> | 2004-02-13 16:53:20 +0000 |
commit | ef80e61d09a8e90b63a45e01be8bb445547fa90c (patch) | |
tree | f73cd994898099e8313a4d7123db4841d8595fe4 | |
parent | 4c3e21ed19baab081addfb7ecfe6859927005245 (diff) | |
download | glibmm-ef80e61d09a8e90b63a45e01be8bb445547fa90c.tar.gz |
documentation fixes and corrections in the comments reflecting the shift
2004-02-13 Martin Schulze <teebaum@cvs.gnome.org>
* documentation fixes and corrections in the comments reflecting
the shift to libsigc++ 2.
* make all source files in example thread use libsigc++ 2 instead
of libsigc++ 1.2.
-rw-r--r-- | ChangeLog | 7 | ||||
-rw-r--r-- | examples/thread/dispatcher2.cc | 5 | ||||
-rw-r--r-- | examples/thread/thread.cc | 5 | ||||
-rw-r--r-- | glib/glibmm/dispatcher.h | 2 | ||||
-rw-r--r-- | glib/glibmm/main.h | 16 | ||||
-rw-r--r-- | glib/glibmm/objectbase.cc | 6 | ||||
-rw-r--r-- | glib/glibmm/objectbase.h | 6 | ||||
-rw-r--r-- | glib/glibmm/propertyproxy_base.cc | 2 | ||||
-rw-r--r-- | glib/glibmm/propertyproxy_base.h | 2 | ||||
-rw-r--r-- | glib/glibmm/signalproxy_connectionnode.h | 2 | ||||
-rw-r--r-- | glib/src/iochannel.hg | 8 | ||||
-rw-r--r-- | glib/src/thread.hg | 4 |
12 files changed, 34 insertions, 31 deletions
@@ -1,3 +1,10 @@ +2004-02-13 Martin Schulze <teebaum@cvs.gnome.org> + + * documentation fixes and corrections in the comments reflecting + the shift to libsigc++ 2. + * make all source files in example thread use libsigc++ 2 instead + of libsigc++ 1.2. + 2004-02-10 Murray Cumming <murrayc@usa.net> * glibmm now uses libsigc++ 2 instead of libsigc++ 1.2. See bug diff --git a/examples/thread/dispatcher2.cc b/examples/thread/dispatcher2.cc index c2270181..1e4cb806 100644 --- a/examples/thread/dispatcher2.cc +++ b/examples/thread/dispatcher2.cc @@ -20,7 +20,6 @@ * Copyright (c) 2002-2003 Free Software Foundation */ -#include <sigc++/class_slot.h> #include <glibmm.h> #include <sstream> #include <iostream> @@ -40,7 +39,7 @@ public: void signal_finished_emit(); void print() const; - typedef SigC::Signal0<void> type_signal_end; + typedef sigc::signal<void> type_signal_end; static type_signal_end& signal_end(); private: @@ -122,7 +121,7 @@ void ThreadTimer::print() const std::cout << time_ << " seconds since start" << std::endl; } -SigC::Signal0< void >& ThreadTimer::signal_end() +sigc::signal< void >& ThreadTimer::signal_end() { return signal_end_; } diff --git a/examples/thread/thread.cc b/examples/thread/thread.cc index aaddff92..cc4c8df2 100644 --- a/examples/thread/thread.cc +++ b/examples/thread/thread.cc @@ -1,7 +1,6 @@ #include <iostream> #include <queue> -#include <sigc++/class_slot.h> #include <glibmm/random.h> #include <glibmm/thread.h> #include <glibmm/timer.h> @@ -99,10 +98,10 @@ int main(int, char**) MessageQueue queue; Glib::Thread *const producer = Glib::Thread::create( - SigC::slot_class(queue, &MessageQueue::producer), true); + sigc::mem_fun(queue, &MessageQueue::producer), true); Glib::Thread *const consumer = Glib::Thread::create( - SigC::slot_class(queue, &MessageQueue::consumer), true); + sigc::mem_fun(queue, &MessageQueue::consumer), true); producer->join(); consumer->join(); diff --git a/glib/glibmm/dispatcher.h b/glib/glibmm/dispatcher.h index d4bc802b..cecf606e 100644 --- a/glib/glibmm/dispatcher.h +++ b/glib/glibmm/dispatcher.h @@ -34,7 +34,7 @@ class DispatchNotifier; /** Signal class for inter-thread communication. * @ingroup Threads - * Glib::Dispatcher works similar to SigC::Signal0<void>. But unlike normal + * Glib::Dispatcher works similar to sigc::signal<void>. But unlike normal * signals, the notification happens asynchronously through a pipe. This is * a simple and efficient way of communicating between threads, and especially * useful in a thread model with a single GUI thread. diff --git a/glib/glibmm/main.h b/glib/glibmm/main.h index 599b444e..d6fbfa33 100644 --- a/glib/glibmm/main.h +++ b/glib/glibmm/main.h @@ -167,12 +167,12 @@ public: /** Connects a timeout handler. * @code - * Glib::signal_timeout().connect(SigC::slot(&timeout_handler), 1000); + * Glib::signal_timeout().connect(sigc::ptr_fun(&timeout_handler), 1000); * @endcode * is equivalent to: * @code * const Glib::RefPtr<Glib::TimeoutSource> timeout_source = Glib::TimeoutSource::create(1000); - * timeout_source->connect(SigC::slot(&timeout_handler)); + * timeout_source->connect(sigc::ptr_fun(&timeout_handler)); * timeout_source->attach(Glib::MainContext::get_default()); * @endcode * @param slot A slot to call when @a interval elapsed. @@ -199,12 +199,12 @@ public: /** Connects an idle handler. * @code - * Glib::signal_idle().connect(SigC::slot(&idle_handler)); + * Glib::signal_idle().connect(sigc::ptr_fun(&idle_handler)); * @endcode * is equivalent to: * @code * const Glib::RefPtr<Glib::IdleSource> idle_source = Glib::IdleSource::create(); - * idle_source->connect(SigC::slot(&idle_handler)); + * idle_source->connect(sigc::ptr_fun(&idle_handler)); * idle_source->attach(Glib::MainContext::get_default()); * @endcode * @param slot A slot to call when the main loop is idle. @@ -230,12 +230,12 @@ public: /** Connects an I/O handler. * @code - * Glib::signal_io().connect(SigC::slot(&io_handler), fd, Glib::IO_IN | Glib::IO_HUP); + * Glib::signal_io().connect(sigc::ptr_fun(&io_handler), fd, Glib::IO_IN | Glib::IO_HUP); * @endcode * is equivalent to: * @code * const Glib::RefPtr<Glib::IOSource> io_source = Glib::IOSource::create(fd, Glib::IO_IN | Glib::IO_HUP); - * io_source->connect(SigC::slot(&io_handler)); + * io_source->connect(sigc::ptr_fun(&io_handler)); * io_source->attach(Glib::MainContext::get_default()); * @endcode * @param slot A slot to call when polling @a fd results in an event that matches @a condition. @@ -251,12 +251,12 @@ public: /** Connects an I/O channel. * @code - * Glib::signal_io().connect(SigC::slot(&io_handler), channel, Glib::IO_IN | Glib::IO_HUP); + * Glib::signal_io().connect(sigc::ptr_fun(&io_handler), channel, Glib::IO_IN | Glib::IO_HUP); * @endcode * is equivalent to: * @code * const Glib::RefPtr<Glib::IOSource> io_source = Glib::IOSource::create(channel, Glib::IO_IN | Glib::IO_HUP); - * io_source->connect(SigC::slot(&io_handler)); + * io_source->connect(sigc::ptr_fun(&io_handler)); * io_source->attach(Glib::MainContext::get_default()); * @endcode * @param slot A slot to call when polling @a channel results in an event that matches @a condition. diff --git a/glib/glibmm/objectbase.cc b/glib/glibmm/objectbase.cc index 9c06ab1c..706f9886 100644 --- a/glib/glibmm/objectbase.cc +++ b/glib/glibmm/objectbase.cc @@ -129,14 +129,12 @@ ObjectBase::~ObjectBase() void ObjectBase::reference() const { - // Completely replace the SigC::Object refcounting. GLIBMM_DEBUG_REFERENCE(this, gobject_); g_object_ref(gobject_); } void ObjectBase::unreference() const { - // Completely replace the SigC::Object refcounting. GLIBMM_DEBUG_UNREFERENCE(this, gobject_); g_object_unref(gobject_); } @@ -233,10 +231,10 @@ bool ObjectBase::is_derived_() const void ObjectBase::set_manage() { - // This is a private method and SigC::manage() is a template function. + // This is a private method and Gtk::manage() is a template function. // Thus this will probably never run, unless you do something like: // - // manage(static_cast<SigC::Object*>(refptr.operator->())); + // manage(static_cast<Gtk::Object*>(refptr.operator->())); g_error("Glib::ObjectBase::set_manage(): " "only Gtk::Object instances can be managed"); diff --git a/glib/glibmm/objectbase.h b/glib/glibmm/objectbase.h index 2b9fe1b6..bddfdcf6 100644 --- a/glib/glibmm/objectbase.h +++ b/glib/glibmm/objectbase.h @@ -42,7 +42,7 @@ namespace Glib class GSigConnectionNode; #endif -//This inherits virtually from sgc::trackable so that people can multiply inherit glibmm classes from other SigC::Object-derived classes. +//This inherits virtually from sigc::trackable so that people can multiply inherit glibmm classes from other sigc::trackable-derived classes. //See bugzilla.gnome.org bug # 116280 class ObjectBase : virtual public sigc::trackable { @@ -97,8 +97,8 @@ public: void get_property(const Glib::ustring& property_name, PropertyType& value) const; - virtual void reference() const; // overrides SigC::ObjectBase::reference() - virtual void unreference() const; // overrides SigC::ObjectBase::unreference() + virtual void reference() const; + virtual void unreference() const; inline GObject* gobj() { return gobject_; } inline const GObject* gobj() const { return gobject_; } diff --git a/glib/glibmm/propertyproxy_base.cc b/glib/glibmm/propertyproxy_base.cc index dba3318d..d10c8cd3 100644 --- a/glib/glibmm/propertyproxy_base.cc +++ b/glib/glibmm/propertyproxy_base.cc @@ -28,7 +28,7 @@ namespace Glib { -/** PropertyProxyConnectionNode is a SigC::ConnectionNode for use with SignalProxyProperty. +/** PropertyProxyConnectionNode is a connection node for use with SignalProxyProperty. * It's like ProxyConnectionNode, but it contains the property name too. */ class PropertyProxyConnectionNode : public SignalProxyConnectionNode diff --git a/glib/glibmm/propertyproxy_base.h b/glib/glibmm/propertyproxy_base.h index 743242ce..036291df 100644 --- a/glib/glibmm/propertyproxy_base.h +++ b/glib/glibmm/propertyproxy_base.h @@ -31,7 +31,7 @@ namespace Glib class ObjectBase; -/// Use the connect() method, with SigC::slot() to connect signals to signal handlers. +/// Use the connect() method, with sigc::ptr_fun() or sig::mem_fun() to connect signals to signal handlers. class SignalProxyProperty : public SignalProxyBase { public: diff --git a/glib/glibmm/signalproxy_connectionnode.h b/glib/glibmm/signalproxy_connectionnode.h index 1126ba9c..0dd84a80 100644 --- a/glib/glibmm/signalproxy_connectionnode.h +++ b/glib/glibmm/signalproxy_connectionnode.h @@ -31,7 +31,7 @@ typedef struct _GObject GObject; namespace Glib { -/** SignalProxyConnectionNode is a SigC::ConnectionNode for use with SignalProxy. +/** SignalProxyConnectionNode is a connection node for use with SignalProxy. * It lives between the layer of Gtk+ and SigC++. * It is very much an internal class. */ diff --git a/glib/src/iochannel.hg b/glib/src/iochannel.hg index fbc3ea13..f109235d 100644 --- a/glib/src/iochannel.hg +++ b/glib/src/iochannel.hg @@ -396,10 +396,10 @@ public: /** Creates an IOSource object. * Create a slot from a function to be called when condition is met - * for the channel with SigC::slot() and pass it into the connect() - * function of the returned IOSource object. Polling of the channel - * will start when you attach a MainContext object to the returned - * IOSource object using its attach() function. + * for the channel with sigc::ptr_fun() or sigc::mem_fun() and pass + * it into the connect() function of the returned IOSource object. + * Polling of the channel will start when you attach a MainContext + * object to the returned IOSource object using its attach() function. * * Glib::signal_io().connect() is a simpler interface to the same * functionality, for the case where you want to add the source to the diff --git a/glib/src/thread.hg b/glib/src/thread.hg index 9431b298..2473f813 100644 --- a/glib/src/thread.hg +++ b/glib/src/thread.hg @@ -179,7 +179,7 @@ public: * calling join(). Otherwise the thread will just disappear, when ready. * * The new thread executes the function or method @a slot points to. You can - * pass additional arguments using SigC::bind(). If the thread was created + * pass additional arguments using sigc::bind(). If the thread was created * successfully, it is returned, otherwise a ThreadError exception is thrown. * * @param slot A slot to execute in the new thread. @@ -201,7 +201,7 @@ public: * faster. On some systems (e.g. Linux) all threads are bound. * * The new thread executes the function or method @a slot points to. You can - * pass additional arguments using SigC::bind(). If the thread was created + * pass additional arguments using sigc::bind(). If the thread was created * successfully, it is returned. * * @note It is not guaranteed, that threads with different priorities really |