Fix broken build without baloo-widgets master
D11245 introduced a dependency on baloo-widgets master, but baloo-widgets is only an optional dependency.