summaryrefslogtreecommitdiffstats
path: root/src/widgets
diff options
context:
space:
mode:
authorRichard Moe Gustavsen <richard.gustavsen@theqtcompany.com>2016-04-19 13:01:12 +0200
committerRichard Moe Gustavsen <richard.gustavsen@theqtcompany.com>2016-04-25 05:56:01 +0000
commit2a740b9cf59b2a343d19b2a45614ee2827c98da2 (patch)
tree169f65f9830dc75ffa329a7675b2b5b5c248287f /src/widgets
parent1b5bc9723c0b23ca5197097c3087df6bbe024a2a (diff)
Darwin: set SH_BlinkCursorWhenTextSelected to false on Darwin
When text is selected on e.g iOS or OS X, the cursor should not blink (or be visible), regardless of style. Note that SH_BlinkCursorWhenTextSelected is actually implemented to mean "hide cursor when text selected" in e.g QWidgetTextControl. If this is a bug or not is hard to say, but it is anyway the desired behavior on Apple platforms. Change-Id: I541dabbe1945c266107ba39e3adb006bec0258bf Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
Diffstat (limited to 'src/widgets')
-rw-r--r--src/widgets/styles/qcommonstyle.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/widgets/styles/qcommonstyle.cpp b/src/widgets/styles/qcommonstyle.cpp
index 437becbf70..e8062e9f9e 100644
--- a/src/widgets/styles/qcommonstyle.cpp
+++ b/src/widgets/styles/qcommonstyle.cpp
@@ -4974,7 +4974,11 @@ int QCommonStyle::styleHint(StyleHint sh, const QStyleOption *opt, const QWidget
break;
case SH_BlinkCursorWhenTextSelected:
+#if defined(Q_OS_DARWIN)
+ ret = 0;
+#else
ret = 1;
+#endif
break;
case SH_Table_GridLineColor: