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

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

#include "aiminfobase.h"

#include <ntqvariant.h>
#include <ktextbrowser.h>
#include <ntqpushbutton.h>
#include <ntqlabel.h>
#include <ntqlineedit.h>
#include <ntqframe.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

/*
 *  Constructs a AIMUserInfoWidget as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 */
AIMUserInfoWidget::AIMUserInfoWidget( TQWidget* parent, const char* name, WFlags fl )
    : TQWidget( parent, name, fl )
{
    if ( !name )
	setName( "AIMUserInfoWidget" );
    setMinimumSize( TQSize( 360, 400 ) );
    AIMUserInfoWidgetLayout = new TQVBoxLayout( this, 0, 6, "AIMUserInfoWidgetLayout"); 

    layout9 = new TQHBoxLayout( 0, 0, 6, "layout9"); 

    lblNickName = new TQLabel( this, "lblNickName" );
    lblNickName->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)4, (TQSizePolicy::SizeType)4, 0, 0, lblNickName->sizePolicy().hasHeightForWidth() ) );
    layout9->addWidget( lblNickName );

    txtNickName = new TQLineEdit( this, "txtNickName" );
    txtNickName->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)0, 0, 0, txtNickName->sizePolicy().hasHeightForWidth() ) );
    layout9->addWidget( txtNickName );

    lblScreenName = new TQLabel( this, "lblScreenName" );
    lblScreenName->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)4, (TQSizePolicy::SizeType)4, 0, 0, lblScreenName->sizePolicy().hasHeightForWidth() ) );
    layout9->addWidget( lblScreenName );

    txtScreenName = new TQLineEdit( this, "txtScreenName" );
    txtScreenName->setReadOnly( true );
    layout9->addWidget( txtScreenName );
    AIMUserInfoWidgetLayout->addLayout( layout9 );

    layout10 = new TQHBoxLayout( 0, 0, 6, "layout10"); 

    lblWarnLevel = new TQLabel( this, "lblWarnLevel" );
    layout10->addWidget( lblWarnLevel );

    txtWarnLevel = new TQLineEdit( this, "txtWarnLevel" );
    txtWarnLevel->setReadOnly( true );
    layout10->addWidget( txtWarnLevel );

    lblIdleTime = new TQLabel( this, "lblIdleTime" );
    layout10->addWidget( lblIdleTime );

    txtIdleTime = new TQLineEdit( this, "txtIdleTime" );
    txtIdleTime->setReadOnly( true );
    layout10->addWidget( txtIdleTime );
    AIMUserInfoWidgetLayout->addLayout( layout10 );

    layout11 = new TQHBoxLayout( 0, 0, 6, "layout11"); 

    lblOnlineSince = new TQLabel( this, "lblOnlineSince" );
    layout11->addWidget( lblOnlineSince );

    txtOnlineSince = new TQLineEdit( this, "txtOnlineSince" );
    txtOnlineSince->setReadOnly( true );
    layout11->addWidget( txtOnlineSince );
    AIMUserInfoWidgetLayout->addLayout( layout11 );

    lblAwayMessage = new TQLabel( this, "lblAwayMessage" );
    lblAwayMessage->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)1, 0, 0, lblAwayMessage->sizePolicy().hasHeightForWidth() ) );
    lblAwayMessage->setAlignment( int( TQLabel::AlignTop ) );
    AIMUserInfoWidgetLayout->addWidget( lblAwayMessage );

    txtAwayMessage = new KTextBrowser( this, "txtAwayMessage" );
    txtAwayMessage->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)5, 0, 0, txtAwayMessage->sizePolicy().hasHeightForWidth() ) );
    txtAwayMessage->setTextFormat( KTextBrowser::AutoText );
    AIMUserInfoWidgetLayout->addWidget( txtAwayMessage );

    textLabel1 = new TQLabel( this, "textLabel1" );
    AIMUserInfoWidgetLayout->addWidget( textLabel1 );

    userInfoFrame = new TQFrame( this, "userInfoFrame" );
    userInfoFrame->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)7, 0, 0, userInfoFrame->sizePolicy().hasHeightForWidth() ) );
    userInfoFrame->setMinimumSize( TQSize( 64, 16 ) );
    userInfoFrame->setFrameShape( TQFrame::NoFrame );
    userInfoFrame->setFrameShadow( TQFrame::Plain );
    userInfoFrame->setLineWidth( 0 );
    AIMUserInfoWidgetLayout->addWidget( userInfoFrame );
    languageChange();
    resize( TQSize(360, 408).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // tab order
    setTabOrder( txtNickName, txtScreenName );
    setTabOrder( txtScreenName, txtWarnLevel );
    setTabOrder( txtWarnLevel, txtIdleTime );
    setTabOrder( txtIdleTime, txtOnlineSince );
    setTabOrder( txtOnlineSince, txtAwayMessage );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void AIMUserInfoWidget::languageChange()
{
    lblNickName->setText( tr2i18n( "Nickname:" ) );
    lblScreenName->setText( tr2i18n( "Screen name:" ) );
    lblWarnLevel->setText( tr2i18n( "Warning level:" ) );
    lblIdleTime->setText( tr2i18n( "Idle minutes:" ) );
    lblOnlineSince->setText( tr2i18n( "Online since:" ) );
    lblAwayMessage->setText( tr2i18n( "Away message:" ) );
    textLabel1->setText( tr2i18n( "Profile:" ) );
}

/****************************************************************************
** AIMUserInfoWidget meta object code from reading C++ file 'aiminfobase.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 "aiminfobase.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 *AIMUserInfoWidget::className() const
{
    return "AIMUserInfoWidget";
}

TQMetaObject *AIMUserInfoWidget::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_AIMUserInfoWidget( "AIMUserInfoWidget", &AIMUserInfoWidget::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

TQMetaObject* AIMUserInfoWidget::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(
	"AIMUserInfoWidget", parentObject,
	slot_tbl, 1,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_AIMUserInfoWidget.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

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

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

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

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

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