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

#include "startdialog.h"

#include <ntqvariant.h>
#include <ntqpushbutton.h>
#include <ntqtabwidget.h>
#include <ntqwidget.h>
#include <ntqiconview.h>
#include <ntqlabel.h>
#include <ntqcheckbox.h>
#include <ntqlayout.h>
#include <ntqtooltip.h>
#include <ntqwhatsthis.h>

/*
 *  Constructs a StartDialogBase 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.
 */
StartDialogBase::StartDialogBase( TQWidget* parent, const char* name, bool modal, WFlags fl )
    : TQDialog( parent, name, modal, fl )
{
    if ( !name )
	setName( "StartDialogBase" );
    setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)5, (TQSizePolicy::SizeType)5, 0, 0, sizePolicy().hasHeightForWidth() ) );
    setSizeGripEnabled( true );
    StartDialogBaseLayout = new TQVBoxLayout( this, 11, 6, "StartDialogBaseLayout"); 

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

    Widget8 = new TQWidget( tabWidget, "Widget8" );
    Widget8Layout = new TQGridLayout( Widget8, 1, 1, 11, 6, "Widget8Layout"); 

    templateView = new TQIconView( Widget8, "templateView" );
    templateView->setGridX( 120 );
    templateView->setResizeMode( TQIconView::Adjust );
    templateView->setItemsMovable( false );

    Widget8Layout->addMultiCellWidget( templateView, 1, 1, 0, 2 );
    tabWidget->insertTab( Widget8, TQString::fromLatin1("") );

    tab = new TQWidget( tabWidget, "tab" );
    tabLayout = new TQHBoxLayout( tab, 11, 6, "tabLayout"); 
    tabWidget->insertTab( tab, TQString::fromLatin1("") );

    Widget9 = new TQWidget( tabWidget, "Widget9" );
    Widget9Layout = new TQGridLayout( Widget9, 1, 1, 11, 6, "Widget9Layout"); 

    recentView = new TQIconView( Widget9, "recentView" );
    recentView->setFocusPolicy( TQIconView::WheelFocus );
    recentView->setGridX( 120 );
    recentView->setResizeMode( TQIconView::Adjust );
    recentView->setItemsMovable( false );

    Widget9Layout->addWidget( recentView, 0, 0 );

    fileInfoLabel = new TQLabel( Widget9, "fileInfoLabel" );
    fileInfoLabel->setSizePolicy( TQSizePolicy( (TQSizePolicy::SizeType)2, (TQSizePolicy::SizeType)5, 0, 0, fileInfoLabel->sizePolicy().hasHeightForWidth() ) );

    Widget9Layout->addWidget( fileInfoLabel, 1, 0 );
    tabWidget->insertTab( Widget9, TQString::fromLatin1("") );
    StartDialogBaseLayout->addWidget( tabWidget );

    checkShowInFuture = new TQCheckBox( this, "checkShowInFuture" );
    StartDialogBaseLayout->addWidget( checkShowInFuture );

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

    buttonHelp = new TQPushButton( this, "buttonHelp" );
    buttonHelp->setAutoDefault( true );
    Layout1->addWidget( buttonHelp );
    Horizontal_Spacing2 = new TQSpacerItem( 0, 20, TQSizePolicy::Expanding, TQSizePolicy::Minimum );
    Layout1->addItem( Horizontal_Spacing2 );

    buttonOk = new TQPushButton( this, "buttonOk" );
    buttonOk->setAutoDefault( true );
    buttonOk->setDefault( true );
    Layout1->addWidget( buttonOk );

    buttonCancel = new TQPushButton( this, "buttonCancel" );
    buttonCancel->setAutoDefault( true );
    Layout1->addWidget( buttonCancel );
    StartDialogBaseLayout->addLayout( Layout1 );
    languageChange();
    resize( TQSize(576, 420).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // signals and slots connections
    connect( buttonOk, TQ_SIGNAL( clicked() ), this, TQ_SLOT( accept() ) );
    connect( buttonCancel, TQ_SIGNAL( clicked() ), this, TQ_SLOT( reject() ) );
    connect( templateView, TQ_SIGNAL( doubleClicked(TQIconViewItem*) ), this, TQ_SLOT( accept() ) );
    connect( templateView, TQ_SIGNAL( returnPressed(TQIconViewItem*) ), this, TQ_SLOT( accept() ) );
    connect( recentView, TQ_SIGNAL( doubleClicked(TQIconViewItem*) ), this, TQ_SLOT( accept() ) );
    connect( recentView, TQ_SIGNAL( onItem(TQIconViewItem*) ), this, TQ_SLOT( recentItemChanged(TQIconViewItem*) ) );
    connect( recentView, TQ_SIGNAL( onViewport() ), this, TQ_SLOT( clearFileInfo() ) );
    connect( recentView, TQ_SIGNAL( returnPressed(TQIconViewItem*) ), this, TQ_SLOT( accept() ) );
    connect( recentView, TQ_SIGNAL( selectionChanged(TQIconViewItem*) ), this, TQ_SLOT( recentItemChanged(TQIconViewItem*) ) );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void StartDialogBase::languageChange()
{
    setCaption( tr( "TQt Designer - New/Open" ) );
    tabWidget->changeTab( Widget8, tr( "&New File/Project" ) );
    tabWidget->changeTab( tab, tr( "&Open File/Project" ) );
    fileInfoLabel->setText( TQString::null );
    tabWidget->changeTab( Widget9, tr( "&Recently Opened" ) );
    checkShowInFuture->setText( tr( "&Don't show this dialog in the future" ) );
    buttonHelp->setText( tr( "&Help" ) );
    buttonOk->setText( tr( "OK" ) );
    buttonCancel->setText( tr( "Cancel" ) );
}

void StartDialogBase::recentItemChanged(TQIconViewItem*)
{
    tqWarning( "StartDialogBase::recentItemChanged(TQIconViewItem*): Not implemented yet" );
}

void StartDialogBase::clearFileInfo()
{
    tqWarning( "StartDialogBase::clearFileInfo(): Not implemented yet" );
}

void StartDialogBase::accept()
{
    tqWarning( "StartDialogBase::accept(): Not implemented yet" );
}

void StartDialogBase::reject()
{
    tqWarning( "StartDialogBase::reject(): Not implemented yet" );
}

