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

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

#include "kmymoneypricedlgdecl.h"

#include <ntqvariant.h>
#include <ntqpushbutton.h>
#include <ntqcheckbox.h>
#include <kpushbutton.h>
#include <ntqframe.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>
#include "../widgets/kmymoneypriceview.h"

/*
 *  Constructs a KMyMoneyPriceDlgDecl as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 *
 *  The qdialog will by default be modeless, unless you set 'modal' to
 *  true to construct a modal qdialog.
 */
KMyMoneyPriceDlgDecl::KMyMoneyPriceDlgDecl( TQWidget* parent, const char* name, bool modal, WFlags fl )
    : TQDialog( parent, name, modal, fl )
{
    if ( !name )
	setName( "KMyMoneyPriceDlgDecl" );
    KMyMoneyPriceDlgDeclLayout = new TQVBoxLayout( this, 11, 6, "KMyMoneyPriceDlgDeclLayout"); 

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

    layout23 = new TQVBoxLayout( 0, 0, 6, "layout23"); 

    m_priceList = new KMyMoneyPriceView( this, "m_priceList" );
    layout23->addWidget( m_priceList );

    m_showAllPrices = new TQCheckBox( this, "m_showAllPrices" );
    layout23->addWidget( m_showAllPrices );
    layout24->addLayout( layout23 );

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

    m_newButton = new KPushButton( this, "m_newButton" );
    layout9->addWidget( m_newButton );

    m_editButton = new KPushButton( this, "m_editButton" );
    layout9->addWidget( m_editButton );

    m_deleteButton = new KPushButton( this, "m_deleteButton" );
    layout9->addWidget( m_deleteButton );

    m_deleteRangeButton = new KPushButton( this, "m_deleteRangeButton" );
    layout9->addWidget( m_deleteRangeButton );
    spacer7 = new TQSpacerItem( 21, 150, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    layout9->addItem( spacer7 );

    m_onlineQuoteButton = new KPushButton( this, "m_onlineQuoteButton" );
    layout9->addWidget( m_onlineQuoteButton );
    layout24->addLayout( layout9 );
    KMyMoneyPriceDlgDeclLayout->addLayout( layout24 );

    line2 = new TQFrame( this, "line2" );
    line2->setFrameShape( TQFrame::HLine );
    line2->setFrameShadow( TQFrame::Sunken );
    line2->setFrameShape( TQFrame::HLine );
    KMyMoneyPriceDlgDeclLayout->addWidget( line2 );

    layout8 = new TQHBoxLayout( 0, 0, 6, "layout8"); 
    spacer8 = new TQSpacerItem( 560, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layout8->addItem( spacer8 );

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

    m_closeButton = new KPushButton( this, "m_closeButton" );
    m_closeButton->setAutoDefault( true );
    m_closeButton->setDefault( true );
    layout7->addWidget( m_closeButton );
    layout8->addLayout( layout7 );
    KMyMoneyPriceDlgDeclLayout->addLayout( layout8 );
    languageChange();
    resize( TQSize(806, 440).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // tab order
    setTabOrder( m_newButton, m_editButton );
    setTabOrder( m_editButton, m_deleteButton );
    setTabOrder( m_deleteButton, m_onlineQuoteButton );
    setTabOrder( m_onlineQuoteButton, m_closeButton );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void KMyMoneyPriceDlgDecl::languageChange()
{
    setCaption( tr2i18n( "Price Editor" ) );
    m_showAllPrices->setText( tr2i18n( "Show all stored prices" ) );
    m_newButton->setText( tr2i18n( "New" ) );
    m_editButton->setText( tr2i18n( "Modify" ) );
    m_deleteButton->setText( tr2i18n( "Delete" ) );
    m_deleteRangeButton->setText( tr2i18n( "Delete Range..." ) );
    m_onlineQuoteButton->setText( tr2i18n( "Online Quotes" ) );
    m_closeButton->setText( tr2i18n( "Close" ) );
}

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

TQMetaObject *KMyMoneyPriceDlgDecl::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_KMyMoneyPriceDlgDecl( "KMyMoneyPriceDlgDecl", &KMyMoneyPriceDlgDecl::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

TQMetaObject* KMyMoneyPriceDlgDecl::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 = TQDialog::staticMetaObject();
    static const TQUMethod slot_0 = {"languageChange", 0, 0 };
    static const TQMetaData slot_tbl[] = {
	{ "languageChange()", &slot_0, TQMetaData::Protected }
    };
    metaObj = TQMetaObject::new_metaobject(
	"KMyMoneyPriceDlgDecl", parentObject,
	slot_tbl, 1,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_KMyMoneyPriceDlgDecl.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

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

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

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

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

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