#include <kdialog.h>
#include <klocale.h>
/****************************************************************************
** Form implementation generated from reading ui file './downloadcompletedialogbase.ui'
**
** Created: 木  7月 19 22:29:34 2007
**      by: The User Interface Compiler ($Id: qt/main.cpp   3.3.5   edited Aug 31 12:13 $)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

#include "downloadcompletedialogbase.h"

#include <qvariant.h>
#include <kpushbutton.h>
#include <qframe.h>
#include <qlabel.h>
#include <qlayout.h>
#include <qtooltip.h>
#include <qwhatsthis.h>
#include "kpushbutton.h"

/*
 *  Constructs a DownloadCompleteDialogBase as a child of 'parent', with the
 *  name 'name' and widget flags set to 'f'.
 *
 *  The dialog will by default be modeless, unless you set 'modal' to
 *  TRUE to construct a modal dialog.
 */
DownloadCompleteDialogBase::DownloadCompleteDialogBase( QWidget* parent, const char* name, bool modal, WFlags fl )
    : QDialog( parent, name, modal, fl )
{
    if ( !name )
	setName( "DownloadCompleteDialogBase" );
    setMinimumSize( QSize( 350, 120 ) );
    setMaximumSize( QSize( 350, 120 ) );
    setBaseSize( QSize( 340, 120 ) );

    m_CloseButton = new KPushButton( this, "m_CloseButton" );
    m_CloseButton->setGeometry( QRect( 240, 80, 100, 30 ) );

    frame3 = new QFrame( this, "frame3" );
    frame3->setGeometry( QRect( 10, 10, 330, 60 ) );
    frame3->setFrameShape( QFrame::StyledPanel );
    frame3->setFrameShadow( QFrame::Sunken );

    m_DetailLabel2 = new QLabel( frame3, "m_DetailLabel2" );
    m_DetailLabel2->setGeometry( QRect( 10, 30, 310, 20 ) );
    m_DetailLabel2->setAlignment( int( QLabel::AlignCenter ) );

    m_DetailLabel1 = new QLabel( frame3, "m_DetailLabel1" );
    m_DetailLabel1->setGeometry( QRect( 10, 10, 310, 20 ) );
    m_DetailLabel1->setAlignment( int( QLabel::AlignCenter ) );

    m_OpenAsButton = new KPushButton( this, "m_OpenAsButton" );
    m_OpenAsButton->setGeometry( QRect( 10, 80, 220, 30 ) );
    languageChange();
    resize( QSize(350, 120).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // signals and slots connections
    connect( m_CloseButton, SIGNAL( clicked() ), this, SLOT( slotCloseClicked() ) );
    connect( m_OpenAsButton, SIGNAL( clicked() ), this, SLOT( slotOpenAsClicked() ) );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void DownloadCompleteDialogBase::languageChange()
{
    setCaption( tr2i18n( "File Download Complete" ) );
    m_CloseButton->setText( tr2i18n( "Close" ) );
    m_CloseButton->setAccel( QKeySequence( QString::null ) );
    m_DetailLabel2->setText( tr2i18n( "95 sec  0 files" ) );
    m_DetailLabel1->setText( tr2i18n( "Total 0KB (0KB/s)" ) );
    m_OpenAsButton->setText( tr2i18n( "Open Folder as &Konqueror" ) );
    m_OpenAsButton->setAccel( QKeySequence( tr2i18n( "Alt+K" ) ) );
}

void DownloadCompleteDialogBase::slotOpenAsClicked()
{
    qWarning( "DownloadCompleteDialogBase::slotOpenAsClicked(): Not implemented yet" );
}

void DownloadCompleteDialogBase::slotCloseClicked()
{
    qWarning( "DownloadCompleteDialogBase::slotCloseClicked(): Not implemented yet" );
}

#include "downloadcompletedialogbase.moc"
