summaryrefslogtreecommitdiffstats
path: root/abs/core/mythtv/stable-0.27/mythtv/fixQTvirtualkeyboard.patch
blob: 1688bd6de9f757e47b6e99fc7fc212c85ec46668 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
--- src/mythtv/libs/libmythui/mythmainwindow.cpp.orig	2015-08-19 21:24:59.990554429 +0000
+++ src/mythtv/libs/libmythui/mythmainwindow.cpp	2015-08-19 21:23:33.851546588 +0000
@@ -1380,7 +1380,7 @@
             .arg(::GetCurrentThreadId()));
 #endif
     if (currentWidget())
-    {
+#ifdef Q_OS_MAC
         // don't disable the current widget, instead we disable all its children
         // on mac, disabling the current active widget entirely prevent keyboard to
         // work on the newly opened widget.
@@ -1395,8 +1395,9 @@
                 d->enabledWidgets[w] = true;
             }
         }
-    }
-
+#else
+        currentWidget()->setEnabled(false);
+#endif
     d->widgetList.push_back(child);
     child->winId();
     child->raise();
@@ -1419,11 +1420,8 @@
     d->widgetList.erase(it);
     QWidget *current = currentWidget();
     if (!current)
-    {
         current = this;
-        // We're be to the main window, enable it just in case
-        setEnabled(true);
-    }
+#ifdef Q_OS_MAC
     else
     {
         QList<QWidget*> list = current->findChildren<QWidget *>();
@@ -1438,6 +1436,8 @@
         }
     }
     current->raise();
+#endif
+    current->setEnabled(true);
     current->setFocus();
     current->setMouseTracking(true);