Skip to content

Commit bd38451

Browse files
author
Kjell Ahlstedt
committed
slot_rep: Fix the notify_slot_rep_invalidated() name in comments
slot_rep::notify() has been renamed to notify_slot_rep_invalidated(), but the name was not updated in all comments.
1 parent 1e258cf commit bd38451

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

sigc++/functors/slot.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ class slot<T_return(T_arg...)> : public slot_base
250250
* the outer slot as the parent of the inner slot. The second overload, called from
251251
* the destructor or destroy() of the outer slot, unsets the parent of the inner slot.
252252
* When an object referenced from the inner slot is deleted, the inner slot calls
253-
* its slot_rep::disconnect(), which calls the outer slot's slot_rep::notify().
253+
* its slot_rep::disconnect(), which calls the outer slot's slot_rep::notify_slot_rep_invalidated().
254254
* The outer slot is informed just as if one of its directly referenced objects
255255
* had been deleted. Result: The outer slot is disconnected from its parent,
256256
* if any (for instance a sigc::signal).

sigc++/functors/slot_base.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ slot_base::delete_rep_with_check()
153153
return;
154154

155155
// Make sure we are notified if disconnect() deletes rep_, which is trackable.
156-
// Compare slot_rep::notify().
156+
// Compare slot_rep::notify_slot_rep_invalidated().
157157
sigc::internal::weak_raw_ptr<rep_type> notifier(rep_);
158158
rep_->disconnect(); // Disconnect the slot (might lead to deletion of rep_!).
159159

sigc++/functors/slot_base.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,13 +41,13 @@ using hook = void* (*)(void*);
4141
* The base class slot_rep serves the purpose to
4242
* - form a common pointer type (slot_rep*),
4343
* - offer the possibility to create duplicates (clone()),
44-
* - offer a notification callback (notify()),
44+
* - offer a notification callback (notify_slot_rep_invalidated()),
4545
* - implement some of slot_base's interface that depends
4646
* on the notification callback, i.e.
4747
* -# the possibility to set a single parent with a callback
48-
* (set_parent()) that is executed from notify(),
48+
* (set_parent()) that is executed from notify_slot_rep_invalidated(),
4949
* -# a generic function pointer, call_, that is simply
50-
* set to zero in notify() to invalidate the slot.
50+
* set to zero in notify_slot_rep_invalidated() to invalidate the slot.
5151
*
5252
* slot_rep inherits trackable so that connection objects can
5353
* refer to the slot and are notified when the slot is destroyed.
@@ -93,7 +93,7 @@ struct SIGC_API slot_rep : public trackable
9393
/** Set the parent with a callback.
9494
* slots have one parent exclusively.
9595
* @param parent The new parent.
96-
* @param cleanup The callback to execute from notify().
96+
* @param cleanup The callback to execute from notify_slot_rep_invalidated().
9797
*/
9898
inline void set_parent(notifiable* parent, notifiable::func_destroy_notify cleanup) noexcept
9999
{
@@ -138,7 +138,7 @@ struct SIGC_API slot_rep : public trackable
138138
};
139139

140140
/** Functor used to add a dependency to a trackable.
141-
* Consequently slot_rep::notify() gets executed when the
141+
* Consequently slot_rep::notify_slot_rep_invalidated() gets executed when the
142142
* trackable is destroyed or overwritten.
143143
*/
144144
struct SIGC_API slot_do_bind

0 commit comments

Comments
 (0)