|
|
|
@ -1279,7 +1279,7 @@ void SearchDlg::slotOpen()
|
|
|
|
|
}
|
|
|
|
|
else if (item->uri().startsWith("knotes:/") )
|
|
|
|
|
{
|
|
|
|
|
slotOpenKNotes(item->uri().mid(9,22));
|
|
|
|
|
slotOpenKNotes(item->uri().mid(10,21));
|
|
|
|
|
}
|
|
|
|
|
else if (item->uri().startsWith("note:/")) {
|
|
|
|
|
KProcess *proc = new KProcess;
|
|
|
|
@ -1344,13 +1344,12 @@ void SearchDlg::slotOpenKAddressBook(const QString &uid)
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void SearchDlg::slotOpenKNotes(const QString ¬eid)
|
|
|
|
|
void SearchDlg::slotOpenKNotes(const QString& noteid)
|
|
|
|
|
{
|
|
|
|
|
if (ensureServiceRunning("knotes")) {
|
|
|
|
|
QByteArray data;
|
|
|
|
|
QDataStream arg(data, IO_WriteOnly);
|
|
|
|
|
arg << noteid;
|
|
|
|
|
|
|
|
|
|
kapp->dcopClient()->send("knotes","KNotesIface","showNote(QString)", data);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -1817,8 +1816,13 @@ static QLabel* dateSwitches[dateSwitchesCount] = {showAnyDate, showToday, showSi
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bool SearchDlg::ensureServiceRunning(const QString & name)
|
|
|
|
|
bool SearchDlg::ensureServiceRunning(const QString& name)
|
|
|
|
|
{
|
|
|
|
|
QCString appname = name.utf8();
|
|
|
|
|
if (kapp->dcopClient()->isApplicationRegistered(appname)) {
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
else {
|
|
|
|
|
QStringList URLs;
|
|
|
|
|
QByteArray data, replyData;
|
|
|
|
|
QCString replyType;
|
|
|
|
@ -1847,6 +1851,7 @@ bool SearchDlg::ensureServiceRunning(const QString & name)
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#include "searchdlg.moc"
|
|
|
|
|