-rw-r--r-- | core/launcher/launcherview.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/core/launcher/launcherview.cpp b/core/launcher/launcherview.cpp index fa46543..6e63fca 100644 --- a/core/launcher/launcherview.cpp +++ b/core/launcher/launcherview.cpp | |||
@@ -487,27 +487,26 @@ bool LauncherIconView::removeLink(const QString& linkfile) | |||
487 | LauncherItem* item = (LauncherItem*)firstItem(); | 487 | LauncherItem* item = (LauncherItem*)firstItem(); |
488 | AppLnk* l; | 488 | AppLnk* l; |
489 | bool did = FALSE; | 489 | bool did = FALSE; |
490 | DocLnk dl(linkfile); | 490 | DocLnk dl(linkfile); |
491 | while (item) { | 491 | while (item) { |
492 | l = item->appLnk(); | 492 | l = item->appLnk(); |
493 | if ( l->linkFileKnown() && l->linkFile() == linkfile | 493 | if ( ( l->linkFileKnown() && ( l->linkFile() == linkfile )) |
494 | || l->fileKnown() && ( | 494 | || ( l->fileKnown() && ( l->file() == linkfile )) |
495 | l->file() == linkfile | 495 | || ( dl.fileKnown() && l->fileKnown() && ( dl.file() == l->file() )) ) { |
496 | || dl.isValid() && dl.file() == l->file() ) ) { | ||
497 | delete item; | 496 | delete item; |
498 | did = TRUE; | 497 | did = TRUE; |
499 | } | 498 | } |
500 | item = (LauncherItem*)item->nextItem(); | 499 | item = (LauncherItem*)item->nextItem(); |
501 | } | 500 | } |
502 | QListIterator<AppLnk> it(hidden); | 501 | QListIterator<AppLnk> it(hidden); |
503 | while ((l=it.current())) { | 502 | while ((l=it.current())) { |
504 | ++it; | 503 | ++it; |
505 | if ( l->linkFileKnown() && l->linkFile() == linkfile | 504 | if ( ( l->linkFileKnown() && ( l->linkFile() == linkfile )) |
506 | || l->file() == linkfile | 505 | || ( l->file() == linkfile ) |
507 | || dl.isValid() && dl.file() == l->file() ) { | 506 | || ( dl.fileKnown() && ( dl.file() == l->file() )) ) { |
508 | hidden.removeRef(l); | 507 | hidden.removeRef(l); |
509 | did = TRUE; | 508 | did = TRUE; |
510 | } | 509 | } |
511 | } | 510 | } |
512 | return did; | 511 | return did; |
513 | } | 512 | } |