don't really need our own copy ctor here, as that was just so i could see when it was getting called; also be more careful in operator=. still getting an odd crash in there though from krunner
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=805669
This commit is contained in:
parent
61ae3df3fc
commit
b97d911e56
@ -44,20 +44,6 @@ class QueryMatch::Private : public QSharedData
|
||||
{
|
||||
}
|
||||
|
||||
Private(const Private &other)
|
||||
{
|
||||
kDebug() << "copy";
|
||||
runner = other.runner;
|
||||
type = other.type;
|
||||
id = other.id;
|
||||
text = other.text;
|
||||
subtext = other.subtext;
|
||||
icon = other.icon;
|
||||
data = other.data;
|
||||
enabled = other.enabled;
|
||||
relevance = other.relevance;
|
||||
}
|
||||
|
||||
QPointer<AbstractRunner> runner;
|
||||
QueryMatch::Type type;
|
||||
QString id;
|
||||
@ -73,7 +59,7 @@ class QueryMatch::Private : public QSharedData
|
||||
QueryMatch::QueryMatch(AbstractRunner *runner)
|
||||
: d(new Private(runner))
|
||||
{
|
||||
if (d->runner) {
|
||||
if (runner) {
|
||||
d->id = runner->id();
|
||||
}
|
||||
// kDebug() << "new match created";
|
||||
@ -193,8 +179,11 @@ bool QueryMatch::operator<(const QueryMatch& other) const
|
||||
|
||||
QueryMatch& QueryMatch::operator=(const QueryMatch &other)
|
||||
{
|
||||
kDebug();
|
||||
d = other.d;
|
||||
if (d != other.d) {
|
||||
kDebug();
|
||||
d = other.d;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user