//Auto-generated by kalyptus. DO NOT EDIT.
#include <kurlpixmapprovider.h>
#include <qpixmap.h>
#include <qstring.h>

#include <qtjava/QtSupport.h>
#include <kdejava/KDESupport.h>
#include <kdejava/KURLPixmapProvider.h>

class KURLPixmapProviderJBridge : public KURLPixmapProvider
{
public:
	KURLPixmapProviderJBridge() : KURLPixmapProvider() {};
	~KURLPixmapProviderJBridge() {QtSupport::qtKeyDeleted(this);}
};

JNIEXPORT void JNICALL
Java_org_kde_koala_KURLPixmapProvider_dispose(JNIEnv* env, jobject obj)
{
	Java_org_kde_koala_KURLPixmapProvider_finalize(env, obj);
	return;
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURLPixmapProvider_finalize(JNIEnv* env, jobject obj)
{
	if (QtSupport::allocatedInJavaWorld(env, obj)) {
		delete (KURLPixmapProvider*)QtSupport::getQt(env, obj);
		QtSupport::setQt(env, obj, 0);
	}
	return;
}

JNIEXPORT jboolean JNICALL
Java_org_kde_koala_KURLPixmapProvider_isDisposed(JNIEnv* env, jobject obj)
{
	return (QtSupport::getQt(env, obj) == 0);
}

JNIEXPORT void JNICALL
Java_org_kde_koala_KURLPixmapProvider_newKURLPixmapProvider(JNIEnv* env, jobject obj)
{
	if (QtSupport::getQt(env, obj) == 0) {
		QtSupport::setQt(env, obj, new KURLPixmapProviderJBridge());
		QtSupport::setObjectForQtKey(env, obj, QtSupport::getQt(env, obj));
	}
	return;
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KURLPixmapProvider_pixmapFor__Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring url)
{
static QString* _qstring_url = 0;
	jobject xret = QtSupport::objectForQtKey(env, (void*)new QPixmap(((KURLPixmapProvider*) QtSupport::getQt(env, obj))->pixmapFor((const QString&)*(QString*) QtSupport::toQString(env, url, &_qstring_url))), "org.kde.qt.QPixmap", TRUE);
	return xret;
}

JNIEXPORT jobject JNICALL
Java_org_kde_koala_KURLPixmapProvider_pixmapFor__Ljava_lang_String_2I(JNIEnv* env, jobject obj, jstring url, jint size)
{
static QString* _qstring_url = 0;
	jobject xret = QtSupport::objectForQtKey(env, (void*)new QPixmap(((KURLPixmapProvider*) QtSupport::getQt(env, obj))->pixmapFor((const QString&)*(QString*) QtSupport::toQString(env, url, &_qstring_url), (int) size)), "org.kde.qt.QPixmap", TRUE);
	return xret;
}

