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

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

#include "modcalcequinoxdlg.h"

#include <ntqvariant.h>
#include <kpushbutton.h>
#include <klineedit.h>
#include <ntqpushbutton.h>
#include <ntqtabwidget.h>
#include <ntqgroupbox.h>
#include <ntqcombobox.h>
#include <ntqlabel.h>
#include <ntqbuttongroup.h>
#include <ntqcheckbox.h>
#include <ntqradiobutton.h>
#include <ntqlineedit.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>
#include "libtdeedu/extdate/extdatetimeedit.h"

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

    tabWidget3 = new TQTabWidget( this, "tabWidget3" );

    tab = new TQWidget( tabWidget3, "tab" );
    tabLayout = new TQVBoxLayout( tab, 11, 6, "tabLayout"); 

    groupBox6 = new TQGroupBox( tab, "groupBox6" );
    groupBox6->setFrameShape( TQGroupBox::GroupBoxPanel );
    groupBox6->setFrameShadow( TQGroupBox::Sunken );
    groupBox6->setColumnLayout(0, TQt::Vertical );
    groupBox6->layout()->setSpacing( 6 );
    groupBox6->layout()->setMargin( 11 );
    groupBox6Layout = new TQHBoxLayout( groupBox6->layout() );
    groupBox6Layout->setAlignment( TQt::AlignTop );
    spacer20_2 = new TQSpacerItem( 70, 21, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    groupBox6Layout->addItem( spacer20_2 );

    equinoxSolsticesComboBox = new TQComboBox( false, groupBox6, "equinoxSolsticesComboBox" );
    groupBox6Layout->addWidget( equinoxSolsticesComboBox );
    spacer20 = new TQSpacerItem( 20, 21, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    groupBox6Layout->addItem( spacer20 );

    textLabel1 = new TQLabel( groupBox6, "textLabel1" );
    groupBox6Layout->addWidget( textLabel1 );

    yearEdit = new KLineEdit( groupBox6, "yearEdit" );
    groupBox6Layout->addWidget( yearEdit );
    spacer19 = new TQSpacerItem( 30, 31, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    groupBox6Layout->addItem( spacer19 );
    tabLayout->addWidget( groupBox6 );

    layout2 = new TQHBoxLayout( 0, 0, 6, "layout2"); 
    spacer6 = new TQSpacerItem( 81, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layout2->addItem( spacer6 );

    Compute = new KPushButton( tab, "Compute" );
    layout2->addWidget( Compute );
    spacer4 = new TQSpacerItem( 51, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layout2->addItem( spacer4 );

    Clear = new KPushButton( tab, "Clear" );
    layout2->addWidget( Clear );
    spacer5 = new TQSpacerItem( 91, 21, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layout2->addItem( spacer5 );
    tabLayout->addLayout( layout2 );

    groupBox7 = new TQGroupBox( tab, "groupBox7" );
    groupBox7->setColumnLayout(0, TQt::Vertical );
    groupBox7->layout()->setSpacing( 6 );
    groupBox7->layout()->setMargin( 11 );
    groupBox7Layout = new TQGridLayout( groupBox7->layout() );
    groupBox7Layout->setAlignment( TQt::AlignTop );

    seasonDuration = new KLineEdit( groupBox7, "seasonDuration" );
    seasonDuration->setFocusPolicy( KLineEdit::NoFocus );

    groupBox7Layout->addWidget( seasonDuration, 1, 2 );

    textLabel3 = new TQLabel( groupBox7, "textLabel3" );

    groupBox7Layout->addMultiCellWidget( textLabel3, 1, 1, 0, 1 );

    textLabel2 = new TQLabel( groupBox7, "textLabel2" );

    groupBox7Layout->addWidget( textLabel2, 0, 0 );

    startDateTimeEquinox = new ExtDateTimeEdit( groupBox7, "startDateTimeEquinox" );

    groupBox7Layout->addMultiCellWidget( startDateTimeEquinox, 0, 0, 1, 2 );
    tabLayout->addWidget( groupBox7 );
    spacer22 = new TQSpacerItem( 41, 237, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    tabLayout->addItem( spacer22 );
    tabWidget3->insertTab( tab, TQString::fromLatin1("") );

    tab_2 = new TQWidget( tabWidget3, "tab_2" );
    tabLayout_2 = new TQVBoxLayout( tab_2, 11, 6, "tabLayout_2"); 

    InputBox_2_2 = new TQButtonGroup( tab_2, "InputBox_2_2" );
    InputBox_2_2->setEnabled( true );
    InputBox_2_2->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)5, 0, 0, InputBox_2_2->sizePolicy().hasHeightForWidth() ) );
    InputBox_2_2->setColumnLayout(0, TQt::Vertical );
    InputBox_2_2->layout()->setSpacing( 6 );
    InputBox_2_2->layout()->setMargin( 11 );
    InputBox_2_2Layout = new TQHBoxLayout( InputBox_2_2->layout() );
    InputBox_2_2Layout->setAlignment( TQt::AlignTop );

    yearCheckBatch = new TQCheckBox( InputBox_2_2, "yearCheckBatch" );
    yearCheckBatch->setChecked( true );
    InputBox_2_2Layout->addWidget( yearCheckBatch );
    spacer23 = new TQSpacerItem( 111, 21, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    InputBox_2_2Layout->addItem( spacer23 );

    yearEditBatch = new KLineEdit( InputBox_2_2, "yearEditBatch" );
    yearEditBatch->setEnabled( false );
    InputBox_2_2Layout->addWidget( yearEditBatch );
    tabLayout_2->addWidget( InputBox_2_2 );

    buttonFieldsGroup = new TQButtonGroup( tab_2, "buttonFieldsGroup" );
    buttonFieldsGroup->setColumnLayout(0, TQt::Vertical );
    buttonFieldsGroup->layout()->setSpacing( 6 );
    buttonFieldsGroup->layout()->setMargin( 11 );
    buttonFieldsGroupLayout = new TQHBoxLayout( buttonFieldsGroup->layout() );
    buttonFieldsGroupLayout->setAlignment( TQt::AlignTop );

    allRadioBatch = new TQRadioButton( buttonFieldsGroup, "allRadioBatch" );
    buttonFieldsGroupLayout->addWidget( allRadioBatch );

    inputRadioBatch = new TQRadioButton( buttonFieldsGroup, "inputRadioBatch" );
    inputRadioBatch->setChecked( true );
    buttonFieldsGroupLayout->addWidget( inputRadioBatch );
    tabLayout_2->addWidget( buttonFieldsGroup );

    groupFilesBox = new TQGroupBox( tab_2, "groupFilesBox" );
    groupFilesBox->setColumnLayout(0, TQt::Vertical );
    groupFilesBox->layout()->setSpacing( 6 );
    groupFilesBox->layout()->setMargin( 11 );
    groupFilesBoxLayout = new TQGridLayout( groupFilesBox->layout() );
    groupFilesBoxLayout->setAlignment( TQt::AlignTop );

    InputButtonBatch = new TQPushButton( groupFilesBox, "InputButtonBatch" );

    groupFilesBoxLayout->addWidget( InputButtonBatch, 0, 0 );

    InputLineEditBatch = new TQLineEdit( groupFilesBox, "InputLineEditBatch" );

    groupFilesBoxLayout->addWidget( InputLineEditBatch, 0, 1 );

    OutputLineEditBatch = new TQLineEdit( groupFilesBox, "OutputLineEditBatch" );

    groupFilesBoxLayout->addWidget( OutputLineEditBatch, 1, 1 );

    OutButtonBatch = new TQPushButton( groupFilesBox, "OutButtonBatch" );

    groupFilesBoxLayout->addWidget( OutButtonBatch, 1, 0 );
    tabLayout_2->addWidget( groupFilesBox );

    layout22 = new TQHBoxLayout( 0, 0, 6, "layout22"); 
    spacer20_2_2 = new TQSpacerItem( 151, 21, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layout22->addItem( spacer20_2_2 );

    runButtonBatch = new KPushButton( tab_2, "runButtonBatch" );
    runButtonBatch->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)5, 0, 0, runButtonBatch->sizePolicy().hasHeightForWidth() ) );
    layout22->addWidget( runButtonBatch );
    spacer19_2 = new TQSpacerItem( 131, 21, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    layout22->addItem( spacer19_2 );
    tabLayout_2->addLayout( layout22 );
    spacer27 = new TQSpacerItem( 41, 71, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    tabLayout_2->addItem( spacer27 );
    tabWidget3->insertTab( tab_2, TQString::fromLatin1("") );
    modCalcEquinoxDlgLayout->addWidget( tabWidget3 );
    languageChange();
    resize( TQSize(459, 477).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // signals and slots connections
    connect( Compute, TQ_SIGNAL( clicked() ), this, TQ_SLOT( slotComputeEquinoxesAndSolstices() ) );
    connect( InputButtonBatch, TQ_SIGNAL( clicked() ), this, TQ_SLOT( slotInputFile() ) );
    connect( OutButtonBatch, TQ_SIGNAL( clicked() ), this, TQ_SLOT( slotOutputFile() ) );
    connect( runButtonBatch, TQ_SIGNAL( clicked() ), this, TQ_SLOT( slotRunBatch() ) );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void modCalcEquinoxDlg::languageChange()
{
    setCaption( tr2i18n( "Equinoxes, Solstices & Seasons" ) );
    groupBox6->setTitle( tr2i18n( "Select Input" ) );
    equinoxSolsticesComboBox->clear();
    equinoxSolsticesComboBox->insertItem( tr2i18n( "Spring Equinox" ) );
    equinoxSolsticesComboBox->insertItem( tr2i18n( "Summer Solstice" ) );
    equinoxSolsticesComboBox->insertItem( tr2i18n( "Autumn Equinox" ) );
    equinoxSolsticesComboBox->insertItem( tr2i18n( "Winter Solstice" ) );
    textLabel1->setText( tr2i18n( "Year:" ) );
    Compute->setText( tr2i18n( "Compute" ) );
    Clear->setText( tr2i18n( "Clear" ) );
    groupBox7->setTitle( tr2i18n( "Season Information" ) );
    textLabel3->setText( tr2i18n( "Duration of the season:" ) );
    textLabel2->setText( tr2i18n( "Start date & time:" ) );
    tabWidget3->changeTab( tab, tr2i18n( "Interactive Mode" ) );
    InputBox_2_2->setTitle( tr2i18n( "Select Fields in Input File" ) );
    yearCheckBatch->setText( tr2i18n( "Year:" ) );
    buttonFieldsGroup->setTitle( tr2i18n( "Fields in Output File Plus Result" ) );
    allRadioBatch->setText( tr2i18n( "All parameters" ) );
    inputRadioBatch->setText( tr2i18n( "Only parameters in input file" ) );
    groupFilesBox->setTitle( tr2i18n( "Files" ) );
    InputButtonBatch->setText( tr2i18n( "Input File..." ) );
    TQToolTip::add( InputButtonBatch, tr2i18n( "File with the input data" ) );
    OutButtonBatch->setText( tr2i18n( "Output File..." ) );
    TQToolTip::add( OutButtonBatch, tr2i18n( "File for the output data" ) );
    runButtonBatch->setText( tr2i18n( "Run" ) );
    tabWidget3->changeTab( tab_2, tr2i18n( "Batch Mode" ) );
}

void modCalcEquinoxDlg::slotComputeEquinoxesAndSolstices()
{
    tqWarning( "modCalcEquinoxDlg::slotComputeEquinoxesAndSolstices(): Not implemented yet" );
}

void modCalcEquinoxDlg::slotInputFile()
{
    tqWarning( "modCalcEquinoxDlg::slotInputFile(): Not implemented yet" );
}

void modCalcEquinoxDlg::slotOutputFile()
{
    tqWarning( "modCalcEquinoxDlg::slotOutputFile(): Not implemented yet" );
}

void modCalcEquinoxDlg::slotRunBatch()
{
    tqWarning( "modCalcEquinoxDlg::slotRunBatch(): Not implemented yet" );
}

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

TQMetaObject *modCalcEquinoxDlg::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_modCalcEquinoxDlg( "modCalcEquinoxDlg", &modCalcEquinoxDlg::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

TQMetaObject* modCalcEquinoxDlg::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 = {"slotComputeEquinoxesAndSolstices", 0, 0 };
    static const TQUMethod slot_1 = {"slotInputFile", 0, 0 };
    static const TQUMethod slot_2 = {"slotOutputFile", 0, 0 };
    static const TQUMethod slot_3 = {"slotRunBatch", 0, 0 };
    static const TQUMethod slot_4 = {"languageChange", 0, 0 };
    static const TQMetaData slot_tbl[] = {
	{ "slotComputeEquinoxesAndSolstices()", &slot_0, TQMetaData::Public },
	{ "slotInputFile()", &slot_1, TQMetaData::Public },
	{ "slotOutputFile()", &slot_2, TQMetaData::Public },
	{ "slotRunBatch()", &slot_3, TQMetaData::Public },
	{ "languageChange()", &slot_4, TQMetaData::Protected }
    };
    metaObj = TQMetaObject::new_metaobject(
	"modCalcEquinoxDlg", parentObject,
	slot_tbl, 5,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_modCalcEquinoxDlg.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

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

bool modCalcEquinoxDlg::tqt_invoke( int _id, TQUObject* _o )
{
    switch ( _id - staticMetaObject()->slotOffset() ) {
    case 0: slotComputeEquinoxesAndSolstices(); break;
    case 1: slotInputFile(); break;
    case 2: slotOutputFile(); break;
    case 3: slotRunBatch(); break;
    case 4: languageChange(); break;
    default:
	return TQWidget::tqt_invoke( _id, _o );
    }
    return true;
}

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

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

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