Removed old-style casting warnings
Summary: To remove the 'old-style casting' warnings, replaced the old (type) cast to static_cast, dynamic_cast or reinterpret_cast
Reviewers: tcanabrava, rizzitello
Reviewed By: tcanabrava, rizzitello
Subscribers: apol, yurchor, kde-edu
Tags: KDE Edu
Differential Revision: https://phabricator.kde.org/D16863