From 39b73acecd566981f40b28db516b03095c61cc86 Mon Sep 17 00:00:00 2001 From: Steffen Imhof Date: Mon, 16 Feb 2009 16:27:18 +0100 Subject: [PATCH] Bug 464050 - Focus handling prevents text selection by mouse; r=vladimir --- widget/src/qt/nsWindow.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/widget/src/qt/nsWindow.cpp b/widget/src/qt/nsWindow.cpp index 726a24b47a0f..19a80d28edf1 100644 --- a/widget/src/qt/nsWindow.cpp +++ b/widget/src/qt/nsWindow.cpp @@ -1811,6 +1811,12 @@ nsWindow::NativeCreate(nsIWidget *aParent, Initialize(mDrawingArea); + // disable focus handling for secondary windows (problems with mouse selection and NS_ACTIVATE) + if (aParent != nsnull) + { + mDrawingArea->setFocusPolicy(Qt::NoFocus); + } + LOG(("Create: nsWindow [%p] [%p]\n", (void *)this, (void *)mDrawingArea)); // resize so that everything is set to the right dimensions