kaddressbook
imaddressbase.cpp00001 #include <kdialog.h>
00002 #include <klocale.h>
00003
00004
00005
00006
00007
00008
00009
00010
00011 #include "imaddressbase.h"
00012
00013 #include <qvariant.h>
00014 #include <qcombobox.h>
00015 #include <qlabel.h>
00016 #include <qlineedit.h>
00017 #include <qlayout.h>
00018 #include <qtooltip.h>
00019 #include <qwhatsthis.h>
00020
00021
00022
00023
00024
00025 IMAddressBase::IMAddressBase( QWidget* parent, const char* name, WFlags fl )
00026 : QWidget( parent, name, fl )
00027 {
00028 if ( !name )
00029 setName( "IMAddressBase" );
00030 setSizePolicy( QSizePolicy( (QSizePolicy::SizeType)0, (QSizePolicy::SizeType)5, 0, 0, sizePolicy().hasHeightForWidth() ) );
00031 IMAddressBaseLayout = new QGridLayout( this, 1, 1, 11, 6, "IMAddressBaseLayout");
00032
00033 cmbProtocol = new QComboBox( FALSE, this, "cmbProtocol" );
00034
00035 IMAddressBaseLayout->addWidget( cmbProtocol, 0, 1 );
00036
00037 labelProtocol = new QLabel( this, "labelProtocol" );
00038
00039 IMAddressBaseLayout->addWidget( labelProtocol, 0, 0 );
00040
00041 edtAddress = new QLineEdit( this, "edtAddress" );
00042
00043 IMAddressBaseLayout->addWidget( edtAddress, 1, 1 );
00044
00045 labelAddress = new QLabel( this, "labelAddress" );
00046
00047 IMAddressBaseLayout->addWidget( labelAddress, 1, 0 );
00048
00049 labelNetwork = new QLabel( this, "labelNetwork" );
00050
00051 IMAddressBaseLayout->addWidget( labelNetwork, 2, 0 );
00052
00053 edtNetwork = new QLineEdit( this, "edtNetwork" );
00054
00055 IMAddressBaseLayout->addWidget( edtNetwork, 2, 1 );
00056 languageChange();
00057 resize( QSize(208, 121).expandedTo(minimumSizeHint()) );
00058 clearWState( WState_Polished );
00059
00060
00061 setTabOrder( cmbProtocol, edtAddress );
00062
00063
00064 labelProtocol->setBuddy( cmbProtocol );
00065 labelAddress->setBuddy( edtAddress );
00066 labelNetwork->setBuddy( edtNetwork );
00067 }
00068
00069
00070
00071
00072 IMAddressBase::~IMAddressBase()
00073 {
00074
00075 }
00076
00077
00078
00079
00080
00081 void IMAddressBase::languageChange()
00082 {
00083 setCaption( tr2i18n( "Edit Address" ) );
00084 labelProtocol->setText( tr2i18n( "&Protocol:" ) );
00085 labelAddress->setText( tr2i18n( "&Address:" ) );
00086 labelNetwork->setText( tr2i18n( "&Network:" ) );
00087 }
00088
00089 void IMAddressBase::slotProtocolChanged(const QString&)
00090 {
00091 qWarning( "IMAddressBase::slotProtocolChanged(const QString&): Not implemented yet" );
00092 }
00093
00094 void IMAddressBase::slotProtocolChanged()
00095 {
00096 qWarning( "IMAddressBase::slotProtocolChanged(): Not implemented yet" );
00097 }
00098
00099 #include "imaddressbase.moc"
|