#include "simapi.h"
/****************************************************************************
** Form implementation generated from reading ui file './phonebase.ui'
**
** Created: вт мар 30 16:42:24 2004
**      by: The User Interface Compiler ($Id: qt/main.cpp   3.1.2   edited Dec 19 11:45 $)
**
** WARNING! All changes made in this file will be lost!
****************************************************************************/

#include "phonebase.h"

#include <qvariant.h>
#include <qwidget.h>
#include <qlabel.h>
#include <qcombobox.h>
#include <qlineedit.h>
#include <qlayout.h>
#include <qtooltip.h>
#include <qwhatsthis.h>
#include <qimage.h>
#include <qpixmap.h>

static const char* const img0_phonebase[] = { 
"22 22 2 1",
". c None",
"# c #a4c610",
"........######........",
".....###########......",
"....##############....",
"...################...",
"..######......######..",
"..#####........#####..",
".#####.......#..#####.",
".####.......###..####.",
"####.......#####..####",
"####......#####...####",
"####....#######...####",
"####....######....####",
"####...########...####",
".####.##########..####",
".####..####.#########.",
".#####..##...########.",
"..#####.......#######.",
"..######......######..",
"...###################",
"....##################",
"......###########.###.",
"........######.....#.."};


/* 
 *  Constructs a PhoneDetailsBase as a child of 'parent', with the 
 *  name 'name' and widget flags set to 'f'.
 */
PhoneDetailsBase::PhoneDetailsBase( QWidget* parent, const char* name, WFlags fl )
    : QWidget( parent, name, fl ),
      image0( (const char **) img0_phonebase )
{
    if ( !name )
	setName( "phoneDetails" );
    setProperty( "sizePolicy", QSizePolicy( (QSizePolicy::SizeType)1, (QSizePolicy::SizeType)1, 0, 0, sizePolicy().hasHeightForWidth() ) );
    phoneDetailsLayout = new QVBoxLayout( this, 11, 6, "phoneDetailsLayout"); 

    Layout7 = new QGridLayout( 0, 1, 1, 0, 6, "Layout7"); 

    lblAreaCode = new QLabel( this, "lblAreaCode" );
    lblAreaCode->setProperty( "alignment", int( QLabel::AlignCenter ) );

    Layout7->addWidget( lblAreaCode, 0, 2 );

    cmbCountry = new QComboBox( FALSE, this, "cmbCountry" );

    Layout7->addWidget( cmbCountry, 1, 0 );

    lblExtension = new QLabel( this, "lblExtension" );
    lblExtension->setProperty( "alignment", int( QLabel::AlignCenter ) );

    Layout7->addWidget( lblExtension, 0, 6 );

    edtExtension = new QLineEdit( this, "edtExtension" );
    edtExtension->setProperty( "sizePolicy", QSizePolicy( (QSizePolicy::SizeType)1, (QSizePolicy::SizeType)0, 0, 0, edtExtension->sizePolicy().hasHeightForWidth() ) );

    Layout7->addWidget( edtExtension, 1, 6 );

    edtAreaCode = new QLineEdit( this, "edtAreaCode" );
    edtAreaCode->setProperty( "sizePolicy", QSizePolicy( (QSizePolicy::SizeType)1, (QSizePolicy::SizeType)0, 0, 0, edtAreaCode->sizePolicy().hasHeightForWidth() ) );

    Layout7->addWidget( edtAreaCode, 1, 2 );

    edtNumber = new QLineEdit( this, "edtNumber" );

    Layout7->addWidget( edtNumber, 1, 4 );

    TextLabel2 = new QLabel( this, "TextLabel2" );

    Layout7->addWidget( TextLabel2, 1, 1 );

    TextLabel5 = new QLabel( this, "TextLabel5" );
    TextLabel5->setProperty( "alignment", int( QLabel::AlignCenter ) );

    Layout7->addWidget( TextLabel5, 0, 4 );

    TextLabel4 = new QLabel( this, "TextLabel4" );

    Layout7->addWidget( TextLabel4, 1, 3 );

    TextLabel1 = new QLabel( this, "TextLabel1" );
    TextLabel1->setProperty( "alignment", int( QLabel::AlignCenter ) );

    Layout7->addWidget( TextLabel1, 0, 0 );

    lblDivExtension = new QLabel( this, "lblDivExtension" );
    lblDivExtension->setProperty( "alignment", int( QLabel::AlignVCenter | QLabel::AlignLeft ) );

    Layout7->addWidget( lblDivExtension, 1, 5 );
    phoneDetailsLayout->addLayout( Layout7 );
    QSpacerItem* spacer = new QSpacerItem( 20, 20, QSizePolicy::Minimum, QSizePolicy::Expanding );
    phoneDetailsLayout->addItem( spacer );
    languageChange();
    resize( QSize(403, 130).expandedTo(minimumSizeHint()) );
    clearWState( WState_Polished );

    // tab order
    setTabOrder( cmbCountry, edtAreaCode );
    setTabOrder( edtAreaCode, edtNumber );
    setTabOrder( edtNumber, edtExtension );
}

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

/*
 *  Sets the strings of the subwidgets using the current
 *  language.
 */
void PhoneDetailsBase::languageChange()
{
    setProperty( "caption", i18n( "Form1" ) );
    lblAreaCode->setProperty( "text", i18n( "Area code:" ) );
    lblExtension->setProperty( "text", i18n( "Extension:" ) );
    TextLabel2->setProperty( "text", i18n( "-" ) );
    TextLabel5->setProperty( "text", i18n( "Number:" ) );
    TextLabel4->setProperty( "text", i18n( "-" ) );
    TextLabel1->setProperty( "text", i18n( "Country:" ) );
    lblDivExtension->setProperty( "text", i18n( "-" ) );
}

#include "phonebase.moc"
