diff options
| author | 2008-09-24 17:47:32 +0000 | |
|---|---|---|
| committer | 2008-09-24 17:47:32 +0000 | |
| commit | 25e71c7f704c8deef50eedbe773bd3f139edee64 (patch) | |
| tree | b4a70610e0383049b178d268a3bf5159f249008e /src/modules | |
| parent | conditional label (diff) | |
| download | KVIrc-25e71c7f704c8deef50eedbe773bd3f139edee64.tar.gz KVIrc-25e71c7f704c8deef50eedbe773bd3f139edee64.tar.bz2 KVIrc-25e71c7f704c8deef50eedbe773bd3f139edee64.zip | |
removed kvi_tal_listbox; removed qt3 support; now we're pure-qt4, baby (some things still to be ported/fixed)
git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@2553 17fca916-40b9-46aa-a4ea-0a15b648b75c
Diffstat (limited to 'src/modules')
| -rw-r--r-- | src/modules/CMakeLists.txt | 8 | ||||
| -rw-r--r-- | src/modules/editor/scripteditor.cpp | 6 | ||||
| -rw-r--r-- | src/modules/trayicon/libkvitrayicon.cpp | 22 | ||||
| -rw-r--r-- | src/modules/trayicon/libkvitrayicon.h | 4 |
4 files changed, 23 insertions, 17 deletions
diff --git a/src/modules/CMakeLists.txt b/src/modules/CMakeLists.txt index b6f617e87..2e59d9cc6 100644 --- a/src/modules/CMakeLists.txt +++ b/src/modules/CMakeLists.txt @@ -35,8 +35,12 @@ SUBDIRS( raweditor regchan reguser serverdb setup sharedfile sharedfileswindow snd socketspy spaste str system - texticons term theme tip tmphighlight toolbar toolbareditor trayicon - upnp url + texticons term +# theme <- to port + tip tmphighlight toolbar toolbareditor +# trayicon <- to port + upnp + url window # broken modules diff --git a/src/modules/editor/scripteditor.cpp b/src/modules/editor/scripteditor.cpp index 7bfd22b32..367e83719 100644 --- a/src/modules/editor/scripteditor.cpp +++ b/src/modules/editor/scripteditor.cpp @@ -38,13 +38,13 @@ #include "kvi_console.h" #include "kvi_window.h" #include "kvi_iconmanager.h" -#include <kvi_tal_groupbox.h> +#include "kvi_tal_groupbox.h" #include "kvi_tal_scrollview.h" #include "kvi_kvs_kernel.h" #include "kvi_modulemanager.h" #include "kvi_config.h" - #include "kvi_tal_vbox.h" + #include "kvi_tal_hbox.h" #include <QScrollBar> #include <QLayout> @@ -225,7 +225,7 @@ void KviScriptEditorWidget::loadCompleterFromFile() f.open(QIODevice::ReadOnly); szBuffer=f.readAll(); f.close(); - szListFunctionsCommand=QStringList::split(',',szBuffer); + szListFunctionsCommand=szBuffer.split(','); createCompleter(szListFunctionsCommand); } void KviScriptEditorWidget::createCompleter(QStringList &list) diff --git a/src/modules/trayicon/libkvitrayicon.cpp b/src/modules/trayicon/libkvitrayicon.cpp index 44ecce764..7f5696e2b 100644 --- a/src/modules/trayicon/libkvitrayicon.cpp +++ b/src/modules/trayicon/libkvitrayicon.cpp @@ -78,7 +78,8 @@ KviTrayIcon::KviTrayIcon(KviFrame * frm) m_iQueries = 0; m_iOther = 0; - m_pFlashingTimer = new QTimer(this,"flashing_timer"); + m_pFlashingTimer = new QTimer(this); + m_pFlashingTimer->setObjectName("flashing_timer"); connect( m_pFlashingTimer, SIGNAL(timeout()), this, SLOT(flashingTimerShot()) ); m_bFlashed=0; g_pTrayIconList->append(this); @@ -93,8 +94,9 @@ KviTrayIcon::KviTrayIcon(KviFrame * frm) l->setStyleSheet("background-color: " + p.color(QPalette::Normal, QPalette::Mid).name()); m_pContextPopup->insertItem(l); m_pContextPopup->setWindowTitle(__tr2qs("Context")); - m_iAwayMenuId = m_pContextPopup->insertItem ( __tr2qs("Away"), m_pAwayPopup); - m_pContextPopup->changeItem(m_iAwayMenuId,*(g_pIconManager->getSmallIcon(KVI_SMALLICON_AWAY)),__tr2qs("Away")); + m_iAwayMenuId = m_pContextPopup->addMenu(m_pAwayPopup); + m_iAwayMenuId.setIcon(*(g_pIconManager->getSmallIcon(KVI_SMALLICON_AWAY))); + m_iAwayMenuId.setText(__tr2qs("Away")); int id = m_pContextPopup->insertItem(*(g_pIconManager->getSmallIcon(KVI_SMALLICON_OPTIONS)),__tr2qs("&Configure KVIrc..."),m_pFrm,SLOT(executeInternalCommand(int))); m_pContextPopup->setItemParameter(id,KVI_INTERNALCOMMAND_OPTIONS_DIALOG); @@ -251,7 +253,7 @@ void KviTrayIcon::fillContextPopup() m_pContextPopup->changeItem(m_iToggleFrame,m_pFrm->isVisible() ? __tr2qs("Hide Window") : __tr2qs("Show Window")); if(g_pApp->topmostConnectedConsole()) { - m_pContextPopup->setItemVisible(m_iAwayMenuId,true); + m_iAwayMenuId->setVisible(true); m_pAwayPopup->clear(); int iAllAway=m_pAwayPopup->insertItem(*(g_pIconManager->getSmallIcon(KVI_SMALLICON_CONSOLE)),__tr2qs("Away on all"),this,SLOT(doAway(int))); @@ -304,19 +306,19 @@ void KviTrayIcon::fillContextPopup() void KviTrayIcon::toggleParentFrame() { - QWidget *top_widget = m_pFrm->topLevelWidget(); + KviWindow *top_widget = m_pFrm->topLevelWidget(); if(m_pFrm->isVisible()) { m_pFrm->hide(); } else { - top_widget->show(); - top_widget->raise(); - top_widget->setActiveWindow(); - if(g_pActiveWindow) g_pActiveWindow->setFocus(); +/* top_widget->show(); + top_widget->raise();*/ + g_pFrame->setActiveWindow(top_widget); +/* if(g_pActiveWindow) g_pActiveWindow->setFocus(); if(m_pFrm->isMinimized()) m_pFrm->showNormal(); else - m_pFrm->show(); + m_pFrm->show();*/ // m_pFrm->setWindowState(getPrevWindowState() & Qt::WindowMinimized); } } diff --git a/src/modules/trayicon/libkvitrayicon.h b/src/modules/trayicon/libkvitrayicon.h index b75eb632c..04ee1b822 100644 --- a/src/modules/trayicon/libkvitrayicon.h +++ b/src/modules/trayicon/libkvitrayicon.h @@ -50,10 +50,10 @@ protected: KviTalPopupMenu * m_pAwayPopup; int m_iToggleFrame; - int m_iAwayMenuId; + QAction* m_pAwayMenuId; bool m_bFlashed; - + QPixmap m_CurrentPixmap; QTimer* m_pFlashingTimer; int m_iConsoles; |
