try harder to maximize the dialog window

This commit is contained in:
Marco Martin 2012-01-09 17:22:09 +01:00
parent c0c231773b
commit e9188f712a
2 changed files with 3 additions and 0 deletions

View File

@ -203,7 +203,9 @@ void FullScreenDialog::setVisible(const bool visible)
if (m_view->isVisible() != visible) {
m_view->setVisible(visible);
if (visible) {
unsigned long state = NET::Sticky | NET::StaysOnTop | NET::KeepAbove | NET::SkipTaskbar | NET::SkipPager | NET::MaxVert | NET::MaxHoriz;
m_view->setVisible(visible);
KWindowSystem::setState(m_view->effectiveWinId(), state);
m_view->raise();
}
}

View File

@ -97,6 +97,7 @@ void PlasmaComponentsPlugin::registerTypes(const char *uri)
qmlRegisterType<QMenuProxy>(uri, 0, 1, "Menu");
qmlRegisterType<QMenuItem>(uri, 0, 1, "MenuItem");
//on touch systems the dialog is fullscreen, c++ needed to do that
} else {
qmlRegisterType<FullScreenDialog>(uri, 0, 1, "Dialog");
}