//Auto-generated by kalyptus. DO NOT EDIT.
#include <tqrect.h>
#include <tqpixmap.h>
#include <tqimage.h>
#include <kpixmapio.h>
#include <tqpoint.h>

#include <qtjava/QtSupport.h>
#include <tdejava/TDESupport.h>
#include <tdejava/KPixmapIO.h>

class KPixmapIOJBridge : public KPixmapIO
{
public:
	KPixmapIOJBridge() : KPixmapIO() {};
	~KPixmapIOJBridge() {QtSupport::qtKeyDeleted(this);}
};

JNIEXPORT jobject JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_convertToImage(JNIEnv* env, jobject obj, jobject pixmap)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)new TQImage(((KPixmapIO*) QtSupport::getQt(env, obj))->convertToImage((const TQPixmap&)*(const TQPixmap*) QtSupport::getQt(env, pixmap))), "org.trinitydesktop.qt.TQImage", TRUE);
	return xret;
}

JNIEXPORT jobject JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_convertToPixmap(JNIEnv* env, jobject obj, jobject image)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)new TQPixmap(((KPixmapIO*) QtSupport::getQt(env, obj))->convertToPixmap((const TQImage&)*(const TQImage*) QtSupport::getQt(env, image))), "org.trinitydesktop.qt.TQPixmap", TRUE);
	return xret;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_dispose(JNIEnv* env, jobject obj)
{
	Java_org_trinitydesktop_koala_KPixmapIO_finalize(env, obj);
	return;
}

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

JNIEXPORT jobject JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_getImage__Lorg_trinitydesktop_qt_QPixmap_2IIII(JNIEnv* env, jobject obj, jobject src, jint sx, jint sy, jint sw, jint sh)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)new TQImage(((KPixmapIO*) QtSupport::getQt(env, obj))->getImage((const TQPixmap*) QtSupport::getQt(env, src), (int) sx, (int) sy, (int) sw, (int) sh)), "org.trinitydesktop.qt.TQImage", TRUE);
	return xret;
}

JNIEXPORT jobject JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_getImage__Lorg_trinitydesktop_qt_QPixmap_2Lorg_trinitydesktop_qt_QRect_2(JNIEnv* env, jobject obj, jobject src, jobject rect)
{
	jobject xret = QtSupport::objectForQtKey(env, (void*)new TQImage(((KPixmapIO*) QtSupport::getQt(env, obj))->getImage((const TQPixmap*) QtSupport::getQt(env, src), (const TQRect&)*(const TQRect*) QtSupport::getQt(env, rect))), "org.trinitydesktop.qt.TQImage", TRUE);
	return xret;
}

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

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

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_preAllocShm(JNIEnv* env, jobject obj, jint size)
{
	((KPixmapIO*) QtSupport::getQt(env, obj))->preAllocShm((int) size);
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_putImage__Lorg_trinitydesktop_qt_QPixmap_2IILorg_trinitydesktop_qt_QImage_2(JNIEnv* env, jobject obj, jobject dst, jint dx, jint dy, jobject src)
{
	((KPixmapIO*) QtSupport::getQt(env, obj))->putImage((TQPixmap*) QtSupport::getQt(env, dst), (int) dx, (int) dy, (const TQImage*) QtSupport::getQt(env, src));
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_putImage__Lorg_trinitydesktop_qt_QPixmap_2Lorg_trinitydesktop_qt_QPoint_2Lorg_trinitydesktop_qt_QImage_2(JNIEnv* env, jobject obj, jobject dst, jobject offset, jobject src)
{
	((KPixmapIO*) QtSupport::getQt(env, obj))->putImage((TQPixmap*) QtSupport::getQt(env, dst), (const TQPoint&)*(const TQPoint*) QtSupport::getQt(env, offset), (const TQImage*) QtSupport::getQt(env, src));
	return;
}

JNIEXPORT void JNICALL
Java_org_trinitydesktop_koala_KPixmapIO_setShmPolicy(JNIEnv* env, jobject obj, jint policy)
{
	((KPixmapIO*) QtSupport::getQt(env, obj))->setShmPolicy((int) policy);
	return;
}

