summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/android
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2020-06-19 20:53:25 +0200
committerLars Knoll <lars.knoll@qt.io>2020-07-06 21:31:14 +0200
commitdf853fed66d891077ae2d04ecfa171d7e2cd5202 (patch)
treebf29d3718eeee1e17d1640841595de0ba8cda4cf /src/plugins/platforms/android
parent3711bf85ae85c9398642ae276cbd90b5bfaa6688 (diff)
Use qsizetype in QList
The change creates a slight source incompatibility. The main things to take care of are * code using printf statements on list.size(). Using qsizetype in printf statements will always require a cast to work on both 32 and 64 bit. * A few places where overloads now get ambiguous. One example is QRandomGenerator::bounded() that has overloads for int, uint and double, but not int64. * Streaming list.size() to a QDataStream will change the format depending on the architecture. [ChangeLog][QtCore][QList] QList now uses qsizetype to index into elements. Change-Id: Iaff562a4d072b97f458417b670f95971bd47cbc6 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/plugins/platforms/android')
-rw-r--r--src/plugins/platforms/android/qandroidinputcontext.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/platforms/android/qandroidinputcontext.cpp b/src/plugins/platforms/android/qandroidinputcontext.cpp
index 2fb2b24890..28d4e00762 100644
--- a/src/plugins/platforms/android/qandroidinputcontext.cpp
+++ b/src/plugins/platforms/android/qandroidinputcontext.cpp
@@ -1173,7 +1173,7 @@ void QAndroidInputContext::focusObjectStartComposing()
QInputMethodEvent event(m_composingText, {
{ QInputMethodEvent::Cursor, absoluteCursorPos - m_composingTextStart, 1 },
- { QInputMethodEvent::TextFormat, 0, m_composingText.length(), underlined }
+ { QInputMethodEvent::TextFormat, 0, int(m_composingText.length()), underlined }
});
event.setCommitString({}, m_composingTextStart - absoluteCursorPos, m_composingText.length());
@@ -1450,7 +1450,7 @@ jboolean QAndroidInputContext::setComposingText(const QString &text, jint newCur
underlined.setFontUnderline(true);
event = QInputMethodEvent(m_composingText, {
- { QInputMethodEvent::TextFormat, 0, m_composingText.length(), underlined },
+ { QInputMethodEvent::TextFormat, 0, int(m_composingText.length()), underlined },
{ QInputMethodEvent::Cursor, m_composingCursor - m_composingTextStart, 1 }
});