Android: use binary name when using loadClass.

QtAndroid::findClass uses loadClass methods to find Qt's java classes.
The documentation says that we should use a binary name.

Change-Id: I2146789235435b7052827cde58b7719b7d62dc1d
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
This commit is contained in:
BogDan Vatra 2013-12-03 15:02:24 +02:00 committed by The Qt Project
parent 82d474d50d
commit 2b70b318e3
2 changed files with 3 additions and 3 deletions

View File

@ -59,8 +59,8 @@
QT_BEGIN_NAMESPACE
static QAndroidInputContext *m_androidInputContext = 0;
static char const *const QtNativeInputConnectionClassName = "org/qtproject/qt5/android/QtNativeInputConnection";
static char const *const QtExtractedTextClassName = "org/qtproject/qt5/android/QtExtractedText";
static char const *const QtNativeInputConnectionClassName = "org.qtproject.qt5.android.QtNativeInputConnection";
static char const *const QtExtractedTextClassName = "org.qtproject.qt5.android.QtExtractedText";
static jclass m_extractedTextClass = 0;
static jmethodID m_classConstructorMethodID = 0;
static jfieldID m_partialEndOffsetFieldID = 0;

View File

@ -184,7 +184,7 @@ static JNINativeMethod methods[] = {
bool registerNatives(JNIEnv *env)
{
jclass clazz = QtAndroid::findClass("org/qtproject/qt5/android/QtMessageDialogHelper", env);
jclass clazz = QtAndroid::findClass("org.qtproject.qt5.android.QtMessageDialogHelper", env);
if (!clazz) {
__android_log_print(ANDROID_LOG_FATAL, QtAndroid::qtTagText(), QtAndroid::classErrorMsgFmt()
, "org/qtproject/qt5/android/QtMessageDialogHelper");