diff options
Diffstat (limited to 'kdejava/koala/kdejava/KTipDatabase.cpp')
-rw-r--r-- | kdejava/koala/kdejava/KTipDatabase.cpp | 95 |
1 files changed, 95 insertions, 0 deletions
diff --git a/kdejava/koala/kdejava/KTipDatabase.cpp b/kdejava/koala/kdejava/KTipDatabase.cpp new file mode 100644 index 00000000..9840bf45 --- /dev/null +++ b/kdejava/koala/kdejava/KTipDatabase.cpp @@ -0,0 +1,95 @@ +//Auto-generated by kalyptus. DO NOT EDIT. +#include <ktip.h> +#include <qstring.h> +#include <qstringlist.h> + +#include <qtjava/QtSupport.h> +#include <kdejava/KDESupport.h> +#include <kdejava/KTipDatabase.h> + +class KTipDatabaseJBridge : public KTipDatabase +{ +public: + KTipDatabaseJBridge(const QString& arg1) : KTipDatabase(arg1) {}; + KTipDatabaseJBridge() : KTipDatabase() {}; + KTipDatabaseJBridge(const QStringList& arg1) : KTipDatabase(arg1) {}; + ~KTipDatabaseJBridge() {QtSupport::qtKeyDeleted(this);} +}; + +JNIEXPORT void JNICALL +Java_org_kde_koala_KTipDatabase_dispose(JNIEnv* env, jobject obj) +{ + Java_org_kde_koala_KTipDatabase_finalize(env, obj); + return; +} + +JNIEXPORT void JNICALL +Java_org_kde_koala_KTipDatabase_finalize(JNIEnv* env, jobject obj) +{ + if (QtSupport::allocatedInJavaWorld(env, obj)) { + delete (KTipDatabase*)QtSupport::getQt(env, obj); + QtSupport::setQt(env, obj, 0); + } + return; +} + +JNIEXPORT jboolean JNICALL +Java_org_kde_koala_KTipDatabase_isDisposed(JNIEnv* env, jobject obj) +{ + return (QtSupport::getQt(env, obj) == 0); +} + +JNIEXPORT void JNICALL +Java_org_kde_koala_KTipDatabase_newKTipDatabase__(JNIEnv* env, jobject obj) +{ + if (QtSupport::getQt(env, obj) == 0) { + QtSupport::setQt(env, obj, new KTipDatabaseJBridge()); + QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj)); + } + return; +} + +JNIEXPORT void JNICALL +Java_org_kde_koala_KTipDatabase_newKTipDatabase__Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring tipFile) +{ +static QString* _qstring_tipFile = 0; + if (QtSupport::getQt(env, obj) == 0) { + QtSupport::setQt(env, obj, new KTipDatabaseJBridge((const QString&)*(QString*) QtSupport::toQString(env, tipFile, &_qstring_tipFile))); + QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj)); + } + return; +} + +JNIEXPORT void JNICALL +Java_org_kde_koala_KTipDatabase_newKTipDatabase___3Ljava_lang_String_2(JNIEnv* env, jobject obj, jobjectArray tipFiles) +{ +static QStringList* _qlist_tipFiles = 0; + if (QtSupport::getQt(env, obj) == 0) { + QtSupport::setQt(env, obj, new KTipDatabaseJBridge((const QStringList&)*(QStringList*) QtSupport::toQStringList(env, tipFiles, &_qlist_tipFiles))); + QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj)); + } + return; +} + +JNIEXPORT void JNICALL +Java_org_kde_koala_KTipDatabase_nextTip(JNIEnv* env, jobject obj) +{ + ((KTipDatabase*) QtSupport::getQt(env, obj))->nextTip(); + return; +} + +JNIEXPORT void JNICALL +Java_org_kde_koala_KTipDatabase_prevTip(JNIEnv* env, jobject obj) +{ + ((KTipDatabase*) QtSupport::getQt(env, obj))->prevTip(); + return; +} + +JNIEXPORT jstring JNICALL +Java_org_kde_koala_KTipDatabase_tip(JNIEnv* env, jobject obj) +{ + QString _qstring; + _qstring = ((KTipDatabase*) QtSupport::getQt(env, obj))->tip(); + return QtSupport::fromQString(env, &_qstring); +} + |