diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 06:08:18 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 06:08:18 +0000 |
commit | 72aaee9802d447ee21340b011856b9b355a58f1a (patch) | |
tree | f97a68e4f75e6c25c8492e03fdfe6983fb0aa199 /src/modules/notifier | |
parent | 5d03948cd3558c613fae1fad109635f860babcbb (diff) | |
download | kvirc-72aaee9802d447ee21340b011856b9b355a58f1a.tar.gz kvirc-72aaee9802d447ee21340b011856b9b355a58f1a.zip |
rename the following methods:
tqfind find
tqreplace replace
tqcontains contains
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kvirc@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'src/modules/notifier')
-rw-r--r-- | src/modules/notifier/notifierwindow.cpp | 42 | ||||
-rw-r--r-- | src/modules/notifier/notifierwindowtabs.cpp | 30 |
2 files changed, 36 insertions, 36 deletions
diff --git a/src/modules/notifier/notifierwindow.cpp b/src/modules/notifier/notifierwindow.cpp index 91583241..e0f080a1 100644 --- a/src/modules/notifier/notifierwindow.cpp +++ b/src/modules/notifier/notifierwindow.cpp @@ -220,7 +220,7 @@ void KviNotifierWindow::addMessage(KviWindow * pWnd,const TQString &szImageId,co { TQPixmap * pIcon; TQString szMessage=szText; - szMessage.tqreplace( TQRegExp("\r([^\r])*\r([^\r])+\r"), "\\2" ); + szMessage.replace( TQRegExp("\r([^\r])*\r([^\r])+\r"), "\\2" ); if(szImageId.isEmpty())pIcon = 0; else pIcon = g_pIconManager->getImage(szImageId); @@ -715,12 +715,12 @@ void KviNotifierWindow::redrawText() KviNotifierMessage * last = l->last(); // make sure that we can loop - int iIdx = l->tqfindRef(cur); + int iIdx = l->findRef(cur); if(iIdx == -1) { tab->setCurrentMessage(last); cur = last; - iIdx = l->tqfindRef(cur); + iIdx = l->findRef(cur); } int y = m_pWndBody->textRect().y() + m_pWndBody->textRect().height(); @@ -786,8 +786,8 @@ void KviNotifierWindow::mouseMoveEvent(TQMouseEvent * e) if(checkResizing(e->pos())) goto sartelo; /* ### MOUSE-MOVE-EVENT -> m_pWndBorder ### */ - if (m_pWndBorder->captionRect().tqcontains(e->pos())) { - if (m_pWndBorder->closeRect().tqcontains(e->pos())) { + if (m_pWndBorder->captionRect().contains(e->pos())) { + if (m_pWndBorder->closeRect().contains(e->pos())) { m_pWndBorder->setCloseIcon(WDG_ICON_OVER); } else { m_pWndBorder->setCloseIcon(WDG_ICON_OUT); @@ -798,14 +798,14 @@ void KviNotifierWindow::mouseMoveEvent(TQMouseEvent * e) if(m_pWndTabs->currentTab()) { /* ### MOUSE-MOVE-EVENT -> m_pWndTabs ### */ - if (m_pWndTabs->rect().tqcontains(e->pos())) { + if (m_pWndTabs->rect().contains(e->pos())) { m_pWndTabs->mouseMoveEvent(e); goto sartelo; } /* ### MOUSE-MOVE-EVENT -> m_pWndBody ### */ - if (m_pWndBody->rect().tqcontains(e->pos())) { - if (m_pWndBody->rctWriteIcon().tqcontains(e->pos())) { + if (m_pWndBody->rect().contains(e->pos())) { + if (m_pWndBody->rctWriteIcon().contains(e->pos())) { m_pWndBody->setWriteIcon(WDG_ICON_ON); } else { m_pWndBody->setWriteIcon(WDG_ICON_OFF); @@ -867,15 +867,15 @@ void KviNotifierWindow::mousePressEvent(TQMouseEvent * e) if(checkResizing(m_pntClick)) goto sartelo; - if(m_pWndTabs->rect().tqcontains(e->pos())) + if(m_pWndTabs->rect().contains(e->pos())) { m_pWndTabs->mousePressEvent(e); goto sartelo; } - if(m_pWndBorder->captionRect().tqcontains(e->pos())) { + if(m_pWndBorder->captionRect().contains(e->pos())) { //debug ("Clicked on m_pWndBorder->rect()"); - if(m_pWndBorder->closeRect().tqcontains(e->pos())) { + if(m_pWndBorder->closeRect().contains(e->pos())) { //debug ("\tClicked on m_pWndBorder->closeRect()"); m_bCloseDown = true; m_pWndBorder->setCloseIcon(WDG_ICON_CLICKED); @@ -892,24 +892,24 @@ void KviNotifierWindow::mousePressEvent(TQMouseEvent * e) //debug ("x,y: %d,%d - width,height: %d,%d", m_pWndBorder->rect().x(),m_pWndBorder->rect().y(),m_pWndBorder->rect().width(),m_pWndBorder->rect().height()); - if (m_pWndBorder->rect().tqcontains(e->pos())) { + if (m_pWndBorder->rect().contains(e->pos())) { if(m_pWndTabs->currentTab()) { //debug ("Clicked on m_pWndBody->textRect()"); - if(m_pWndBody->rctWriteIcon().tqcontains(e->pos())) + if(m_pWndBody->rctWriteIcon().contains(e->pos())) { m_pWndBody->setWriteIcon(WDG_ICON_CLICKED); showLineEdit(!(m_pLineEdit->isVisible())); } - if(m_pWndBody->rctPrevIcon().tqcontains(e->pos()) && m_pWndBody->prevIconState()!=WDG_ICON_OFF) + if(m_pWndBody->rctPrevIcon().contains(e->pos()) && m_pWndBody->prevIconState()!=WDG_ICON_OFF) { m_bPrevDown = true; m_pWndBody->setPrevIcon(WDG_ICON_CLICKED); prevButtonClicked(); } - if(m_pWndBody->rctNextIcon().tqcontains(e->pos()) && m_pWndBody->nextIconState()!=WDG_ICON_OFF) + if(m_pWndBody->rctNextIcon().contains(e->pos()) && m_pWndBody->nextIconState()!=WDG_ICON_OFF) { m_bNextDown = true; m_pWndBody->setNextIcon(WDG_ICON_CLICKED); @@ -947,9 +947,9 @@ void KviNotifierWindow::mouseReleaseEvent(TQMouseEvent * e) return; } - if(m_pWndBorder->captionRect().tqcontains(e->pos())) { + if(m_pWndBorder->captionRect().contains(e->pos())) { - if(m_pWndBorder->closeRect().tqcontains(e->pos())) { + if(m_pWndBorder->closeRect().contains(e->pos())) { //debug ("hide now from release event"); hideNow(); } else { @@ -958,7 +958,7 @@ void KviNotifierWindow::mouseReleaseEvent(TQMouseEvent * e) } - if(m_pWndTabs->rect().tqcontains(e->pos())) + if(m_pWndTabs->rect().contains(e->pos())) { m_pWndTabs->mouseReleaseEvent(e); } @@ -969,7 +969,7 @@ void KviNotifierWindow::mouseReleaseEvent(TQMouseEvent * e) void KviNotifierWindow::mouseDoubleClickEvent(TQMouseEvent * e) { - if(!m_pWndBody->textRect().tqcontains(e->pos())) + if(!m_pWndBody->textRect().contains(e->pos())) { TQWidget::mouseDoubleClickEvent(e); return; @@ -1406,8 +1406,8 @@ void KviNotifierWindow::returnPressed() TQString txt = m_pLineEdit->text(); if(txt.isEmpty())return; TQString html = txt; - html.tqreplace("<","<"); - html.tqreplace(">",">"); + html.replace("<","<"); + html.replace(">",">"); KviStr tmp(KviStr::Format,"%d",KVI_SMALLICON_OWNPRIVMSG); addMessage(tab->window(),tmp.ptr(),html,0); //m_pCurrentFocusedWindowTab on place of m_pCurrentMessage->window() diff --git a/src/modules/notifier/notifierwindowtabs.cpp b/src/modules/notifier/notifierwindowtabs.cpp index 7455049f..9e024d5b 100644 --- a/src/modules/notifier/notifierwindowtabs.cpp +++ b/src/modules/notifier/notifierwindowtabs.cpp @@ -77,7 +77,7 @@ KviNotifierWindowTab::~KviNotifierWindowTab() void KviNotifierWindowTab::setNextMessageAsCurrent() { if(!m_pCurrentMessage)return; - if(m_pMessageList->tqfindRef(m_pCurrentMessage) == -1)return; + if(m_pMessageList->findRef(m_pCurrentMessage) == -1)return; m_pCurrentMessage = m_pMessageList->next(); if(!m_pCurrentMessage)m_pCurrentMessage = m_pMessageList->last(); } @@ -85,7 +85,7 @@ void KviNotifierWindowTab::setNextMessageAsCurrent() void KviNotifierWindowTab::setPrevMessageAsCurrent() { if(!m_pCurrentMessage)return; - if(!m_pMessageList->tqfindRef(m_pCurrentMessage) == -1)return; + if(!m_pMessageList->findRef(m_pCurrentMessage) == -1)return; m_pCurrentMessage = m_pMessageList->prev(); if(!m_pCurrentMessage)m_pCurrentMessage = m_pMessageList->first(); } @@ -285,7 +285,7 @@ void KviNotifierWindowTabs::addMessage(KviWindow * pWnd, KviNotifierMessage * me // e quindi iterando i tab nuovi possono trovarsi PRIMA dei tab vecchi // il che' confonde un po KviNotifierWindowTab * tab; - if (!m_tabMap.tqcontains(pWnd)) { + if (!m_tabMap.contains(pWnd)) { m_tabMap.insert(pWnd, tab = new KviNotifierWindowTab(pWnd, sender)); m_tabPtrList.append(tab); } else { @@ -413,26 +413,26 @@ void KviNotifierWindowTabs::next() void KviNotifierWindowTabs::mousePressEvent(TQMouseEvent * e) { - if (m_bIsOverRightBound && m_rctNextIcon.tqcontains(e->pos())) { + if (m_bIsOverRightBound && m_rctNextIcon.contains(e->pos())) { return; } - if (m_bIsOverLeftBound && m_rctPrevIcon.tqcontains(e->pos())) { + if (m_bIsOverLeftBound && m_rctPrevIcon.contains(e->pos())) { return; } - if(m_rctTabs.tqcontains(e->pos())) + if(m_rctTabs.contains(e->pos())) { TQMap<KviWindow *, KviNotifierWindowTab *>::Iterator tab; for (tab = m_tabMap.begin(); tab != m_tabMap.end(); tab++ ) { - if (tab.data()->rect().tqcontains(e->pos())) { + if (tab.data()->rect().contains(e->pos())) { setFocusOn(tab.data()); return; } } } - if (m_rctCloseTabIconHotArea.tqcontains(e->pos())) { + if (m_rctCloseTabIconHotArea.contains(e->pos())) { setCloseTabIcon(WDG_ICON_CLICKED); return; } @@ -441,7 +441,7 @@ void KviNotifierWindowTabs::mousePressEvent(TQMouseEvent * e) { void KviNotifierWindowTabs::mouseMoveEvent(TQMouseEvent * e) { - if (m_rctCloseTabIconHotArea.tqcontains(e->pos())) + if (m_rctCloseTabIconHotArea.contains(e->pos())) { setCloseTabIcon(WDG_ICON_ON); } else { @@ -453,19 +453,19 @@ void KviNotifierWindowTabs::mouseMoveEvent(TQMouseEvent * e) void KviNotifierWindowTabs::mouseReleaseEvent(TQMouseEvent * e) { - if (m_bIsOverRightBound && m_rctNextIcon.tqcontains(e->pos())) { + if (m_bIsOverRightBound && m_rctNextIcon.contains(e->pos())) { scrollTabsLeft(); return; } - if (m_bIsOverLeftBound && m_rctPrevIcon.tqcontains(e->pos())) { + if (m_bIsOverLeftBound && m_rctPrevIcon.contains(e->pos())) { scrollTabsRight(); return; } if(currentTab()) { - if (rctCloseTabIconHotArea().tqcontains(e->pos())) + if (rctCloseTabIconHotArea().contains(e->pos())) { closeCurrentTab(); g_pNotifierWindow->update(); @@ -555,7 +555,7 @@ void KviNotifierWindowTabs::draw(TQPainter * p) KviPointerListIterator<KviNotifierWindowTab> tabIterator (m_tabPtrList); - //m_tabPtrList.tqfindRef(m_tabMap[m_pTabFocused->wnd()]); + //m_tabPtrList.findRef(m_tabMap[m_pTabFocused->wnd()]); // TQMap<KviWindow *, KviNotifierWindowTab *>::Iterator tab; KviNotifierWindowTab * tab; @@ -654,7 +654,7 @@ void KviNotifierWindowTabs::markAllMessagesAsHistoric() void KviNotifierWindowTabs::closeTab(KviWindow * pWnd) { - KviNotifierWindowTab * pTab = m_tabMap.tqfind(pWnd).data(); + KviNotifierWindowTab * pTab = m_tabMap.find(pWnd).data(); closeTab(pWnd, pTab); } @@ -671,7 +671,7 @@ void KviNotifierWindowTabs::closeCurrentTab() KviNotifierWindowTab * pTab = m_pTabFocused; if (m_tabMap.isEmpty()) return; // Empty??? The World is ending... KviWindow * pWnd = pTab->wnd(); - if (!m_tabMap.tqcontains(pWnd)) return; // The current tab is not on the map??? Call 911!! + if (!m_tabMap.contains(pWnd)) return; // The current tab is not on the map??? Call 911!! // End paranoic stuff, go back to sanity... closeTab(pWnd, pTab); |