projects
/
quassel.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
As preparation for revamping the whole networking stuff, I did two renames:
[quassel.git]
/
src
/
common
/
ircuser.cpp
diff --git
a/src/common/ircuser.cpp
b/src/common/ircuser.cpp
index
a313fc6
..
f6818b9
100644
(file)
--- a/
src/common/ircuser.cpp
+++ b/
src/common/ircuser.cpp
@@
-21,20
+21,20
@@
#include "ircuser.h"
#include "util.h"
#include "ircuser.h"
#include "util.h"
-#include "network
info
.h"
+#include "network.h"
#include "signalproxy.h"
#include "ircchannel.h"
#include <QTextCodec>
#include <QDebug>
#include "signalproxy.h"
#include "ircchannel.h"
#include <QTextCodec>
#include <QDebug>
-IrcUser::IrcUser(const QString &hostmask, Network
Info *networkinfo
)
- : SyncableObject(network
info
),
+IrcUser::IrcUser(const QString &hostmask, Network
*network
)
+ : SyncableObject(network),
_initialized(false),
_nick(nickFromMask(hostmask)),
_user(userFromMask(hostmask)),
_host(hostFromMask(hostmask)),
_initialized(false),
_nick(nickFromMask(hostmask)),
_user(userFromMask(hostmask)),
_host(hostFromMask(hostmask)),
-
networkInfo(networkinfo
),
+
_network(network
),
_codecForEncoding(0),
_codecForDecoding(0)
{
_codecForEncoding(0),
_codecForDecoding(0)
{
@@
-81,6
+81,10
@@
QStringList IrcUser::channels() const {
return chanList;
}
return chanList;
}
+Network* IrcUser::network() const {
+ return _network;
+}
+
QTextCodec *IrcUser::codecForEncoding() const {
return _codecForEncoding;
}
QTextCodec *IrcUser::codecForEncoding() const {
return _codecForEncoding;
}
@@
-106,7
+110,7
@@
void IrcUser::setCodecForDecoding(QTextCodec *codec) {
}
QString IrcUser::decodeString(const QByteArray &text) const {
}
QString IrcUser::decodeString(const QByteArray &text) const {
- if(!codecForDecoding()) return network
Info
->decodeString(text);
+ if(!codecForDecoding()) return network
()
->decodeString(text);
return ::decodeString(text, codecForDecoding());
}
return ::decodeString(text, codecForDecoding());
}
@@
-114,7
+118,7
@@
QByteArray IrcUser::encodeString(const QString string) const {
if(codecForEncoding()) {
return codecForEncoding()->fromUnicode(string);
}
if(codecForEncoding()) {
return codecForEncoding()->fromUnicode(string);
}
- return network
Info
->encodeString(string);
+ return network
()
->encodeString(string);
}
// ====================
}
// ====================
@@
-143,7
+147,7
@@
void IrcUser::setNick(const QString &nick) {
}
void IrcUser::updateObjectName() {
}
void IrcUser::updateObjectName() {
- QString newName = QString::number(network
Info
->networkId()) + "/" + _nick;
+ QString newName = QString::number(network
()
->networkId()) + "/" + _nick;
QString oldName = objectName();
if(oldName != newName) {
setObjectName(newName);
QString oldName = objectName();
if(oldName != newName) {
setObjectName(newName);
@@
-172,7
+176,7
@@
void IrcUser::joinChannel(IrcChannel *channel) {
}
void IrcUser::joinChannel(const QString &channelname) {
}
void IrcUser::joinChannel(const QString &channelname) {
- joinChannel(network
Info
->newIrcChannel(channelname));
+ joinChannel(network
()
->newIrcChannel(channelname));
}
void IrcUser::partChannel(IrcChannel *channel) {
}
void IrcUser::partChannel(IrcChannel *channel) {
@@
-185,7
+189,7
@@
void IrcUser::partChannel(IrcChannel *channel) {
}
void IrcUser::partChannel(const QString &channelname) {
}
void IrcUser::partChannel(const QString &channelname) {
- IrcChannel *channel = network
Info
->ircChannel(channelname);
+ IrcChannel *channel = network
()
->ircChannel(channelname);
if(channel == 0) {
qWarning() << "IrcUser::partChannel(): received part for unknown Channel" << channelname;
} else {
if(channel == 0) {
qWarning() << "IrcUser::partChannel(): received part for unknown Channel" << channelname;
} else {