projects
/
quassel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Some more tweaking for QuasselTopia.
[quassel.git]
/
src
/
client
/
buffer.cpp
diff --git
a/src/client/buffer.cpp
b/src/client/buffer.cpp
index
b0e2862
..
b533dd6
100644
(file)
--- a/
src/client/buffer.cpp
+++ b/
src/client/buffer.cpp
@@
-107,12
+107,12
@@
QVariantMap Buffer::nickList() const {
}
QString Buffer::topic() const {
}
QString Buffer::topic() const {
- // FIXME check if we got a networkInfo() object
+ if(ircChannel()) return ircChannel()->topic();
return QString();
}
QString Buffer::ownNick() const {
return QString();
}
QString Buffer::ownNick() const {
- // FIXME
check if we got a networkInfo() object
+ // FIXME
if(ircChannel()) return ircChannel()->ownNick();
return QString();
}
return QString();
}
@@
-159,12
+159,14
@@
IrcChannel *Buffer::ircChannel() const {
return _ircChannel;
}
return _ircChannel;
}
-void Buffer::setIrcChannel(IrcChannel *ircchan) {
return;
+void Buffer::setIrcChannel(IrcChannel *ircchan) {
if(_ircChannel) {
disconnect(_ircChannel, 0, this, 0);
}
_ircChannel = ircchan;
if(_ircChannel) {
if(_ircChannel) {
disconnect(_ircChannel, 0, this, 0);
}
_ircChannel = ircchan;
if(_ircChannel) {
+ emit topicSet(_ircChannel->topic());
+ connect(_ircChannel, SIGNAL(topicSet(QString)), this, SIGNAL(topicSet(QString)));
connect(_ircChannel, SIGNAL(destroyed()), this, SLOT(setIrcChannel()));
}
_nickModel->setIrcChannel(ircChannel());
connect(_ircChannel, SIGNAL(destroyed()), this, SLOT(setIrcChannel()));
}
_nickModel->setIrcChannel(ircChannel());
@@
-172,11
+174,6
@@
void Buffer::setIrcChannel(IrcChannel *ircchan) { return;
// no longer needed
// back reference:
// no longer needed
// back reference:
-// void Buffer::setTopic(QString t) {
-// _topic = t;
-// emit topicSet(t);
-// emit bufferUpdated(this);
-// }
// void Buffer::addNick(QString nick, QVariantMap props) {
// if(nick == ownNick()) setActive(true);
// void Buffer::addNick(QString nick, QVariantMap props) {
// if(nick == ownNick()) setActive(true);