Adding a link from the browser now starts RetroShare when it is not running.

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@4157 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
thunder2 2011-04-14 23:58:30 +00:00
parent 20fa00c40e
commit 099cc6c11c
5 changed files with 19 additions and 17 deletions

View file

@ -91,18 +91,10 @@ bool EventReceiver::start()
return result;
}
void EventReceiver::showNoRunningInstanceFound()
{
QMessageBox mb(QMessageBox::Critical, "RetroShare", QObject::tr("No running instance of RetroShare found."), QMessageBox::Ok);
mb.setWindowIcon(QIcon(":/images/rstray3.png"));
mb.exec();
}
bool EventReceiver::sendRetroShareLink(const QString& link)
{
if (!sharedMMemory.attach()) {
/* No running instance found */
showNoRunningInstanceFound();
return false;
}
@ -122,7 +114,6 @@ bool EventReceiver::sendRetroShareLink(const QString& link)
SendMessage((HWND) info->wid, WM_COPYDATA, (WPARAM) 0, (LPARAM) (PCOPYDATASTRUCT) &send);
} else {
showNoRunningInstanceFound();
result = false;
}
#else