summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qcocoaview_mac.mm
diff options
context:
space:
mode:
authorFabien Freling <fabien.freling@nokia.com>2011-03-15 14:09:06 (GMT)
committerFabien Freling <fabien.freling@nokia.com>2011-03-15 14:09:06 (GMT)
commitb36f947147e3f5acf444c94d6e2a608506b7e753 (patch)
treea0bf253b8e315305cfada01871f3a1cbf54aef43 /src/gui/kernel/qcocoaview_mac.mm
parentd524e983c60ba59f3c65d811ec92f02c97d1a8ab (diff)
parentc0cd8db0498daaa8151d1f80143b6849016bdc7c (diff)
downloadQt-b36f947147e3f5acf444c94d6e2a608506b7e753.zip
Qt-b36f947147e3f5acf444c94d6e2a608506b7e753.tar.gz
Qt-b36f947147e3f5acf444c94d6e2a608506b7e753.tar.bz2
Merge remote branch 'mainline/master' into merge_raster
Diffstat (limited to 'src/gui/kernel/qcocoaview_mac.mm')
-rw-r--r--src/gui/kernel/qcocoaview_mac.mm4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/kernel/qcocoaview_mac.mm b/src/gui/kernel/qcocoaview_mac.mm
index 976612e..43eb072 100644
--- a/src/gui/kernel/qcocoaview_mac.mm
+++ b/src/gui/kernel/qcocoaview_mac.mm
@@ -858,7 +858,7 @@ static int qCocoaViewCount = 0;
- (BOOL)resignFirstResponder
{
if (!qwidget)
- return NO;
+ return YES;
// Seems like the following test only triggers if this
// view is inside a QMacNativeWidget:
@@ -1044,7 +1044,7 @@ static int qCocoaViewCount = 0;
QString qtText;
// Cursor position is retrived from the range.
QList<QInputMethodEvent::Attribute> attrs;
- attrs<<QInputMethodEvent::Attribute(QInputMethodEvent::Cursor, selRange.location, 1, QVariant());
+ attrs<<QInputMethodEvent::Attribute(QInputMethodEvent::Cursor, selRange.location + selRange.length, 1, QVariant());
if ([aString isKindOfClass:[NSAttributedString class]]) {
qtText = QCFString::toQString(reinterpret_cast<CFStringRef>([aString string]));
composingLength = qtText.length();