[glibmm] sigc3: .h/.cc files: Use slot/signal<R(Args...)> syntax.



commit ba81039b2f0140200358e2d3615bd2bf7aefb360
Author: Murray Cumming <murrayc murrayc com>
Date:   Thu Mar 31 12:53:33 2016 +0200

    sigc3: .h/.cc files: Use slot/signal<R(Args...)> syntax.

 gio/giomm/socketsource.cc         |    4 +-
 gio/giomm/socketsource.h          |    2 +-
 glib/glibmm/dispatcher.cc         |    4 +-
 glib/glibmm/dispatcher.h          |    8 +++---
 glib/glibmm/exceptionhandler.cc   |    2 +-
 glib/glibmm/exceptionhandler.h    |    2 +-
 glib/glibmm/main.cc               |   46 ++++++++++++++++++------------------
 glib/glibmm/main.h                |   28 +++++++++++-----------
 glib/glibmm/objectbase.cc         |    8 +++---
 glib/glibmm/objectbase.h          |    8 +++---
 glib/glibmm/propertyproxy_base.cc |    2 +-
 glib/glibmm/propertyproxy_base.h  |    2 +-
 glib/glibmm/signalproxy.cc        |    2 +-
 glib/glibmm/signalproxy.h         |    8 +++---
 glib/glibmm/threadpool.cc         |   24 +++++++++---------
 glib/glibmm/threadpool.h          |    4 +-
 16 files changed, 77 insertions(+), 77 deletions(-)
---
diff --git a/gio/giomm/socketsource.cc b/gio/giomm/socketsource.cc
index af1e974..4284261 100644
--- a/gio/giomm/socketsource.cc
+++ b/gio/giomm/socketsource.cc
@@ -31,7 +31,7 @@ giomm_generic_socket_callback(sigc::slot_base* slot, GIOCondition condition)
   try
   {
     // Recreate the specific slot from the generic slot node.
-    return (*static_cast<sigc::slot<bool, Glib::IOCondition>*>(slot))((Glib::IOCondition)condition);
+    return (*static_cast<sigc::slot<bool(Glib::IOCondition)>*>(slot))((Glib::IOCondition)condition);
   }
   catch (...)
   {
@@ -66,7 +66,7 @@ inline SignalSocket::SignalSocket(GMainContext* context) : context_(context)
 }
 
 sigc::connection
-SignalSocket::connect(const sigc::slot<bool, Glib::IOCondition>& slot,
+SignalSocket::connect(const sigc::slot<bool(Glib::IOCondition)>& slot,
   const Glib::RefPtr<Socket>& socket, Glib::IOCondition condition,
   const Glib::RefPtr<Cancellable>& cancellable, int priority)
 {
diff --git a/gio/giomm/socketsource.h b/gio/giomm/socketsource.h
index c1345c6..feadfb0 100644
--- a/gio/giomm/socketsource.h
+++ b/gio/giomm/socketsource.h
@@ -69,7 +69,7 @@ public:
    * @param priority The priority of the new event source.
    * @return A connection handle, which can be used to disconnect the handler.
    */
-  sigc::connection connect(const sigc::slot<bool, Glib::IOCondition>& slot,
+  sigc::connection connect(const sigc::slot<bool(Glib::IOCondition)>& slot,
     const Glib::RefPtr<Socket>& socket, Glib::IOCondition condition,
     const Glib::RefPtr<Cancellable>& cancellable = Glib::RefPtr<Cancellable>(),
     int priority = Glib::PRIORITY_DEFAULT);
diff --git a/glib/glibmm/dispatcher.cc b/glib/glibmm/dispatcher.cc
index e21914a..83da346 100644
--- a/glib/glibmm/dispatcher.cc
+++ b/glib/glibmm/dispatcher.cc
@@ -527,13 +527,13 @@ Dispatcher::operator()()
 }
 
 sigc::connection
-Dispatcher::connect(const sigc::slot<void>& slot)
+Dispatcher::connect(const sigc::slot<void()>& slot)
 {
   return signal_.connect(slot);
 }
 
 sigc::connection
-Dispatcher::connect(sigc::slot<void>&& slot)
+Dispatcher::connect(sigc::slot<void()>&& slot)
 {
   return signal_.connect(std::move(slot));
 }
diff --git a/glib/glibmm/dispatcher.h b/glib/glibmm/dispatcher.h
index e3b0d18..2109560 100644
--- a/glib/glibmm/dispatcher.h
+++ b/glib/glibmm/dispatcher.h
@@ -30,7 +30,7 @@ class DispatchNotifier;
 
 /** Signal class for inter-thread communication.
  * @ingroup Threads
- * Glib::Dispatcher works similar to sigc::signal<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.
@@ -88,13 +88,13 @@ public:
   void emit();
   void operator()();
 
-  sigc::connection connect(const sigc::slot<void>& slot);
+  sigc::connection connect(const sigc::slot<void()>& slot);
   /** @newin{2,48}
    */
-  sigc::connection connect(sigc::slot<void>&& slot);
+  sigc::connection connect(sigc::slot<void()>&& slot);
 
 private:
-  sigc::signal<void> signal_;
+  sigc::signal<void()> signal_;
   DispatchNotifier* notifier_;
 
 #ifndef DOXYGEN_SHOULD_SKIP_THIS
diff --git a/glib/glibmm/exceptionhandler.cc b/glib/glibmm/exceptionhandler.cc
index 95032a3..7a16c78 100644
--- a/glib/glibmm/exceptionhandler.cc
+++ b/glib/glibmm/exceptionhandler.cc
@@ -90,7 +90,7 @@ namespace Glib
 {
 
 sigc::connection
-add_exception_handler(const sigc::slot<void>& slot)
+add_exception_handler(const sigc::slot<void()>& slot)
 {
 #ifdef GLIBMM_CAN_USE_THREAD_LOCAL
   HandlerList* handler_list = thread_specific_handler_list;
diff --git a/glib/glibmm/exceptionhandler.h b/glib/glibmm/exceptionhandler.h
index 89c169b..acfd6f5 100644
--- a/glib/glibmm/exceptionhandler.h
+++ b/glib/glibmm/exceptionhandler.h
@@ -29,7 +29,7 @@ namespace Glib
 
 /** Specify a slot to be called when an exception is thrown by a signal handler.
  */
-sigc::connection add_exception_handler(const sigc::slot<void>& slot);
+sigc::connection add_exception_handler(const sigc::slot<void()>& slot);
 
 #ifndef DOXYGEN_SHOULD_SKIP_THIS
 // internal
diff --git a/glib/glibmm/main.cc b/glib/glibmm/main.cc
index 2b0cb8e..06521a4 100644
--- a/glib/glibmm/main.cc
+++ b/glib/glibmm/main.cc
@@ -230,7 +230,7 @@ glibmm_source_callback(void* data)
   try
   {
     // Recreate the specific slot from the generic slot node.
-    return (*static_cast<sigc::slot<bool>*>(conn_data->get_slot()))();
+    return (*static_cast<sigc::slot<bool()>*>(conn_data->get_slot()))();
   }
   catch (...)
   {
@@ -251,7 +251,7 @@ glibmm_source_callback_once(void* data)
   try
   {
     // Recreate the specific slot from the generic slot node.
-    (*static_cast<sigc::slot<void>*>(conn_data->get_slot()))();
+    (*static_cast<sigc::slot<void()>*>(conn_data->get_slot()))();
   }
   catch (...)
   {
@@ -276,7 +276,7 @@ glibmm_iosource_callback(GIOChannel*, GIOCondition condition, void* data)
   try
   {
     // Recreate the specific slot from the generic slot node.
-    return (*static_cast<sigc::slot<bool, Glib::IOCondition>*>(callback_data->node->get_slot()))(
+    return (*static_cast<sigc::slot<bool(Glib::IOCondition)>*>(callback_data->node->get_slot()))(
       (Glib::IOCondition)condition);
   }
   catch (...)
@@ -298,7 +298,7 @@ glibmm_child_watch_callback(GPid pid, gint child_status, void* data)
   try
   {
     // Recreate the specific slot from the generic slot node.
-    (*static_cast<sigc::slot<void, GPid, int>*>(conn_data->get_slot()))(pid, child_status);
+    (*static_cast<sigc::slot<void(GPid, int)>*>(conn_data->get_slot()))(pid, child_status);
   }
   catch (...)
   {
@@ -309,7 +309,7 @@ glibmm_child_watch_callback(GPid pid, gint child_status, void* data)
 
 static void
 glibmm_signal_connect_once(
-  const sigc::slot<void>& slot, int priority, GSource* source, GMainContext* context)
+  const sigc::slot<void()>& slot, int priority, GSource* source, GMainContext* context)
 {
   SourceConnectionNode* const conn_node = new SourceConnectionNode(slot);
 
@@ -332,7 +332,7 @@ glibmm_main_context_invoke_callback(void* data)
   try
   {
     // Recreate the specific slot from the generic slot node.
-    return (*static_cast<sigc::slot<bool>*>(slot))();
+    return (*static_cast<sigc::slot<bool()>*>(slot))();
   }
   catch (...)
   {
@@ -384,7 +384,7 @@ inline SignalTimeout::SignalTimeout(GMainContext* context) : context_(context)
 
 /* Note that this is our equivalent of g_timeout_add(). */
 sigc::connection
-SignalTimeout::connect(const sigc::slot<bool>& slot, unsigned int interval, int priority)
+SignalTimeout::connect(const sigc::slot<bool()>& slot, unsigned int interval, int priority)
 {
   SourceConnectionNode* const conn_node = new SourceConnectionNode(slot);
   const sigc::connection connection(*conn_node->get_slot());
@@ -406,7 +406,7 @@ SignalTimeout::connect(const sigc::slot<bool>& slot, unsigned int interval, int
 }
 
 void
-SignalTimeout::connect_once(const sigc::slot<void>& slot, unsigned int interval, int priority)
+SignalTimeout::connect_once(const sigc::slot<void()>& slot, unsigned int interval, int priority)
 {
   GSource* const source = g_timeout_source_new(interval);
   glibmm_signal_connect_once(slot, priority, source, context_);
@@ -414,7 +414,7 @@ SignalTimeout::connect_once(const sigc::slot<void>& slot, unsigned int interval,
 
 /* Note that this is our equivalent of g_timeout_add_seconds(). */
 sigc::connection
-SignalTimeout::connect_seconds(const sigc::slot<bool>& slot, unsigned int interval, int priority)
+SignalTimeout::connect_seconds(const sigc::slot<bool()>& slot, unsigned int interval, int priority)
 {
   SourceConnectionNode* const conn_node = new SourceConnectionNode(slot);
   const sigc::connection connection(*conn_node->get_slot());
@@ -437,7 +437,7 @@ SignalTimeout::connect_seconds(const sigc::slot<bool>& slot, unsigned int interv
 
 void
 SignalTimeout::connect_seconds_once(
-  const sigc::slot<void>& slot, unsigned int interval, int priority)
+  const sigc::slot<void()>& slot, unsigned int interval, int priority)
 {
   GSource* const source = g_timeout_source_new_seconds(interval);
   glibmm_signal_connect_once(slot, priority, source, context_);
@@ -456,7 +456,7 @@ inline SignalIdle::SignalIdle(GMainContext* context) : context_(context)
 }
 
 sigc::connection
-SignalIdle::connect(const sigc::slot<bool>& slot, int priority)
+SignalIdle::connect(const sigc::slot<bool()>& slot, int priority)
 {
   SourceConnectionNode* const conn_node = new SourceConnectionNode(slot);
   const sigc::connection connection(*conn_node->get_slot());
@@ -478,7 +478,7 @@ SignalIdle::connect(const sigc::slot<bool>& slot, int priority)
 }
 
 void
-SignalIdle::connect_once(const sigc::slot<void>& slot, int priority)
+SignalIdle::connect_once(const sigc::slot<void()>& slot, int priority)
 {
   GSource* const source = g_idle_source_new();
   glibmm_signal_connect_once(slot, priority, source, context_);
@@ -498,7 +498,7 @@ inline SignalIO::SignalIO(GMainContext* context) : context_(context)
 
 sigc::connection
 SignalIO::connect(
-  const sigc::slot<bool, IOCondition>& slot, int fd, IOCondition condition, int priority)
+  const sigc::slot<bool(IOCondition)>& slot, int fd, IOCondition condition, int priority)
 {
   const auto source = IOSource::create(fd, condition);
 
@@ -513,7 +513,7 @@ SignalIO::connect(
 }
 
 sigc::connection
-SignalIO::connect(const sigc::slot<bool, IOCondition>& slot, const Glib::RefPtr<IOChannel>& channel,
+SignalIO::connect(const sigc::slot<bool(IOCondition)>& slot, const Glib::RefPtr<IOChannel>& channel,
   IOCondition condition, int priority)
 {
   const auto source = IOSource::create(channel, condition);
@@ -541,7 +541,7 @@ inline SignalChildWatch::SignalChildWatch(GMainContext* context) : context_(cont
 }
 
 sigc::connection
-SignalChildWatch::connect(const sigc::slot<void, GPid, int>& slot, GPid pid, int priority)
+SignalChildWatch::connect(const sigc::slot<void(GPid, int)>& slot, GPid pid, int priority)
 {
   SourceConnectionNode* const conn_node = new SourceConnectionNode(slot);
   const sigc::connection connection(*conn_node->get_slot());
@@ -700,10 +700,10 @@ MainContext::remove_poll(PollFD& fd)
 }
 
 void
-MainContext::invoke(const sigc::slot<bool>& slot, int priority)
+MainContext::invoke(const sigc::slot<bool()>& slot, int priority)
 {
   // Make a copy of slot on the heap.
-  sigc::slot_base* const slot_copy = new sigc::slot<bool>(slot);
+  sigc::slot_base* const slot_copy = new sigc::slot<bool()>(slot);
 
   g_main_context_invoke_full(gobj(), priority, glibmm_main_context_invoke_callback, slot_copy,
     glibmm_main_context_invoke_destroy_notify_callback);
@@ -1171,7 +1171,7 @@ TimeoutSource::create(unsigned int interval)
 }
 
 sigc::connection
-TimeoutSource::connect(const sigc::slot<bool>& slot)
+TimeoutSource::connect(const sigc::slot<bool()>& slot)
 {
   return connect_generic(slot);
 }
@@ -1243,7 +1243,7 @@ TimeoutSource::check()
 bool
 TimeoutSource::dispatch(sigc::slot_base* slot)
 {
-  const bool again = (*static_cast<sigc::slot<bool>*>(slot))();
+  const bool again = (*static_cast<sigc::slot<bool()>*>(slot))();
 
   if (again)
   {
@@ -1268,7 +1268,7 @@ IdleSource::create()
 }
 
 sigc::connection
-IdleSource::connect(const sigc::slot<bool>& slot)
+IdleSource::connect(const sigc::slot<bool()>& slot)
 {
   return connect_generic(slot);
 }
@@ -1298,7 +1298,7 @@ IdleSource::check()
 bool
 IdleSource::dispatch(sigc::slot_base* slot)
 {
-  return (*static_cast<sigc::slot<bool>*>(slot))();
+  return (*static_cast<sigc::slot<bool()>*>(slot))();
 }
 
 /**** Glib::IOSource *******************************************************/
@@ -1317,7 +1317,7 @@ IOSource::create(const Glib::RefPtr<IOChannel>& channel, IOCondition condition)
 }
 
 sigc::connection
-IOSource::connect(const sigc::slot<bool, IOCondition>& slot)
+IOSource::connect(const sigc::slot<bool(IOCondition)>& slot)
 {
   return connect_generic(slot);
 }
@@ -1357,7 +1357,7 @@ IOSource::check()
 bool
 IOSource::dispatch(sigc::slot_base* slot)
 {
-  return (*static_cast<sigc::slot<bool, IOCondition>*>(slot))(poll_fd_.get_revents());
+  return (*static_cast<sigc::slot<bool(IOCondition)>*>(slot))(poll_fd_.get_revents());
 }
 
 } // namespace Glib
diff --git a/glib/glibmm/main.h b/glib/glibmm/main.h
index f60cc8f..4dbbf15 100644
--- a/glib/glibmm/main.h
+++ b/glib/glibmm/main.h
@@ -73,7 +73,7 @@ private:
 // and SignalIdle::connect_once():
 // See https://bugzilla.gnome.org/show_bug.cgi?id=396963 and
 // http://bugzilla.gnome.org/show_bug.cgi?id=512348 about the sigc::trackable issue.
-// It's recommended to replace sigc::slot<void>& by std::function<void()>& in
+// It's recommended to replace sigc::slot<void()>& by std::function<void()>& in
 // Threads::Thread::create() and ThreadPool::push() at the next ABI break.
 // Such a replacement would be a mixed blessing in SignalTimeout and SignalIdle.
 // In a single-threaded program auto-disconnection of trackable slots is safe
@@ -122,7 +122,7 @@ public:
    * @return A connection handle, which can be used to disconnect the handler.
    */
   sigc::connection connect(
-    const sigc::slot<bool>& slot, unsigned int interval, int priority = PRIORITY_DEFAULT);
+    const sigc::slot<bool()>& slot, unsigned int interval, int priority = PRIORITY_DEFAULT);
 
   /** Connects a timeout handler that runs only once.
    * This method takes a function pointer to a function with a void return
@@ -144,7 +144,7 @@ public:
    * @param priority The priority of the new event source.
    */
   void connect_once(
-    const sigc::slot<void>& slot, unsigned int interval, int priority = PRIORITY_DEFAULT);
+    const sigc::slot<void()>& slot, unsigned int interval, int priority = PRIORITY_DEFAULT);
 
   /** Connects a timeout handler with whole second granularity.
    *
@@ -182,7 +182,7 @@ public:
    * @newin{2,14}
    */
   sigc::connection connect_seconds(
-    const sigc::slot<bool>& slot, unsigned int interval, int priority = PRIORITY_DEFAULT);
+    const sigc::slot<bool()>& slot, unsigned int interval, int priority = PRIORITY_DEFAULT);
 
   /** Connects a timeout handler that runs only once with whole second
    *  granularity.
@@ -206,7 +206,7 @@ public:
    * @param priority The priority of the new event source.
    */
   void connect_seconds_once(
-    const sigc::slot<void>& slot, unsigned int interval, int priority = PRIORITY_DEFAULT);
+    const sigc::slot<void()>& slot, unsigned int interval, int priority = PRIORITY_DEFAULT);
 
 private:
   GMainContext* context_;
@@ -244,7 +244,7 @@ public:
    * @param priority The priority of the new event source.
    * @return A connection handle, which can be used to disconnect the handler.
    */
-  sigc::connection connect(const sigc::slot<bool>& slot, int priority = PRIORITY_DEFAULT_IDLE);
+  sigc::connection connect(const sigc::slot<bool()>& slot, int priority = PRIORITY_DEFAULT_IDLE);
 
   /** Connects an idle handler that runs only once.
    * This method takes a function pointer to a function with a void return
@@ -264,7 +264,7 @@ public:
    * @endcode
    * @param priority The priority of the new event source.
    */
-  void connect_once(const sigc::slot<void>& slot, int priority = PRIORITY_DEFAULT_IDLE);
+  void connect_once(const sigc::slot<void()>& slot, int priority = PRIORITY_DEFAULT_IDLE);
 
 private:
   GMainContext* context_;
@@ -305,7 +305,7 @@ public:
    * @param priority The priority of the new event source.
    * @return A connection handle, which can be used to disconnect the handler.
    */
-  sigc::connection connect(const sigc::slot<bool, IOCondition>& slot, int fd, IOCondition condition,
+  sigc::connection connect(const sigc::slot<bool(IOCondition)>& slot, int fd, IOCondition condition,
     int priority = PRIORITY_DEFAULT);
 
   /** Connects an I/O handler that watches an I/O channel.
@@ -334,7 +334,7 @@ public:
    * @param priority The priority of the new event source.
    * @return A connection handle, which can be used to disconnect the handler.
    */
-  sigc::connection connect(const sigc::slot<bool, IOCondition>& slot,
+  sigc::connection connect(const sigc::slot<bool(IOCondition)>& slot,
     const Glib::RefPtr<IOChannel>& channel, IOCondition condition, int priority = PRIORITY_DEFAULT);
 
 private:
@@ -366,7 +366,7 @@ public:
    * @return A connection handle, which can be used to disconnect the handler.
    */
   sigc::connection connect(
-    const sigc::slot<void, GPid, int>& slot, GPid pid, int priority = PRIORITY_DEFAULT);
+    const sigc::slot<void(GPid, int)>& slot, GPid pid, int priority = PRIORITY_DEFAULT);
 
 private:
   GMainContext* context_;
@@ -583,7 +583,7 @@ public:
    *
    * @newin{2,38}
    */
-  void invoke(const sigc::slot<bool>& slot, int priority = PRIORITY_DEFAULT);
+  void invoke(const sigc::slot<bool()>& slot, int priority = PRIORITY_DEFAULT);
 
   /** Timeout signal, attached to this MainContext.
    * @return A signal proxy; you want to use SignalTimeout::connect().
@@ -848,7 +848,7 @@ public:
   using CppObjectType = Glib::TimeoutSource;
 
   static Glib::RefPtr<TimeoutSource> create(unsigned int interval);
-  sigc::connection connect(const sigc::slot<bool>& slot);
+  sigc::connection connect(const sigc::slot<bool()>& slot);
 
 protected:
   explicit TimeoutSource(unsigned int interval);
@@ -871,7 +871,7 @@ public:
   using CppObjectType = Glib::IdleSource;
 
   static Glib::RefPtr<IdleSource> create();
-  sigc::connection connect(const sigc::slot<bool>& slot);
+  sigc::connection connect(const sigc::slot<bool()>& slot);
 
 protected:
   IdleSource();
@@ -890,7 +890,7 @@ public:
   static Glib::RefPtr<IOSource> create(int fd, IOCondition condition);
   static Glib::RefPtr<IOSource> create(
     const Glib::RefPtr<IOChannel>& channel, IOCondition condition);
-  sigc::connection connect(const sigc::slot<bool, IOCondition>& slot);
+  sigc::connection connect(const sigc::slot<bool(IOCondition)>& slot);
 
 protected:
   IOSource(int fd, IOCondition condition);
diff --git a/glib/glibmm/objectbase.cc b/glib/glibmm/objectbase.cc
index c524a16..d2a252d 100644
--- a/glib/glibmm/objectbase.cc
+++ b/glib/glibmm/objectbase.cc
@@ -353,20 +353,20 @@ ObjectBase::get_property_value(const Glib::ustring& property_name, Glib::ValueBa
 
 void
 ObjectBase::connect_property_changed(
-  const Glib::ustring& property_name, const sigc::slot<void>& slot)
+  const Glib::ustring& property_name, const sigc::slot<void()>& slot)
 {
   connect_property_changed_with_return(property_name, slot);
 }
 
 void
-ObjectBase::connect_property_changed(const Glib::ustring& property_name, sigc::slot<void>&& slot)
+ObjectBase::connect_property_changed(const Glib::ustring& property_name, sigc::slot<void()>&& slot)
 {
   connect_property_changed_with_return(property_name, std::move(slot));
 }
 
 sigc::connection
 ObjectBase::connect_property_changed_with_return(
-  const Glib::ustring& property_name, const sigc::slot<void>& slot)
+  const Glib::ustring& property_name, const sigc::slot<void()>& slot)
 {
   // Create a proxy to hold our connection info
   // This will be deleted by destroy_notify_handler.
@@ -379,7 +379,7 @@ ObjectBase::connect_property_changed_with_return(
 
 sigc::connection
 ObjectBase::connect_property_changed_with_return(
-  const Glib::ustring& property_name, sigc::slot<void>&& slot)
+  const Glib::ustring& property_name, sigc::slot<void()>&& slot)
 {
   // Create a proxy to hold our connection info
   // This will be deleted by destroy_notify_handler.
diff --git a/glib/glibmm/objectbase.h b/glib/glibmm/objectbase.h
index cf6a4a0..6cbc767 100644
--- a/glib/glibmm/objectbase.h
+++ b/glib/glibmm/objectbase.h
@@ -126,13 +126,13 @@ public:
    *
    * See also connect_property_changed_with_return().
    */
-  void connect_property_changed(const Glib::ustring& property_name, const sigc::slot<void>& slot);
+  void connect_property_changed(const Glib::ustring& property_name, const sigc::slot<void()>& slot);
 
   /** You can use the signal_changed() signal of the property proxy instead.
    *
    * @newin{2,48}
    */
-  void connect_property_changed(const Glib::ustring& property_name, sigc::slot<void>&& slot);
+  void connect_property_changed(const Glib::ustring& property_name, sigc::slot<void()>&& slot);
 
   /** You can use the signal_changed() signal of the property proxy instead.
    *
@@ -140,14 +140,14 @@ public:
    * and we could not break the ABI by changing that function.
    */
   sigc::connection connect_property_changed_with_return(
-    const Glib::ustring& property_name, const sigc::slot<void>& slot);
+    const Glib::ustring& property_name, const sigc::slot<void()>& slot);
 
   /** You can use the signal_changed() signal of the property proxy instead.
    *
    * @newin{2,48}
    */
   sigc::connection connect_property_changed_with_return(
-    const Glib::ustring& property_name, sigc::slot<void>&& slot);
+    const Glib::ustring& property_name, sigc::slot<void()>&& slot);
 
   /** Increases the freeze count on object. If the freeze count is non-zero, the
    * emission of "notify" signals on object is stopped. The signals are queued
diff --git a/glib/glibmm/propertyproxy_base.cc b/glib/glibmm/propertyproxy_base.cc
index 5b7a400..66ebf70 100644
--- a/glib/glibmm/propertyproxy_base.cc
+++ b/glib/glibmm/propertyproxy_base.cc
@@ -58,7 +58,7 @@ void PropertyProxyConnectionNode::callback(GObject*, GParamSpec* pspec, gpointer
   if (pspec && data)
   {
     if (sigc::slot_base* const slot = SignalProxyBase::data_to_slot(data))
-      (*static_cast<sigc::slot<void>*>(slot))();
+      (*static_cast<sigc::slot<void()>*>(slot))();
   }
 }
 
diff --git a/glib/glibmm/propertyproxy_base.h b/glib/glibmm/propertyproxy_base.h
index fdfb237..c5e6a53 100644
--- a/glib/glibmm/propertyproxy_base.h
+++ b/glib/glibmm/propertyproxy_base.h
@@ -39,7 +39,7 @@ public:
   SignalProxyProperty(Glib::ObjectBase* obj, const gchar* property_name);
   ~SignalProxyProperty() noexcept;
 
-  using SlotType = sigc::slot<void>;
+  using SlotType = sigc::slot<void()>;
   sigc::connection connect(const SlotType& slot);
   /** @newin{2,48}
    */
diff --git a/glib/glibmm/signalproxy.cc b/glib/glibmm/signalproxy.cc
index a7e5d9c..e7815df 100644
--- a/glib/glibmm/signalproxy.cc
+++ b/glib/glibmm/signalproxy.cc
@@ -101,7 +101,7 @@ SignalProxyNormal::slot0_void_callback(GObject* self, void* data)
     try
     {
       if (sigc::slot_base* const slot = data_to_slot(data))
-        (*static_cast<sigc::slot<void>*>(slot))();
+        (*static_cast<sigc::slot<void()>*>(slot))();
     }
     catch (...)
     {
diff --git a/glib/glibmm/signalproxy.h b/glib/glibmm/signalproxy.h
index 458e6b1..f67a4a6 100644
--- a/glib/glibmm/signalproxy.h
+++ b/glib/glibmm/signalproxy.h
@@ -153,8 +153,8 @@ template <class R, class... T>
 class SignalProxy : public SignalProxyNormal
 {
 public:
-  using SlotType = sigc::slot<R, T...>;
-  using VoidSlotType = sigc::slot<void, T...>;
+  using SlotType = sigc::slot<R(T...)>;
+  using VoidSlotType = sigc::slot<void(T...)>;
 
   SignalProxy(ObjectBase* obj, const SignalProxyInfo* info) : SignalProxyNormal(obj, info) {}
 
@@ -303,8 +303,8 @@ template <class R, class... T>
 class SignalProxyDetailedAnyType : public SignalProxyDetailed
 {
 public:
-  using SlotType = sigc::slot<R, T...>;
-  using VoidSlotType = sigc::slot<void, T...>;
+  using SlotType = sigc::slot<R(T...)>;
+  using VoidSlotType = sigc::slot<void(T...)>;
 
   SignalProxyDetailedAnyType(
     ObjectBase* obj, const SignalProxyInfo* info, const Glib::ustring& detail_name)
diff --git a/glib/glibmm/threadpool.cc b/glib/glibmm/threadpool.cc
index 75a6a7b..7070ccd 100644
--- a/glib/glibmm/threadpool.cc
+++ b/glib/glibmm/threadpool.cc
@@ -38,14 +38,14 @@ public:
   SlotList(const ThreadPool::SlotList&) = delete;
   ThreadPool::SlotList& operator=(const ThreadPool::SlotList&) = delete;
 
-  sigc::slot<void>* push(const sigc::slot<void>& slot);
-  sigc::slot<void> pop(sigc::slot<void>* slot_ptr);
+  sigc::slot<void()>* push(const sigc::slot<void()>& slot);
+  sigc::slot<void()> pop(sigc::slot<void()>* slot_ptr);
 
   void lock_and_unlock();
 
 private:
   Glib::Threads::Mutex mutex_;
-  std::list<sigc::slot<void>> list_;
+  std::list<sigc::slot<void()>> list_;
 };
 
 ThreadPool::SlotList::SlotList()
@@ -56,8 +56,8 @@ ThreadPool::SlotList::~SlotList() noexcept
 {
 }
 
-sigc::slot<void>*
-ThreadPool::SlotList::push(const sigc::slot<void>& slot)
+sigc::slot<void()>*
+ThreadPool::SlotList::push(const sigc::slot<void()>& slot)
 {
   Threads::Mutex::Lock lock(mutex_);
 
@@ -65,15 +65,15 @@ ThreadPool::SlotList::push(const sigc::slot<void>& slot)
   return &list_.back();
 }
 
-sigc::slot<void>
-ThreadPool::SlotList::pop(sigc::slot<void>* slot_ptr)
+sigc::slot<void()>
+ThreadPool::SlotList::pop(sigc::slot<void()>* slot_ptr)
 {
-  sigc::slot<void> slot;
+  sigc::slot<void()> slot;
 
   {
     Threads::Mutex::Lock lock(mutex_);
 
-    std::list<sigc::slot<void>>::iterator pslot = list_.begin();
+    std::list<sigc::slot<void()>>::iterator pslot = list_.begin();
     while (pslot != list_.end() && slot_ptr != &*pslot)
       ++pslot;
 
@@ -107,7 +107,7 @@ call_thread_entry_slot(void* data, void* user_data)
     Glib::ThreadPool::SlotList* const slot_list =
       static_cast<Glib::ThreadPool::SlotList*>(user_data);
 
-    sigc::slot<void> slot(slot_list->pop(static_cast<sigc::slot<void>*>(data)));
+    sigc::slot<void()> slot(slot_list->pop(static_cast<sigc::slot<void()>*>(data)));
 
     slot();
   }
@@ -155,9 +155,9 @@ ThreadPool::~ThreadPool() noexcept
 }
 
 void
-ThreadPool::push(const sigc::slot<void>& slot)
+ThreadPool::push(const sigc::slot<void()>& slot)
 {
-  sigc::slot<void>* const slot_ptr = slot_list_->push(slot);
+  sigc::slot<void()>* const slot_ptr = slot_list_->push(slot);
 
   GError* error = nullptr;
   g_thread_pool_push(gobject_, slot_ptr, &error);
diff --git a/glib/glibmm/threadpool.h b/glib/glibmm/threadpool.h
index f75f34d..06285f0 100644
--- a/glib/glibmm/threadpool.h
+++ b/glib/glibmm/threadpool.h
@@ -72,7 +72,7 @@ public:
   virtual ~ThreadPool() noexcept;
 
   // See http://bugzilla.gnome.org/show_bug.cgi?id=512348 about the sigc::trackable issue.
-  // TODO: At the next ABI break, consider changing const sigc::slot<void>& slot
+  // TODO: At the next ABI break, consider changing const sigc::slot<void()>& slot
   // to const std::function<void()>& func, if it can be assumed that all supported
   // compilers understand the C++11 template class std::function<>.
   /** Inserts @a slot into the list of tasks to be executed by the pool.
@@ -91,7 +91,7 @@ public:
    * couldn't be created. In that case @a slot is simply appended to the
    * queue of work to do.
    */
-  void push(const sigc::slot<void>& slot);
+  void push(const sigc::slot<void()>& slot);
 
   /** Sets the maximal allowed number of threads for the pool.
    * A value of -1 means that the maximal number of threads is unlimited.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]