This is mostly a duplicate of `LauncherModel::itemInModel()` except for the thing that is returned. Maybe we can combine both function bodies to a private function that iterates over the model? e.g. `int findItem(const QString &path, LauncherItem **item)` that returns the index and - if `item` is non-`NULL` - returns the item there, then implement both functions like this:

```
int LauncherModel::findItem(const QString &path, LauncherItem **item)
{
   ...
}

LauncherItem *LauncherModel::itemInModel(const QString &path)
{
    LauncherItem *result = 0;
    (void)findItem(path, &result);
    return result;
}

int LauncherModel::indexInModel(const QString &path)
{
    return findItem(path, 0);
}
```