fix kgraphviewerpart creation

fix from Sandro Andrade <sandroandrade@kde.org>