aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules/dcc/dialogs.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/dcc/dialogs.cpp')
-rw-r--r--src/modules/dcc/dialogs.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/modules/dcc/dialogs.cpp b/src/modules/dcc/dialogs.cpp
index e21cce930..db09d936c 100644
--- a/src/modules/dcc/dialogs.cpp
+++ b/src/modules/dcc/dialogs.cpp
@@ -116,8 +116,8 @@ void KviDccAcceptBox::closeEvent(QCloseEvent *e)
void KviDccAcceptBox::showEvent(QShowEvent *e)
{
- move((g_pApp->desktop()->width() - width()) >> 1,
- (g_pApp->desktop()->height() - height()) >> 1);
+ QRect rect = g_pApp->desktop()->screenGeometry(g_pApp->desktop()->primaryScreen());
+ move((rect.width() - width())/2,(rect.height() - height())/2);
QWidget::showEvent(e);
}