Source Code (Use browser search to find items of interest.)

Class Index

empath'EmpathAddressHeaderBodyWidget (./kdepim/empath/parts/libEmpathComposeWidget/EmpathHeaderBodyWidget.h:88)

class EmpathAddressHeaderBodyWidget : public EmpathHeaderBodyWidget
{
    Q_OBJECT
    
    public:
    
        EmpathAddressHeaderBodyWidget(QWidget * parent = 0)
            :   EmpathHeaderBodyWidget(parent)
        {
            le_address_ = new KLineEdit(this, "le_address");

            QPushButton * pb_browse_ = new QPushButton(this, "pb_browse");

            pb_browse_->setPixmap(BarIcon("pointingHand")), 
            pb_browse_->setFixedWidth(pb_browse_->sizeHint().width());

            QHBoxLayout * layout = new QHBoxLayout(this);

            layout->addWidget(le_address_);
            layout->addWidget(pb_browse_);

            QObject::connect(
                pb_browse_, SIGNAL(clicked()),
                this,       SLOT(s_browseClicked())
            );

            setFocusProxy(le_address_);
        }

        virtual ~EmpathAddressHeaderBodyWidget()
        {
            // Empty.
        }

        QString text() const
        {
            return le_address_->text();
        }

        void setText(const QString & s)
        {
            le_address_->setText(s);
        }

        KLineEdit * lineEdit() { return le_address_; };
        
    protected slots:

        void s_browseClicked()
        {
            QMessageBox::information(
                this,
                "Empath",
                i18n("Sorry, the addressbook isn't ready for use yet."),
                i18n("OK")
            );
        }

    private:

        KLineEdit   * le_address_;
};



#endif

// vim:ts=4:sw=4:tw=78