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

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

#include "svnintegratordlgbase.h"

#include <ntqvariant.h>
#include <kurlrequester.h>
#include <ntqbuttongroup.h>
#include <ntqradiobutton.h>
#include <ntqlabel.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

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

    buttonGroup1 = new TQButtonGroup( this, "buttonGroup1" );
    buttonGroup1->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)7, 0, 0, buttonGroup1->sizePolicy().hasHeightForWidth() ) );
    buttonGroup1->setFrameShape( TQButtonGroup::NoFrame );
    buttonGroup1->setFrameShadow( TQButtonGroup::Sunken );
    buttonGroup1->setColumnLayout(0, TQt::Vertical );
    buttonGroup1->layout()->setSpacing( 6 );
    buttonGroup1->layout()->setMargin( 0 );
    buttonGroup1Layout = new TQVBoxLayout( buttonGroup1->layout() );
    buttonGroup1Layout->setAlignment( TQt::AlignTop );

    doNothing = new TQRadioButton( buttonGroup1, "doNothing" );
    doNothing->setChecked( true );
    buttonGroup1Layout->addWidget( doNothing );

    createProject = new TQRadioButton( buttonGroup1, "createProject" );
    buttonGroup1Layout->addWidget( createProject );

    textLabel1 = new TQLabel( buttonGroup1, "textLabel1" );
    buttonGroup1Layout->addWidget( textLabel1 );

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

    repositoryLabel1 = new TQLabel( buttonGroup1, "repositoryLabel1" );
    repositoryLabel1->setEnabled( false );
    layout5->addWidget( repositoryLabel1 );

    repos1 = new KURLRequester( buttonGroup1, "repos1" );
    repos1->setEnabled( false );
    layout5->addWidget( repos1 );
    buttonGroup1Layout->addLayout( layout5 );
    spacer9 = new TQSpacerItem( 21, 131, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    buttonGroup1Layout->addItem( spacer9 );

    SvnIntegratorDlgBaseLayout->addWidget( buttonGroup1, 0, 0 );
    languageChange();
    resize( TQSize(648, 429).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // signals and slots connections
    connect( createProject, TQ_SIGNAL( toggled(bool) ), repositoryLabel1, TQ_SLOT( setEnabled(bool) ) );
    connect( createProject, TQ_SIGNAL( toggled(bool) ), repos1, TQ_SLOT( setEnabled(bool) ) );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void SvnIntegratorDlgBase::languageChange()
{
    buttonGroup1->setTitle( TQString::null );
    doNothing->setText( tr2i18n( "&Do not do anything" ) );
    TQToolTip::add( doNothing, tr2i18n( "Adds subversion menus to project.\n"
"\n"
"NOTE: Unless you import the project\n"
"out of tdevelop, you will not be able\n"
"to perform any subversion operations." ) );
    TQWhatsThis::add( doNothing, tr2i18n( "Adds subversion menus to project.\n"
"\n"
"NOTE: Unless you import the project\n"
"out of tdevelop, you will not be able\n"
"to perform any subversion operations." ) );
    createProject->setText( tr2i18n( "&Create a project tree and import new project into trunk, then checkout from the repository" ) );
    TQToolTip::add( createProject, tr2i18n( "Creates project, imports it into the subversion\n"
"repository and checks it out as a working copy.\n"
"\n"
"NOTE: The repository has to exist.\n"
"e.g. has been created with 'svnadmin'" ) );
    TQWhatsThis::add( createProject, tr2i18n( "Creates project, imports it into the subversion\n"
"repository and checks it out as a working copy.\n"
"\n"
"NOTE: The repository has to exist.\n"
"e.g. has been created with 'svnadmin'" ) );
    textLabel1->setText( tr2i18n( "Example for the url (if /home/user/subversion is the subversion repository):\n"
"file:///home/user/subversion/mynewproject" ) );
    repositoryLabel1->setText( tr2i18n( "Repository:" ) );
    TQToolTip::add( repos1, tr2i18n( "Subversion repository location.\n"
"The repository has to exist -\n"
"e.g. has been created with 'svnadmin'" ) );
    TQWhatsThis::add( repos1, tr2i18n( "Subversion repository location. This should include the subdirectory for the project in the repository. The project subdirectory and further subdirectories will be created. \n"
"\n"
"So for example if you give http://localhost/svn/projectname the following directories will be created and the project imported into the trunk subdirectory:\n"
"http://localhost/svn/projectname\n"
"http://localhost/svn/projectname/tags\n"
"http://localhost/svn/projectname/branches\n"
"http://localhost/svn/projectname/trunk" ) );
}

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

TQMetaObject *SvnIntegratorDlgBase::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_SvnIntegratorDlgBase( "SvnIntegratorDlgBase", &SvnIntegratorDlgBase::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

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

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

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

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

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

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