Be explicit on what the ViewContainer accepts

Summary:
This is needed to clean up a bit of the code later.
being really explicit here removes the need to handle
QWidget pointers, as that could in theory be anything

Handling only TerminalDisplays* we can remove the
SessionController map from the ViewContainer and
add it to the TerminalDisplay class in the future

Reviewers: #konsole, hindenburg

Reviewed By: #konsole, hindenburg

Subscribers: konsole-devel

Tags: #konsole

Differential Revision: https://phabricator.kde.org/D17492
This commit is contained in:
Tomaz Canabrava
2018-12-12 10:25:44 -05:00
committed by Kurt Hindenburg
parent f2fab9a26a
commit 6406a66a91
3 changed files with 57 additions and 68 deletions

View File

@@ -882,8 +882,8 @@ QList<ViewProperties *> ViewManager::viewProperties() const
list.reserve(container->count());
for(int i = 0, end = container->count(); i < end; i++) {
auto view = container->widget(i);
ViewProperties *properties = container->viewProperties(view);
auto view = container->terminalAt(i);
ViewProperties *properties = view->sessionController();
Q_ASSERT(properties);
list << properties;
}