Finally! All *Id types are now first-class types rather than tpyedefs.
[quassel.git] / src / common / ircchannel.cpp
index 12f70c2..e6c809f 100644 (file)
@@ -40,7 +40,7 @@ IrcChannel::IrcChannel(const QString &channelname, Network *network)
     _topic(QString()),
     network(network)
 {
-  setObjectName(QString::number(network->networkId()) + "/" +  channelname);
+  setObjectName(QString::number(network->networkId().toInt()) + "/" +  channelname);
 }
 
 IrcChannel::~IrcChannel() {
@@ -73,10 +73,6 @@ bool IrcChannel::isValidChannelUserMode(const QString &mode) const {
   return isvalid;
 }
 
-bool IrcChannel::initialized() const {
-  return _initialized;
-}
-
 QString IrcChannel::name() const {
   return _name;
 }
@@ -169,6 +165,8 @@ void IrcChannel::part(IrcUser *ircuser) {
     // if you wonder why there is no counterpart to ircUserParted:
     // the joines are propagted by the ircuser. the signal ircUserParted is only for convenience
     emit ircUserParted(ircuser);
+    if(network->isMe(ircuser))
+       deleteLater();
   }
 }
 
@@ -256,8 +254,3 @@ void IrcChannel::ircUserNickSet(QString nick) {
   emit ircUserNickSet(ircUser, nick);
 }
 
-void IrcChannel::setInitialized() {
-  _initialized = true;
-  emit initDone();
-}
-