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

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

#include "adaproject_optionsdlgbase.h"

#include <ntqvariant.h>
#include <kdialog.h>
#include <kurlrequester.h>
#include <ntqlabel.h>
#include <ntqcombobox.h>
#include <ntqpushbutton.h>
#include <ntqlineedit.h>
#include <ntqframe.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

/*
 *  Constructs a AdaProjectOptionsDlgBase as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 */
AdaProjectOptionsDlgBase::AdaProjectOptionsDlgBase( TQWidget* parent, const char* name, WFlags fl )
    : TQWidget( parent, name, fl )
{
    if ( !name )
	setName( "AdaProjectOptionsDlgBase" );
    setEnabled( true );
    AdaProjectOptionsDlgBaseLayout = new TQGridLayout( this, 1, 1, KDialog::marginHint(), KDialog::spacingHint(), "AdaProjectOptionsDlgBaseLayout"); 
    spacer1 = new TQSpacerItem( 20, 160, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    AdaProjectOptionsDlgBaseLayout->addItem( spacer1, 10, 1 );

    configuration_layout = new TQHBoxLayout( 0, 0, KDialog::spacingHint(), "configuration_layout"); 

    config_label = new TQLabel( this, "config_label" );
    config_label->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)1, (TQSizePolicy::SizeType)5, 0, 0, config_label->sizePolicy().hasHeightForWidth() ) );
    configuration_layout->addWidget( config_label );

    config_combo = new TQComboBox( false, this, "config_combo" );
    config_combo->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)3, (TQSizePolicy::SizeType)0, 0, 0, config_combo->sizePolicy().hasHeightForWidth() ) );
    config_combo->setEditable( true );
    configuration_layout->addWidget( config_combo );
    Spacer17_2 = new TQSpacerItem( 20, 8, TQSizePolicy::Fixed, TQSizePolicy::Minimum );
    configuration_layout->addItem( Spacer17_2 );

    addconfig_button = new TQPushButton( this, "addconfig_button" );
    configuration_layout->addWidget( addconfig_button );

    removeconfig_button = new TQPushButton( this, "removeconfig_button" );
    configuration_layout->addWidget( removeconfig_button );
    Spacer18_2 = new TQSpacerItem( 20, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    configuration_layout->addItem( Spacer18_2 );

    AdaProjectOptionsDlgBaseLayout->addMultiCellLayout( configuration_layout, 0, 0, 0, 4 );

    options_button = new TQPushButton( this, "options_button" );
    options_button->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)0, (TQSizePolicy::SizeType)0, 0, 0, options_button->sizePolicy().hasHeightForWidth() ) );
    options_button->setMaximumSize( TQSize( 30, 32767 ) );

    AdaProjectOptionsDlgBaseLayout->addWidget( options_button, 6, 4 );

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

    AdaProjectOptionsDlgBaseLayout->addWidget( options_label, 6, 0 );

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

    AdaProjectOptionsDlgBaseLayout->addWidget( compiler_label, 2, 0 );

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

    AdaProjectOptionsDlgBaseLayout->addMultiCellWidget( exec_edit, 4, 4, 1, 3 );

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

    AdaProjectOptionsDlgBaseLayout->addMultiCellWidget( options_edit, 6, 6, 1, 3 );

    compiler_box = new TQComboBox( false, this, "compiler_box" );

    AdaProjectOptionsDlgBaseLayout->addMultiCellWidget( compiler_box, 2, 2, 1, 3 );

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

    AdaProjectOptionsDlgBaseLayout->addWidget( exec_label, 4, 0 );

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

    AdaProjectOptionsDlgBaseLayout->addMultiCellWidget( configuration_line, 1, 1, 0, 4 );
    spacer11 = new TQSpacerItem( 20, 16, TQSizePolicy::Minimum, TQSizePolicy::Fixed );
    AdaProjectOptionsDlgBaseLayout->addItem( spacer11, 3, 1 );
    spacer12 = new TQSpacerItem( 20, 16, TQSizePolicy::Minimum, TQSizePolicy::Fixed );
    AdaProjectOptionsDlgBaseLayout->addItem( spacer12, 5, 3 );

    mainSourceUrl = new KURLRequester( this, "mainSourceUrl" );
    mainSourceUrl->setMinimumSize( TQSize( 0, 26 ) );
    mainSourceUrl->setFocusPolicy( KURLRequester::WheelFocus );

    AdaProjectOptionsDlgBaseLayout->addMultiCellWidget( mainSourceUrl, 9, 9, 1, 4 );

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

    AdaProjectOptionsDlgBaseLayout->addWidget( mainSourceLabel, 9, 0 );
    spacer13 = new TQSpacerItem( 20, 30, TQSizePolicy::Minimum, TQSizePolicy::Fixed );
    AdaProjectOptionsDlgBaseLayout->addItem( spacer13, 8, 2 );
    spacer7 = new TQSpacerItem( 400, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    AdaProjectOptionsDlgBaseLayout->addMultiCell( spacer7, 7, 7, 0, 2 );

    defaultopts_button = new TQPushButton( this, "defaultopts_button" );

    AdaProjectOptionsDlgBaseLayout->addMultiCellWidget( defaultopts_button, 7, 7, 3, 4 );
    languageChange();
    resize( TQSize(600, 480).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // signals and slots connections
    connect( compiler_box, TQ_SIGNAL( activated(const TQString&) ), this, TQ_SLOT( compiler_box_activated(const TQString&) ) );
    connect( removeconfig_button, TQ_SIGNAL( clicked() ), this, TQ_SLOT( configRemoved() ) );
    connect( config_combo, TQ_SIGNAL( textChanged(const TQString&) ), this, TQ_SLOT( configComboTextChanged(const TQString&) ) );
    connect( config_combo, TQ_SIGNAL( activated(const TQString&) ), this, TQ_SLOT( configChanged(const TQString&) ) );
    connect( addconfig_button, TQ_SIGNAL( clicked() ), this, TQ_SLOT( configAdded() ) );
    connect( options_button, TQ_SIGNAL( clicked() ), this, TQ_SLOT( optionsButtonClicked() ) );
    connect( exec_edit, TQ_SIGNAL( textChanged(const TQString&) ), this, TQ_SLOT( setDirty() ) );
    connect( options_edit, TQ_SIGNAL( textChanged(const TQString&) ), this, TQ_SLOT( setDirty() ) );
    connect( mainSourceUrl, TQ_SIGNAL( textChanged(const TQString&) ), this, TQ_SLOT( setDirty() ) );
    connect( mainSourceUrl, TQ_SIGNAL( urlSelected(const TQString&) ), this, TQ_SLOT( setDirty() ) );
    connect( compiler_box, TQ_SIGNAL( activated(const TQString&) ), this, TQ_SLOT( setDirty() ) );
    connect( compiler_box, TQ_SIGNAL( textChanged(const TQString&) ), this, TQ_SLOT( setDirty() ) );
    connect( defaultopts_button, TQ_SIGNAL( clicked() ), this, TQ_SLOT( setDefaultOptions() ) );
    connect( defaultopts_button, TQ_SIGNAL( clicked() ), this, TQ_SLOT( setDirty() ) );

    // tab order
    setTabOrder( compiler_box, exec_edit );
    setTabOrder( exec_edit, options_edit );
    setTabOrder( options_edit, options_button );
    setTabOrder( options_button, mainSourceUrl );
    setTabOrder( mainSourceUrl, config_combo );
    setTabOrder( config_combo, addconfig_button );
    setTabOrder( addconfig_button, removeconfig_button );

    // buddies
    options_label->setBuddy( compiler_box );
    compiler_label->setBuddy( compiler_box );
    exec_label->setBuddy( compiler_box );
    mainSourceLabel->setBuddy( compiler_box );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void AdaProjectOptionsDlgBase::languageChange()
{
    setCaption( tr2i18n( "Ada Compiler" ) );
    config_label->setText( tr2i18n( "Configuration:" ) );
    addconfig_button->setText( tr2i18n( "Add" ) );
    removeconfig_button->setText( tr2i18n( "Remove" ) );
    options_button->setText( tr2i18n( "..." ) );
    options_label->setText( tr2i18n( "Compiler &options:" ) );
    compiler_label->setText( tr2i18n( "Ada &compiler:" ) );
    exec_label->setText( tr2i18n( "Compiler co&mmand:" ) );
    mainSourceLabel->setText( tr2i18n( "Main &source file:" ) );
    defaultopts_button->setText( tr2i18n( "Load Default Compiler Options" ) );
}

void AdaProjectOptionsDlgBase::compiler_box_activated(const TQString&)
{
    tqWarning( "AdaProjectOptionsDlgBase::compiler_box_activated(const TQString&): Not implemented yet" );
}

void AdaProjectOptionsDlgBase::addconfig_button_clicked()
{
    tqWarning( "AdaProjectOptionsDlgBase::addconfig_button_clicked(): Not implemented yet" );
}

void AdaProjectOptionsDlgBase::configRemoved()
{
    tqWarning( "AdaProjectOptionsDlgBase::configRemoved(): Not implemented yet" );
}

void AdaProjectOptionsDlgBase::configComboTextChanged(const TQString&)
{
    tqWarning( "AdaProjectOptionsDlgBase::configComboTextChanged(const TQString&): Not implemented yet" );
}

void AdaProjectOptionsDlgBase::configChanged(const TQString&)
{
    tqWarning( "AdaProjectOptionsDlgBase::configChanged(const TQString&): Not implemented yet" );
}

void AdaProjectOptionsDlgBase::optionsButtonClicked()
{
    tqWarning( "AdaProjectOptionsDlgBase::optionsButtonClicked(): Not implemented yet" );
}

void AdaProjectOptionsDlgBase::configAdded()
{
    tqWarning( "AdaProjectOptionsDlgBase::configAdded(): Not implemented yet" );
}

void AdaProjectOptionsDlgBase::setDirty()
{
    tqWarning( "AdaProjectOptionsDlgBase::setDirty(): Not implemented yet" );
}

void AdaProjectOptionsDlgBase::setDefaultOptions()
{
    tqWarning( "AdaProjectOptionsDlgBase::setDefaultOptions(): Not implemented yet" );
}

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

TQMetaObject *AdaProjectOptionsDlgBase::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_AdaProjectOptionsDlgBase( "AdaProjectOptionsDlgBase", &AdaProjectOptionsDlgBase::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

TQMetaObject* AdaProjectOptionsDlgBase::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 TQUParameter param_slot_1[] = {
	{ 0, &static_QUType_TQString, 0, TQUParameter::In }
    };
    static const TQUMethod slot_1 = {"compiler_box_activated", 1, param_slot_1 };
    static const TQUMethod slot_2 = {"addconfig_button_clicked", 0, 0 };
    static const TQUMethod slot_3 = {"configRemoved", 0, 0 };
    static const TQUParameter param_slot_4[] = {
	{ 0, &static_QUType_TQString, 0, TQUParameter::In }
    };
    static const TQUMethod slot_4 = {"configComboTextChanged", 1, param_slot_4 };
    static const TQUParameter param_slot_5[] = {
	{ 0, &static_QUType_TQString, 0, TQUParameter::In }
    };
    static const TQUMethod slot_5 = {"configChanged", 1, param_slot_5 };
    static const TQUMethod slot_6 = {"optionsButtonClicked", 0, 0 };
    static const TQUMethod slot_7 = {"configAdded", 0, 0 };
    static const TQUMethod slot_8 = {"setDirty", 0, 0 };
    static const TQUMethod slot_9 = {"setDefaultOptions", 0, 0 };
    static const TQMetaData slot_tbl[] = {
	{ "languageChange()", &slot_0, TQMetaData::Protected },
	{ "compiler_box_activated(const TQString&)", &slot_1, TQMetaData::Protected },
	{ "addconfig_button_clicked()", &slot_2, TQMetaData::Protected },
	{ "configRemoved()", &slot_3, TQMetaData::Protected },
	{ "configComboTextChanged(const TQString&)", &slot_4, TQMetaData::Protected },
	{ "configChanged(const TQString&)", &slot_5, TQMetaData::Protected },
	{ "optionsButtonClicked()", &slot_6, TQMetaData::Protected },
	{ "configAdded()", &slot_7, TQMetaData::Protected },
	{ "setDirty()", &slot_8, TQMetaData::Protected },
	{ "setDefaultOptions()", &slot_9, TQMetaData::Protected }
    };
    metaObj = TQMetaObject::new_metaobject(
	"AdaProjectOptionsDlgBase", parentObject,
	slot_tbl, 10,
	0, 0,
#ifndef TQT_NO_PROPERTIES
	0, 0,
	0, 0,
#endif // TQT_NO_PROPERTIES
	0, 0 );
    cleanUp_AdaProjectOptionsDlgBase.setMetaObject( metaObj );
#ifdef TQT_THREAD_SUPPORT
    if (tqt_sharedMetaObjectMutex) tqt_sharedMetaObjectMutex->unlock();
#endif // TQT_THREAD_SUPPORT
    return metaObj;
}

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

bool AdaProjectOptionsDlgBase::tqt_invoke( int _id, TQUObject* _o )
{
    switch ( _id - staticMetaObject()->slotOffset() ) {
    case 0: languageChange(); break;
    case 1: compiler_box_activated((const TQString&)static_QUType_TQString.get(_o+1)); break;
    case 2: addconfig_button_clicked(); break;
    case 3: configRemoved(); break;
    case 4: configComboTextChanged((const TQString&)static_QUType_TQString.get(_o+1)); break;
    case 5: configChanged((const TQString&)static_QUType_TQString.get(_o+1)); break;
    case 6: optionsButtonClicked(); break;
    case 7: configAdded(); break;
    case 8: setDirty(); break;
    case 9: setDefaultOptions(); break;
    default:
	return TQWidget::tqt_invoke( _id, _o );
    }
    return true;
}

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

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

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