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

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

#include "slideshowcfg.h"

#include <ntqvariant.h>
#include <kurlrequester.h>
#include <ntqcheckbox.h>
#include <ntqlabel.h>
#include <ntqspinbox.h>
#include <ntqframe.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

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

    mCbxSubdirectory = new TQCheckBox( this, "mCbxSubdirectory" );

    Form1Layout->addMultiCellWidget( mCbxSubdirectory, 7, 7, 0, 3 );

    mCbxRandom = new TQCheckBox( this, "mCbxRandom" );

    Form1Layout->addMultiCellWidget( mCbxRandom, 1, 1, 0, 2 );

    mDirChooser = new KURLRequester( this, "mDirChooser" );

    Form1Layout->addMultiCellWidget( mDirChooser, 6, 6, 2, 4 );

    mCbxZoom = new TQCheckBox( this, "mCbxZoom" );

    Form1Layout->addMultiCellWidget( mCbxZoom, 0, 0, 0, 2 );
    spacer9 = new TQSpacerItem( 161, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    Form1Layout->addItem( spacer9, 7, 4 );

    textLabel1 = new TQLabel( this, "textLabel1" );

    Form1Layout->addMultiCellWidget( textLabel1, 6, 6, 0, 1 );

    mCbxShowName = new TQCheckBox( this, "mCbxShowName" );

    Form1Layout->addMultiCellWidget( mCbxShowName, 2, 2, 0, 2 );
    spacer11 = new TQSpacerItem( 20, 19, TQSizePolicy::Minimum, TQSizePolicy::Expanding );
    Form1Layout->addItem( spacer11, 5, 1 );

    mDelay = new TQSpinBox( this, "mDelay" );
    mDelay->setMaxValue( 240 );
    mDelay->setMinValue( 1 );

    Form1Layout->addMultiCellWidget( mDelay, 4, 4, 1, 2 );

    textLabel1_2 = new TQLabel( this, "textLabel1_2" );

    Form1Layout->addWidget( textLabel1_2, 4, 0 );

    mCbxRandomPosition = new TQCheckBox( this, "mCbxRandomPosition" );

    Form1Layout->addMultiCellWidget( mCbxRandomPosition, 3, 3, 0, 2 );

    mPreview = new TQFrame( this, "mPreview" );
    mPreview->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)7, (TQSizePolicy::SizeType)7, 0, 0, mPreview->sizePolicy().hasHeightForWidth() ) );
    mPreview->setFrameShape( TQFrame::NoFrame );
    mPreview->setFrameShadow( TQFrame::Plain );

    Form1Layout->addMultiCellWidget( mPreview, 0, 5, 3, 4 );
    languageChange();
    resize( TQSize(400, 243).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // signals and slots connections
    connect( mCbxZoom, TQ_SIGNAL( toggled(bool) ), mCbxRandomPosition, TQ_SLOT( setDisabled(bool) ) );

    // buddies
    textLabel1->setBuddy( mDirChooser );
    textLabel1_2->setBuddy( mDelay );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void SlideShowCfg::languageChange()
{
    mCbxSubdirectory->setText( tr2i18n( "&Include images from sub-folders" ) );
    mCbxRandom->setText( tr2i18n( "&Random order" ) );
    mCbxZoom->setText( tr2i18n( "Resi&ze images" ) );
    textLabel1->setText( tr2i18n( "I&mage folder:" ) );
    mCbxShowName->setText( tr2i18n( "Show &names" ) );
    mDelay->setSuffix( tr2i18n( " sec" ) );
    mDelay->setSpecialValueText( TQString::null );
    textLabel1_2->setText( tr2i18n( "&Delay:" ) );
    mCbxRandomPosition->setText( tr2i18n( "Random &position" ) );
}

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

TQMetaObject *SlideShowCfg::metaObj = 0;
static TQMetaObjectCleanUp cleanUp_SlideShowCfg( "SlideShowCfg", &SlideShowCfg::staticMetaObject );

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

#endif // TQT_NO_TRANSLATION

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

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

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

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

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

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