diff options
| author | 2008-11-28 15:36:29 +0000 | |
|---|---|---|
| committer | 2008-11-28 15:36:29 +0000 | |
| commit | 20e29c806fd0451e75b773697afe5532fd6865df (patch) | |
| tree | fb5a170434aee11a1f34005f4ceb0721a51c68e4 /src/modules | |
| parent | Installation fixes for MacOS X (diff) | |
| download | KVIrc-20e29c806fd0451e75b773697afe5532fd6865df.tar.gz KVIrc-20e29c806fd0451e75b773697afe5532fd6865df.tar.bz2 KVIrc-20e29c806fd0451e75b773697afe5532fd6865df.zip | |
ported r2927 to trunk/4.0
git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@2928 17fca916-40b9-46aa-a4ea-0a15b648b75c
Diffstat (limited to 'src/modules')
| -rw-r--r-- | src/modules/dcc/chat.cpp | 21 | ||||
| -rw-r--r-- | src/modules/dcc/chat.h | 12 |
2 files changed, 20 insertions, 13 deletions
diff --git a/src/modules/dcc/chat.cpp b/src/modules/dcc/chat.cpp index 230dc6f94..f899b8cd1 100644 --- a/src/modules/dcc/chat.cpp +++ b/src/modules/dcc/chat.cpp @@ -48,7 +48,6 @@ #include "kvi_thread.h" #include "kvi_ircsocket.h" #include "kvi_settings.h" -#include "kvi_themedlabel.h" #include "kvi_socket.h" #include "kvi_app.h" #include "kvi_parameterlist.h" @@ -87,14 +86,18 @@ extern KviDccBroker * g_pDccBroker; KviDccChat::KviDccChat(KviFrame *pFrm,KviDccDescriptor * dcc,const char * name) : KviDccWindow(KVI_WINDOW_TYPE_DCCCHAT,pFrm,name,dcc) { - m_pTopSplitter = new QSplitter(Qt::Horizontal,this); - m_pTopSplitter->setObjectName("top_splitter"); - KviThemedLabel * dummy; - dummy = new KviThemedLabel(m_pTopSplitter,"dummy_label"); - KviTalVBox * box = new KviTalVBox(m_pTopSplitter); + m_pButtonBox = new KviTalHBox(this); + + m_pLabel = new KviThemedLabel(m_pButtonBox,"dcc_chat_label"); + m_pLabel->setAutoHeight(1); + m_pLabel->setText(name); + m_pButtonBox->setStretchFactor(m_pLabel,1); + + m_pButtonContainer= new KviTalHBox(m_pButtonBox); + createTextEncodingButton(m_pButtonContainer); #ifdef COMPILE_CRYPT_SUPPORT - createCryptControllerButton(box); + createCryptControllerButton(m_pButtonContainer); #endif m_pSplitter = new QSplitter(Qt::Horizontal,this); @@ -479,8 +482,8 @@ bool KviDccChat::event(QEvent *e) void KviDccChat::resizeEvent(QResizeEvent *) { int hght = m_pInput->heightHint(); - int hght2 = m_pTopSplitter->sizeHint().height(); - m_pTopSplitter->setGeometry(0,0,width(),hght2); + int hght2 = m_pButtonBox->sizeHint().height(); + m_pButtonBox->setGeometry(0,0,width(),hght2); m_pSplitter->setGeometry(0,hght2,width(),height() - (hght + hght2)); m_pInput->setGeometry(0,height() - hght,width(),hght); } diff --git a/src/modules/dcc/chat.h b/src/modules/dcc/chat.h index 326741d6a..26ca3033a 100644 --- a/src/modules/dcc/chat.h +++ b/src/modules/dcc/chat.h @@ -24,14 +24,15 @@ // //============================================================================= -#include "window.h" #include "descriptor.h" #include "thread.h" +#include "window.h" -#include "kvi_window.h" -#include "kvi_string.h" #include "kvi_databuffer.h" #include "kvi_pointerlist.h" +#include "kvi_themedlabel.h" +#include "kvi_string.h" +#include "kvi_window.h" #ifdef COMPILE_SSL_SUPPORT class KviSSL; @@ -69,11 +70,14 @@ class KviDccChat : public KviDccWindow public: KviDccChat(KviFrame *pFrm,KviDccDescriptor * dcc,const char * name); ~KviDccChat(); + QFrame * buttonContainer() { return (QFrame*)m_pButtonContainer; }; protected: KviDccChatThread * m_pSlaveThread; - QSplitter * m_pTopSplitter; QString m_szTarget; QString m_szLocalNick; + KviThemedLabel * m_pLabel; + KviTalHBox * m_pButtonBox; + KviTalHBox * m_pButtonContainer; protected: virtual const QString & target(); virtual void fillCaptionBuffers(); |
