- RS_CHG_AFTER_NOTIFIER(REMOTE_SCRIPT & r, USER_PTR u) : user(u), rs(r) {}
- void Notify(const varParamType & oldValue, const varParamType & newValue);
- USER_PTR GetUser() {return user; }
+ CONNECTED_NOTIFIER(REMOTE_SCRIPT & r, UserPtr u)
+ : user(u), rs(r) { user->AddConnectedAfterNotifier(this); }
+ CONNECTED_NOTIFIER(const CONNECTED_NOTIFIER & rhs)
+ : user(rhs.user), rs(rhs.rs) { user->AddConnectedAfterNotifier(this); }
+ ~CONNECTED_NOTIFIER() { user->DelConnectedAfterNotifier(this); }
+
+ CONNECTED_NOTIFIER & operator=(const CONNECTED_NOTIFIER & rhs)
+ {
+ user->DelConnectedAfterNotifier(this);
+ user = rhs.user;
+ user->AddConnectedAfterNotifier(this);
+ return *this;
+ }
+
+ void Notify(const bool & oldValue, const bool & newValue);
+ UserPtr GetUser() const { return user; }