#include <kdialog.h>
#include <tdelocale.h>

/****************************************************************************
** Form implementation generated from reading ui file 'gaduregisteraccountui.ui'
**
** Created by: The TQt user interface compiler (TQt 3.5.0)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

#include "gaduregisteraccountui.h"

#include <ntqvariant.h>
#include <klineedit.h>
#include <ntqlabel.h>
#include <ntqlineedit.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

/*
 *  Constructs a GaduRegisterAccountUI as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 */
GaduRegisterAccountUI::GaduRegisterAccountUI( TQWidget* parent, const char* name, WFlags fl )
    : TQWidget( parent, name, fl )
{
    if ( !name )
	setName( "GaduRegisterAccountUI" );
    GaduRegisterAccountUILayout = new TQVBoxLayout( this, 11, 6, "GaduRegisterAccountUILayout"); 

    layout33 = new TQGridLayout( 0, 1, 1, 0, 6, "layout33"); 

    pixmapEmailAddress = new TQLabel( this, "pixmapEmailAddress" );
    pixmapEmailAddress->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 0, 0, pixmapEmailAddress->sizePolicy().hasHeightForWidth() ) );
    pixmapEmailAddress->setMinimumSize( TQSize( 16, 16 ) );
    pixmapEmailAddress->setMaximumSize( TQSize( 32767, 32767 ) );
    pixmapEmailAddress->setScaledContents( true );

    layout33->addWidget( pixmapEmailAddress, 0, 0 );

    labelPasswordVerify = new TQLabel( this, "labelPasswordVerify" );
    labelPasswordVerify->setEnabled( true );

    layout33->addWidget( labelPasswordVerify, 2, 1 );

    valuePassword = new KLineEdit( this, "valuePassword" );
    valuePassword->setEchoMode( KLineEdit::Password );

    layout33->addWidget( valuePassword, 1, 2 );

    valueEmailAddress = new KLineEdit( this, "valueEmailAddress" );

    layout33->addWidget( valueEmailAddress, 0, 2 );

    pixmapVerificationSequence = new TQLabel( this, "pixmapVerificationSequence" );
    pixmapVerificationSequence->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 0, 0, pixmapVerificationSequence->sizePolicy().hasHeightForWidth() ) );
    pixmapVerificationSequence->setMinimumSize( TQSize( 16, 16 ) );
    pixmapVerificationSequence->setMaximumSize( TQSize( 32767, 32767 ) );
    pixmapVerificationSequence->setScaledContents( true );

    layout33->addWidget( pixmapVerificationSequence, 3, 0 );

    labelEmailAddress = new TQLabel( this, "labelEmailAddress" );

    layout33->addWidget( labelEmailAddress, 0, 1 );

    pixmapPasswordVerify = new TQLabel( this, "pixmapPasswordVerify" );
    pixmapPasswordVerify->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 0, 0, pixmapPasswordVerify->sizePolicy().hasHeightForWidth() ) );
    pixmapPasswordVerify->setMinimumSize( TQSize( 16, 16 ) );
    pixmapPasswordVerify->setMaximumSize( TQSize( 32767, 32767 ) );
    pixmapPasswordVerify->setScaledContents( true );

    layout33->addWidget( pixmapPasswordVerify, 2, 0 );

    labelVerificationSequence = new TQLabel( this, "labelVerificationSequence" );
    labelVerificationSequence->setEnabled( true );

    layout33->addWidget( labelVerificationSequence, 3, 1 );

    valueVerificationSequence = new TQLineEdit( this, "valueVerificationSequence" );

    layout33->addWidget( valueVerificationSequence, 3, 2 );

    pixmapPassword = new TQLabel( this, "pixmapPassword" );
    pixmapPassword->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 0, 0, pixmapPassword->sizePolicy().hasHeightForWidth() ) );
    pixmapPassword->setMinimumSize( TQSize( 16, 16 ) );
    pixmapPassword->setMaximumSize( TQSize( 32767, 32767 ) );
    pixmapPassword->setScaledContents( true );

    layout33->addWidget( pixmapPassword, 1, 0 );

    labelPassword = new TQLabel( this, "labelPassword" );

    layout33->addWidget( labelPassword, 1, 1 );

    valuePasswordVerify = new KLineEdit( this, "valuePasswordVerify" );
    valuePasswordVerify->setEchoMode( KLineEdit::Password );

    layout33->addWidget( valuePasswordVerify, 2, 2 );
    GaduRegisterAccountUILayout->addLayout( layout33 );

    layoutImageCenter = new TQHBoxLayout( 0, 0, 6, "layoutImageCenter"); 
    spacerImageLeft = new TQSpacerItem( 23, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layoutImageCenter->addItem( spacerImageLeft );

    pixmapToken = new TQLabel( this, "pixmapToken" );
    pixmapToken->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 20, 13, pixmapToken->sizePolicy().hasHeightForWidth() ) );
    pixmapToken->setMinimumSize( TQSize( 256, 64 ) );
    pixmapToken->setMaximumSize( TQSize( 256, 64 ) );
    pixmapToken->setBackgroundMode( TQLabel::PaletteForeground );
    pixmapToken->setPaletteForegroundColor( TQColor( 255, 255, 255 ) );
    pixmapToken->setFrameShape( TQLabel::Box );
    pixmapToken->setFrameShadow( TQLabel::Sunken );
    pixmapToken->setScaledContents( true );
    layoutImageCenter->addWidget( pixmapToken );
    spacerImageRight = new TQSpacerItem( 22, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layoutImageCenter->addItem( spacerImageRight );
    GaduRegisterAccountUILayout->addLayout( layoutImageCenter );

    labelInstructions = new TQLabel( this, "labelInstructions" );
    labelInstructions->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)3, (TQSizePolicy::SizeType)3, 0, 0, labelInstructions->sizePolicy().hasHeightForWidth() ) );
    labelInstructions->setAlignment( int( TQLabel::WordBreak | TQLabel::AlignTop ) );
    GaduRegisterAccountUILayout->addWidget( labelInstructions );
    spacerMiddle = new TQSpacerItem( 20, 16, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    GaduRegisterAccountUILayout->addItem( spacerMiddle );

    labelStatusMessage = new TQLabel( this, "labelStatusMessage" );
    labelStatusMessage->setAlignment( int( TQLabel::AlignCenter ) );
    GaduRegisterAccountUILayout->addWidget( labelStatusMessage );
    languageChange();
    resize( TQSize(376, 394).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // tab order
    setTabOrder( valueEmailAddress, valuePassword );
    setTabOrder( valuePassword, valuePasswordVerify );
    setTabOrder( valuePasswordVerify, valueVerificationSequence );

    // buddies
    labelPasswordVerify->setBuddy( valuePasswordVerify );
    labelEmailAddress->setBuddy( valueEmailAddress );
    labelVerificationSequence->setBuddy( valueVerificationSequence );
    labelPassword->setBuddy( valuePassword );
}

/*
 *  Destroys the object and frees any allocated resources
 */
GaduRegisterAccountUI::~GaduRegisterAccountUI()
{
    // no need to delete child widgets, TQt does it all for us
}

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void GaduRegisterAccountUI::languageChange()
{
    setCaption( tr2i18n( "Register Account - Gadu-Gadu" ) );
    labelPasswordVerify->setText( tr2i18n( "Repeat pass&word:" ) );
    TQToolTip::add( labelPasswordVerify, tr2i18n( "A confirmation of the password you would like to use." ) );
    TQWhatsThis::add( labelPasswordVerify, tr2i18n( "A confirmation of the password you would like to use for this account." ) );
    TQToolTip::add( valuePassword, tr2i18n( "The password you would like to use." ) );
    TQWhatsThis::add( valuePassword, tr2i18n( "The password you would like to use for this account." ) );
    TQToolTip::add( valueEmailAddress, tr2i18n( "Your E-mail address." ) );
    TQWhatsThis::add( valueEmailAddress, tr2i18n( "The E-mail address you would like to use to register this account." ) );
    labelEmailAddress->setText( tr2i18n( "&E-Mail address:" ) );
    TQToolTip::add( labelEmailAddress, tr2i18n( "Your E-mail address." ) );
    TQWhatsThis::add( labelEmailAddress, tr2i18n( "The E-mail address you would like to use to register this account." ) );
    labelVerificationSequence->setText( tr2i18n( "&Verification sequence:" ) );
    TQToolTip::add( labelVerificationSequence, tr2i18n( "The text from the image below." ) );
    TQWhatsThis::add( labelVerificationSequence, tr2i18n( "The text from the image below.  This is used to prevent abusive automated registration scripts." ) );
    TQToolTip::add( valueVerificationSequence, tr2i18n( "The text from the image below." ) );
    TQWhatsThis::add( valueVerificationSequence, tr2i18n( "The text from the image below.  This is used to prevent abusive automated registration scripts." ) );
    labelPassword->setText( tr2i18n( "&Password:" ) );
    TQToolTip::add( labelPassword, tr2i18n( "The password you would like to use." ) );
    TQWhatsThis::add( labelPassword, tr2i18n( "The password you would like to use for this account." ) );
    TQToolTip::add( valuePasswordVerify, tr2i18n( "A confirmation of the password you would like to use." ) );
    TQWhatsThis::add( valuePasswordVerify, tr2i18n( "A confirmation of the password you would like to use for this account." ) );
    TQToolTip::add( pixmapToken, tr2i18n( "Gadu-Gadu registration token." ) );
    TQWhatsThis::add( pixmapToken, tr2i18n( "This field contains an image with number that you need to type into the <b>Verification Sequence</b> field above." ) );
    labelInstructions->setText( tr2i18n( "<i>Type the letters and numbers shown in the image above into the <b>Verification Sequence</b> field.  This is used to prevent automated registration abuse.</i>" ) );
    labelStatusMessage->setText( TQString::null );
}

/****************************************************************************
** GaduRegisterAccountUI meta object code from reading C++ file 'gaduregisteraccountui.h'
**
** Created by: The TQt Meta Object Compiler version 26 (TQt 3.5.0)
** WARNING! All changes made in this file will be lost!
*****************************************************************************/

#undef TQT_NO_COMPAT
#include "gaduregisteraccountui.h"
#include <ntqmetaobject.h>
#include <ntqapplication.h>

#include <private/qucomextra_p.h>
#if !defined(Q_MOC_OUTPUT_REVISION) || (Q_MOC_OUTPUT_REVISION != 26)
#error "This file was generated using the moc from 3.5.0. It"
#error "cannot be used with the include files from this version of TQt."
#error "(The moc has changed too much.)"
#endif

const char *GaduRegisterAccountUI::className() const
{
    return "GaduRegisterAccountUI";
}

TQMetaObject *GaduRegisterAccountUI::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_GaduRegisterAccountUI( "GaduRegisterAccountUI", &GaduRegisterAccountUI::staticMetaObject );

#ifndef TQT_NO_TRANSLATION
TQString GaduRegisterAccountUI::tr( const char *s, const char *c )
{
    if ( tqApp )
	return tqApp->translate( "GaduRegisterAccountUI", s, c, TQApplication::DefaultCodec );
    else
	return TQString::fromLatin1( s );
}
#ifndef TQT_NO_TRANSLATION_UTF8
TQString GaduRegisterAccountUI::trUtf8( const char *s, const char *c )
{
    if ( tqApp )
	return tqApp->translate( "GaduRegisterAccountUI", s, c, TQApplication::UnicodeUTF8 );
    else
	return TQString::fromUtf8( s );
}
#endif // TQT_NO_TRANSLATION_UTF8

#endif // TQT_NO_TRANSLATION

TQMetaObject* GaduRegisterAccountUI::staticMetaObject()
{
    if ( metaObj ) {
	return metaObj;
}
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->lock();
    if ( metaObj ) {
	if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
	return metaObj;
    }
#endif // TQT_THREAD_SUPPORT
    TQMetaObject* parentObject = TQWidget::staticMetaObject();
    static const TQUMethod slot_0 = {"languageChange", 0, 0 };
    static const TQMetaData slot_tbl[] = {
	{ "languageChange()", &slot_0, TQMetaData::Protected }
    };
    metaObj = TQMetaObject::new_metaobject(
	"GaduRegisterAccountUI", parentObject,
	slot_tbl, 1,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_GaduRegisterAccountUI.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

void* GaduRegisterAccountUI::tqt_cast( const char* clname )
{
    if ( !qstrcmp( clname, "GaduRegisterAccountUI" ) )
	return this;
    return TQWidget::tqt_cast( clname );
}

bool GaduRegisterAccountUI::tqt_invoke( int _id, TQUObject* _o )
{
    switch ( _id - staticMetaObject()->slotOffset() ) {
    case 0: languageChange(); break;
    default:
	return TQWidget::tqt_invoke( _id, _o );
    }
    return true;
}

bool GaduRegisterAccountUI::tqt_emit( int _id, TQUObject* _o )
{
    return TQWidget::tqt_emit(_id,_o);
}
#ifndef TQT_NO_PROPERTIES

bool GaduRegisterAccountUI::tqt_property( int id, int f, TQVariant* v)
{
    return TQWidget::tqt_property( id, f, v);
}

bool GaduRegisterAccountUI::tqt_static_property( TQObject* , int , int , TQVariant* ){ return false; }
#endif // TQT_NO_PROPERTIES
