File indexing completed on 2024-11-17 04:43:12

0001 /*
0002     SPDX-FileCopyrightText: 2020 Volker Krause <vkrause@kde.org>
0003 
0004     SPDX-License-Identifier: LGPL-2.0-or-later
0005 */
0006 
0007 #include "context.h"
0008 
0009 #include <KAndroidExtras/JavaTypes>
0010 #include <KAndroidExtras/JniSignature>
0011 
0012 #include <QCoreApplication>
0013 
0014 using namespace KAndroidExtras;
0015 
0016 QJniObject Context::getPackageName()
0017 {
0018     const QJniObject context = QNativeInterface::QAndroidApplication::context();
0019     return context.callObjectMethod("getPackageName", Jni::signature<java::lang::String()>());
0020 }