diff options
Diffstat (limited to 'klinkstatus/src/ui')
-rw-r--r-- | klinkstatus/src/ui/documentrootdialog.cpp | 2 | ||||
-rw-r--r-- | klinkstatus/src/ui/resultssearchbar.cpp | 34 | ||||
-rw-r--r-- | klinkstatus/src/ui/resultssearchbar.h | 4 | ||||
-rw-r--r-- | klinkstatus/src/ui/resultview.cpp | 42 | ||||
-rw-r--r-- | klinkstatus/src/ui/resultview.h | 16 | ||||
-rw-r--r-- | klinkstatus/src/ui/sessionwidget.cpp | 22 | ||||
-rw-r--r-- | klinkstatus/src/ui/sessionwidget.h | 6 | ||||
-rw-r--r-- | klinkstatus/src/ui/sessionwidgetbase.ui | 44 | ||||
-rw-r--r-- | klinkstatus/src/ui/settings/configidentificationdialogui.ui | 2 | ||||
-rw-r--r-- | klinkstatus/src/ui/settings/configsearchdialog.ui | 8 | ||||
-rw-r--r-- | klinkstatus/src/ui/tablelinkstatus.cpp | 158 | ||||
-rw-r--r-- | klinkstatus/src/ui/tablelinkstatus.h | 30 | ||||
-rw-r--r-- | klinkstatus/src/ui/tabwidgetsession.cpp | 6 | ||||
-rw-r--r-- | klinkstatus/src/ui/tabwidgetsession.h | 4 | ||||
-rw-r--r-- | klinkstatus/src/ui/treeview.cpp | 108 | ||||
-rw-r--r-- | klinkstatus/src/ui/treeview.h | 16 |
16 files changed, 251 insertions, 251 deletions
diff --git a/klinkstatus/src/ui/documentrootdialog.cpp b/klinkstatus/src/ui/documentrootdialog.cpp index b1563285..9a813211 100644 --- a/klinkstatus/src/ui/documentrootdialog.cpp +++ b/klinkstatus/src/ui/documentrootdialog.cpp @@ -24,7 +24,7 @@ #include <kurl.h> #include <tqstring.h> -#include <tqlayout.h> +#include <layout.h> #include <tqlabel.h> diff --git a/klinkstatus/src/ui/resultssearchbar.cpp b/klinkstatus/src/ui/resultssearchbar.cpp index b19f7764..3318132c 100644 --- a/klinkstatus/src/ui/resultssearchbar.cpp +++ b/klinkstatus/src/ui/resultssearchbar.cpp @@ -35,19 +35,19 @@ #include <tqtimer.h> #include <tqtoolbutton.h> #include <tqtooltip.h> -#include <tqlayout.h> +#include <layout.h> class ResultsSearchBar::ResultsSearchBarPrivate { public: ResultsSearchBarPrivate() - : tqlayout(0), searchLine(0), searchCombo(0), delay(400), m_lastComboIndex(0) + : layout(0), searchLine(0), searchCombo(0), delay(400), m_lastComboIndex(0) {} TQString searchText; TQTimer timer; - TQHBoxLayout* tqlayout; + TQHBoxLayout* layout; KLineEdit* searchLine; KComboBox* searchCombo; int delay; @@ -57,31 +57,31 @@ public: ResultsSearchBar::ResultsSearchBar(TQWidget* parent, const char* name) : TQWidget(parent, name), d(new ResultsSearchBar::ResultsSearchBarPrivate) { - tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed)); + setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed)); - d->tqlayout = new TQHBoxLayout(this); - d->tqlayout->setMargin(2); - d->tqlayout->setSpacing(5); + d->layout = new TQHBoxLayout(this); + d->layout->setMargin(2); + d->layout->setSpacing(5); TQToolButton* clearButton = new TQToolButton(this); clearButton->setIconSet(SmallIconSet(TQApplication::reverseLayout() ? "clear_left" : "locationbar_erase")); clearButton->setAutoRaise(true); - d->tqlayout->addWidget(clearButton); + d->layout->addWidget(clearButton); TQLabel* searchLabel = new TQLabel(this); searchLabel->setText(i18n("S&earch:")); - d->tqlayout->addWidget(searchLabel); + d->layout->addWidget(searchLabel); d->searchLine = new KLineEdit(this, "searchline"); connect(d->searchLine, TQT_SIGNAL(textChanged(const TQString &)), this, TQT_SLOT(slotSearchStringChanged(const TQString &))); searchLabel->setBuddy(d->searchLine); - d->tqlayout->addWidget(d->searchLine); + d->layout->addWidget(d->searchLine); TQLabel* statusLabel = new TQLabel(this); statusLabel->setText( i18n("Status:") ); - d->tqlayout->addWidget(statusLabel); + d->layout->addWidget(statusLabel); d->searchCombo = new KComboBox(this, "searchcombo"); TQPixmap iconAll = KGlobal::iconLoader()->loadIcon("exec", KIcon::Small); @@ -95,7 +95,7 @@ ResultsSearchBar::ResultsSearchBar(TQWidget* parent, const char* name) d->searchCombo->insertItem(iconBroken, i18n("Broken Links")); d->searchCombo->insertItem(iconMalformed, i18n("Malformed Links")); d->searchCombo->insertItem(iconUndetermined, i18n("Undetermined Links")); - d->tqlayout->addWidget(d->searchCombo); + d->layout->addWidget(d->searchCombo); TQToolTip::add(clearButton, i18n("Clear filter")); TQToolTip::add( d->searchLine, i18n("Enter the terms to filter the result link list")); @@ -147,7 +147,7 @@ void ResultsSearchBar::slotClearSearch() } } -void ResultsSearchBar::slotSettqStatus(int status) +void ResultsSearchBar::slotSetStatus(int status) { d->searchCombo->setCurrentItem(status); } @@ -187,19 +187,19 @@ void ResultsSearchBar::slotActivateSearch() { kdDebug(23100) << "ResultsSearchBar::slotActivateSearch" << endl; - ResultView::tqStatus status = selectedtqStatus(); + ResultView::Status status = selectedStatus(); emit signalSearch(LinkMatcher(d->searchLine->text(), status)); } LinkMatcher ResultsSearchBar::currentLinkMatcher() const { - return LinkMatcher(d->searchLine->text(), selectedtqStatus()); + return LinkMatcher(d->searchLine->text(), selectedStatus()); } -ResultView::tqStatus ResultsSearchBar::selectedtqStatus() const +ResultView::Status ResultsSearchBar::selectedStatus() const { - ResultView::tqStatus status = ResultView::none; + ResultView::Status status = ResultView::none; if(d->searchCombo->currentItem()) { diff --git a/klinkstatus/src/ui/resultssearchbar.h b/klinkstatus/src/ui/resultssearchbar.h index c99b1da1..1c161e99 100644 --- a/klinkstatus/src/ui/resultssearchbar.h +++ b/klinkstatus/src/ui/resultssearchbar.h @@ -52,7 +52,7 @@ signals: public slots: void slotClearSearch(); - void slotSettqStatus(int status); + void slotSetStatus(int status); void slotSetText(const TQString& text); private slots: @@ -63,7 +63,7 @@ private slots: private: - ResultView::tqStatus selectedtqStatus() const; + ResultView::Status selectedStatus() const; private: diff --git a/klinkstatus/src/ui/resultview.cpp b/klinkstatus/src/ui/resultview.cpp index 507d06e3..fdf65099 100644 --- a/klinkstatus/src/ui/resultview.cpp +++ b/klinkstatus/src/ui/resultview.cpp @@ -69,31 +69,31 @@ void ResultView::setColumns(TQStringList const& columns) number_of_columns_ = columns.size(); } -bool ResultView::displayableWithtqStatus(LinktqStatus const* ls, tqStatus const& status) +bool ResultView::displayableWithStatus(LinkStatus const* ls, Status const& status) { if(status == ResultView::good) { return - ls->status() == LinktqStatus::SUCCESSFULL || - ls->status() == LinktqStatus::HTTP_REDIRECTION; + ls->status() == LinkStatus::SUCCESSFULL || + ls->status() == LinkStatus::HTTP_REDIRECTION; } else if(status == ResultView::bad) { return - ls->status() == LinktqStatus::BROKEN || - ls->status() == LinktqStatus::HTTP_CLIENT_ERROR || - ls->status() == LinktqStatus::HTTP_SERVER_ERROR; + ls->status() == LinkStatus::BROKEN || + ls->status() == LinkStatus::HTTP_CLIENT_ERROR || + ls->status() == LinkStatus::HTTP_SERVER_ERROR; } else if(status == ResultView::malformed) { - return ls->status() == LinktqStatus::MALFORMED; + return ls->status() == LinkStatus::MALFORMED; } else if(status == ResultView::undetermined) { return - ls->status() == LinktqStatus::UNDETERMINED || - ls->status() == LinktqStatus::TIMEOUT || - ls->status() == LinktqStatus::NOT_SUPPORTED; + ls->status() == LinkStatus::UNDETERMINED || + ls->status() == LinkStatus::TIMEOUT || + ls->status() == LinkStatus::NOT_SUPPORTED; } else return true; @@ -102,8 +102,8 @@ bool ResultView::displayableWithtqStatus(LinktqStatus const* ls, tqStatus const& // ******************************* ResultViewItem ***************************** -ResultViewItem::ResultViewItem(LinktqStatus const* linkstatus, int column_index) - : ls_((LinktqStatus*)linkstatus), column_index_(column_index) +ResultViewItem::ResultViewItem(LinkStatus const* linkstatus, int column_index) + : ls_((LinkStatus*)linkstatus), column_index_(column_index) { Q_ASSERT(ls_); Q_ASSERT(column_index_ > 0); @@ -123,7 +123,7 @@ int ResultViewItem::columnIndex() const return column_index_; } -LinktqStatus const* ResultViewItem::linktqStatus() const +LinkStatus const* ResultViewItem::linkStatus() const { Q_ASSERT(ls_); return ls_; @@ -131,30 +131,30 @@ LinktqStatus const* ResultViewItem::linktqStatus() const TQColor const& ResultViewItem::textStatusColor() const { - if(linktqStatus()->errorOccurred()) + if(linkStatus()->errorOccurred()) { - //kdDebug(23100) << "ERROR: " << linkStatus()->error() << ": " << linktqStatus()->absoluteUrl().prettyURL() << endl; - if(linktqStatus()->error() == i18n( "Javascript not supported" )) + //kdDebug(23100) << "ERROR: " << linkStatus()->error() << ": " << linkStatus()->absoluteUrl().prettyURL() << endl; + if(linkStatus()->error() == i18n( "Javascript not supported" )) return TQt::lightGray; else return TQt::red; } - else if(linktqStatus()->absoluteUrl().hasRef()) + else if(linkStatus()->absoluteUrl().hasRef()) return TQt::blue; - else if(!linktqStatus()->absoluteUrl().protocol().startsWith("http")) + else if(!linkStatus()->absoluteUrl().protocol().startsWith("http")) return TQt::darkGreen; else { - TQString status_code(TQString::number(linktqStatus()->httpHeader().statusCode())); + TQString status_code(TQString::number(linkStatus()->httpHeader().statusCode())); if(status_code[0] == '0') { kdWarning(23100) << "status code == 0: " << endl; - kdWarning(23100) << linktqStatus()->toString() << endl; - kdWarning(23100) << linktqStatus()->httpHeader().toString() << endl; + kdWarning(23100) << linkStatus()->toString() << endl; + kdWarning(23100) << linkStatus()->httpHeader().toString() << endl; } //Q_ASSERT(status_code[0] != '0'); diff --git a/klinkstatus/src/ui/resultview.h b/klinkstatus/src/ui/resultview.h index 842ed68b..44e90390 100644 --- a/klinkstatus/src/ui/resultview.h +++ b/klinkstatus/src/ui/resultview.h @@ -27,7 +27,7 @@ class KURL; -class LinktqStatus; +class LinkStatus; class CellToolTip; @@ -43,7 +43,7 @@ public: static const TQString MARKUP_LABEL; static const TQString LINK_LABEL_LABEL; - enum tqStatus { + enum Status { none = 0, good, bad, @@ -54,14 +54,14 @@ public: ResultView(); virtual ~ResultView(); - //virtual void insertResult(LinktqStatus const* linkstatus) = 0; + //virtual void insertResult(LinkStatus const* linkstatus) = 0; virtual void clear() = 0; - virtual void show(tqStatus const& status) = 0; + virtual void show(Status const& status) = 0; virtual void showAll() = 0; //virtual void ensureCellVisible(int row, int col) = 0; virtual void setColumns(TQStringList const& columns); - static bool displayableWithtqStatus(LinktqStatus const* ls, tqStatus const& status); + static bool displayableWithStatus(LinkStatus const* ls, Status const& status); int numberOfColumns() const { return number_of_columns_; } @@ -105,7 +105,7 @@ private: class ResultViewItem { public: - ResultViewItem(LinktqStatus const* linkstatus, + ResultViewItem(LinkStatus const* linkstatus, int column_index); virtual ~ResultViewItem(); @@ -113,7 +113,7 @@ public: virtual int columnIndex() const; virtual TQString toolTip() const = 0; - LinktqStatus const* linktqStatus() const; + LinkStatus const* linkStatus() const; protected: @@ -125,7 +125,7 @@ protected: protected: - LinktqStatus* ls_; + LinkStatus* ls_; int column_index_; int alignment_; }; diff --git a/klinkstatus/src/ui/sessionwidget.cpp b/klinkstatus/src/ui/sessionwidget.cpp index 87831ffc..15f7d631 100644 --- a/klinkstatus/src/ui/sessionwidget.cpp +++ b/klinkstatus/src/ui/sessionwidget.cpp @@ -40,7 +40,7 @@ #include <tqspinbox.h> #include <tqcheckbox.h> #include <tqpushbutton.h> -#include <tqlayout.h> +#include <layout.h> #include <tqlabel.h> #include <tqlistbox.h> #include <tqstringlist.h> @@ -154,10 +154,10 @@ void SessionWidget::newSearchManager() TQT_TQOBJECT(this), "search_manager"); Q_ASSERT(search_manager_); - connect(search_manager_, TQT_SIGNAL(signalRootChecked(const LinktqStatus *, LinkChecker *)), - this, TQT_SLOT(slotRootChecked(const LinktqStatus *, LinkChecker *))); - connect(search_manager_, TQT_SIGNAL(signalLinkChecked(const LinktqStatus *, LinkChecker *)), - this, TQT_SLOT(slotLinkChecked(const LinktqStatus *, LinkChecker *))); + connect(search_manager_, TQT_SIGNAL(signalRootChecked(const LinkStatus *, LinkChecker *)), + this, TQT_SLOT(slotRootChecked(const LinkStatus *, LinkChecker *))); + connect(search_manager_, TQT_SIGNAL(signalLinkChecked(const LinkStatus *, LinkChecker *)), + this, TQT_SLOT(slotLinkChecked(const LinkStatus *, LinkChecker *))); connect(search_manager_, TQT_SIGNAL(signalSearchFinished()), this, TQT_SLOT(slotSearchFinished())); connect(search_manager_, TQT_SIGNAL(signalSearchPaused()), @@ -356,7 +356,7 @@ bool SessionWidget::validFields() return true; } -void SessionWidget::slotRootChecked(LinktqStatus const* linkstatus, LinkChecker * anal) +void SessionWidget::slotRootChecked(LinkStatus const* linkstatus, LinkChecker * anal) { slotSetTimeElapsed(); emit signalUpdateTabLabel(search_manager_->linkStatusRoot(), this); @@ -368,7 +368,7 @@ void SessionWidget::slotRootChecked(LinktqStatus const* linkstatus, LinkChecker //table_linkstatus->insertResult(linkstatus); TreeViewItem* tree_view_item = new TreeViewItem(tree_view, tree_view->lastItem(), linkstatus); - LinktqStatus* ls = const_cast<LinktqStatus*> (linkstatus); + LinkStatus* ls = const_cast<LinkStatus*> (linkstatus); ls->setTreeViewItem(tree_view_item); if(linkstatus->isRedirection() && linkstatus->redirection()) @@ -378,7 +378,7 @@ void SessionWidget::slotRootChecked(LinktqStatus const* linkstatus, LinkChecker ActionManager::getInstance()->action("file_export_html")->setEnabled(!isEmpty()); } -void SessionWidget::slotLinkChecked(LinktqStatus const* linkstatus, LinkChecker * anal) +void SessionWidget::slotLinkChecked(LinkStatus const* linkstatus, LinkChecker * anal) { slotSetTimeElapsed(); @@ -416,7 +416,7 @@ void SessionWidget::slotLinkChecked(LinktqStatus const* linkstatus, LinkChecker tree_view_item->setVisible(match); } - LinktqStatus* ls = const_cast<LinktqStatus*> (linkstatus); + LinkStatus* ls = const_cast<LinkStatus*> (linkstatus); ls->setTreeViewItem(tree_view_item); if(linkstatus->isRedirection() && linkstatus->redirection()) @@ -503,10 +503,10 @@ void SessionWidget::showBottomStatusLabel(TQListViewItem* item) TreeViewItem* _item = tree_view->myItem(item); if(_item) { - TQString status = _item->linktqStatus()->statusText(); + TQString status = _item->linkStatus()->statusText(); textlabel_status->setText(status); - if(textlabel_status->tqsizeHint().width() > textlabel_status->maximumWidth()) + if(textlabel_status->sizeHint().width() > textlabel_status->maximumWidth()) TQToolTip::add(textlabel_status, status); else TQToolTip::remove(textlabel_status); diff --git a/klinkstatus/src/ui/sessionwidget.h b/klinkstatus/src/ui/sessionwidget.h index d171cc37..1c288632 100644 --- a/klinkstatus/src/ui/sessionwidget.h +++ b/klinkstatus/src/ui/sessionwidget.h @@ -70,7 +70,7 @@ public: bool stopped() const { return stopped_; } signals: - void signalUpdateTabLabel(const LinktqStatus *, SessionWidget*); + void signalUpdateTabLabel(const LinkStatus *, SessionWidget*); void signalSearchStarted(); void signalSearchPaused(); void signalSearchFinnished(); @@ -97,8 +97,8 @@ private slots: //virtual void slotSuggestDomain(bool toogle); void slotEnableCheckButton(const TQString &); - void slotRootChecked(LinktqStatus const* linkstatus, LinkChecker * anal); - void slotLinkChecked(LinktqStatus const* linkstatus, LinkChecker * anal); + void slotRootChecked(LinkStatus const* linkstatus, LinkChecker * anal); + void slotLinkChecked(LinkStatus const* linkstatus, LinkChecker * anal); void slotSearchFinished(); void slotSearchPaused(); /** Shows the status of the clicked URL (row) for 5 seconds */ diff --git a/klinkstatus/src/ui/sessionwidgetbase.ui b/klinkstatus/src/ui/sessionwidgetbase.ui index 43d6029e..53cdd510 100644 --- a/klinkstatus/src/ui/sessionwidgetbase.ui +++ b/klinkstatus/src/ui/sessionwidgetbase.ui @@ -12,7 +12,7 @@ <height>683</height> </rect> </property> - <property name="tqminimumSize"> + <property name="minimumSize"> <size> <width>0</width> <height>300</height> @@ -41,7 +41,7 @@ </property> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout15</cstring> + <cstring>layout15</cstring> </property> <hbox> <property name="name"> @@ -49,7 +49,7 @@ </property> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout14</cstring> + <cstring>layout14</cstring> </property> <vbox> <property name="name"> @@ -57,7 +57,7 @@ </property> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout13</cstring> + <cstring>layout13</cstring> </property> <hbox> <property name="name"> @@ -75,13 +75,13 @@ <verstretch>0</verstretch> </sizepolicy> </property> - <property name="tqminimumSize"> + <property name="minimumSize"> <size> <width>25</width> <height>25</height> </size> </property> - <property name="tqmaximumSize"> + <property name="maximumSize"> <size> <width>25</width> <height>25</height> @@ -109,7 +109,7 @@ <property name="text"> <string>URL: </string> </property> - <property name="tqalignment"> + <property name="alignment"> <set>AlignVCenter|AlignLeft</set> </property> </widget> @@ -150,7 +150,7 @@ <property name="sizeType"> <enum>Maximum</enum> </property> - <property name="tqsizeHint"> + <property name="sizeHint"> <size> <width>16</width> <height>20</height> @@ -161,7 +161,7 @@ </widget> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout10</cstring> + <cstring>layout10</cstring> </property> <hbox> <property name="name"> @@ -225,7 +225,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="tqsizeHint"> + <property name="sizeHint"> <size> <width>160</width> <height>20</height> @@ -236,7 +236,7 @@ </widget> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout11</cstring> + <cstring>layout11</cstring> </property> <hbox> <property name="name"> @@ -266,7 +266,7 @@ <property name="sizeType"> <enum>MinimumExpanding</enum> </property> - <property name="tqsizeHint"> + <property name="sizeHint"> <size> <width>174</width> <height>20</height> @@ -277,7 +277,7 @@ </widget> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout11</cstring> + <cstring>layout11</cstring> </property> <hbox> <property name="name"> @@ -306,7 +306,7 @@ <property name="sizeType"> <enum>Maximum</enum> </property> - <property name="tqsizeHint"> + <property name="sizeHint"> <size> <width>16</width> <height>20</height> @@ -338,7 +338,7 @@ <property name="name"> <cstring>tree_view</cstring> </property> - <property name="tqminimumSize"> + <property name="minimumSize"> <size> <width>0</width> <height>300</height> @@ -347,7 +347,7 @@ </widget> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout10</cstring> + <cstring>layout10</cstring> </property> <hbox> <property name="name"> @@ -357,7 +357,7 @@ <property name="name"> <cstring>textlabel_progressbar</cstring> </property> - <property name="tqminimumSize"> + <property name="minimumSize"> <size> <width>94</width> <height>0</height> @@ -385,7 +385,7 @@ </widget> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout11</cstring> + <cstring>layout11</cstring> </property> <hbox> <property name="name"> @@ -403,7 +403,7 @@ <verstretch>0</verstretch> </sizepolicy> </property> - <property name="tqmaximumSize"> + <property name="maximumSize"> <size> <width>470</width> <height>32767</height> @@ -423,7 +423,7 @@ <property name="sizeType"> <enum>Preferred</enum> </property> - <property name="tqsizeHint"> + <property name="sizeHint"> <size> <width>30</width> <height>20</height> @@ -432,7 +432,7 @@ </spacer> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout12_2</cstring> + <cstring>layout12_2</cstring> </property> <grid> <property name="name"> @@ -475,7 +475,7 @@ <verstretch>0</verstretch> </sizepolicy> </property> - <property name="tqminimumSize"> + <property name="minimumSize"> <size> <width>80</width> <height>0</height> diff --git a/klinkstatus/src/ui/settings/configidentificationdialogui.ui b/klinkstatus/src/ui/settings/configidentificationdialogui.ui index 8fa3e5d7..87b73fbf 100644 --- a/klinkstatus/src/ui/settings/configidentificationdialogui.ui +++ b/klinkstatus/src/ui/settings/configidentificationdialogui.ui @@ -69,7 +69,7 @@ <verstretch>0</verstretch> </sizepolicy> </property> - <property name="tqminimumSize"> + <property name="minimumSize"> <size> <width>300</width> <height>0</height> diff --git a/klinkstatus/src/ui/settings/configsearchdialog.ui b/klinkstatus/src/ui/settings/configsearchdialog.ui index 62553ffb..72c420ca 100644 --- a/klinkstatus/src/ui/settings/configsearchdialog.ui +++ b/klinkstatus/src/ui/settings/configsearchdialog.ui @@ -39,7 +39,7 @@ <verstretch>0</verstretch> </sizepolicy> </property> - <property name="tqminimumSize"> + <property name="minimumSize"> <size> <width>0</width> <height>0</height> @@ -184,7 +184,7 @@ </widget> <widget class="TQLayoutWidget" row="1" column="0" rowspan="1" colspan="2"> <property name="name"> - <cstring>tqlayout21</cstring> + <cstring>layout21</cstring> </property> <hbox> <property name="name"> @@ -211,7 +211,7 @@ <property name="sizeType"> <enum>Maximum</enum> </property> - <property name="tqsizeHint"> + <property name="sizeHint"> <size> <width>40</width> <height>20</height> @@ -220,7 +220,7 @@ </spacer> <widget class="TQLayoutWidget"> <property name="name"> - <cstring>tqlayout20</cstring> + <cstring>layout20</cstring> </property> <hbox> <property name="name"> diff --git a/klinkstatus/src/ui/tablelinkstatus.cpp b/klinkstatus/src/ui/tablelinkstatus.cpp index 6aef2c97..dd72dd9f 100644 --- a/klinkstatus/src/ui/tablelinkstatus.cpp +++ b/klinkstatus/src/ui/tablelinkstatus.cpp @@ -26,7 +26,7 @@ #include <tqmemarray.h> #include <tqtooltip.h> #include <tqpixmap.h> -#include <tqclipboard.h> +#include <clipboard.h> #include <tqpainter.h> #include <tqprocess.h> @@ -106,17 +106,17 @@ void TableLinkstatus::setColumns(TQStringList const& columns) horizontal_header->adjustHeaderSize(); } -void TableLinkstatus::insertResult(LinktqStatus const* linkstatus) +void TableLinkstatus::insertResult(LinkStatus const* linkstatus) { insereLinha(generateRowOfTableItems(linkstatus)); } -vector<TableItem*> TableLinkstatus::generateRowOfTableItems(LinktqStatus const* linkstatus) +vector<TableItem*> TableLinkstatus::generateRowOfTableItems(LinkStatus const* linkstatus) { vector<TableItem*> items; int column = 1; - TableItem* item1 = new TableItemtqStatus(this, TQTableItem::Never, + TableItem* item1 = new TableItemStatus(this, TQTableItem::Never, linkstatus, column++); TableItem* item2 = new TableItemNome(this, TQTableItem::Never, linkstatus, column++); @@ -147,10 +147,10 @@ void TableLinkstatus::insereLinha(vector<TableItem*> items) setItem(row, col, items[i]); } - if(items[col_url_ - 1]->tqsizeHint().width() > columnWidth(col_url_ - 1)) + if(items[col_url_ - 1]->sizeHint().width() > columnWidth(col_url_ - 1)) { setColumnStretchable(col_url_ - 1, false); - setColumnWidth(col_url_ - 1, items[col_url_ - 1]->tqsizeHint().width()); + setColumnWidth(col_url_ - 1, items[col_url_ - 1]->sizeHint().width()); } ensureCellVisible(row, 0); @@ -178,14 +178,14 @@ void TableLinkstatus::removeColunas() Q_ASSERT(numCols() == 0); } -void TableLinkstatus::show(ResultView::tqStatus const& status) +void TableLinkstatus::show(ResultView::Status const& status) { for(int i = 0; i != numRows(); ++i) { int row = i; TableItem* _item = myItem(row, col_status_); - if(!ResultView::displayableWithtqStatus(_item->linktqStatus(), status)) + if(!ResultView::displayableWithStatus(_item->linkStatus(), status)) hideRow(row); else showRow(row); @@ -230,7 +230,7 @@ bool TableLinkstatus::textFitsInCell(int row, int col) const TQTableItem* itm(myItem(row, col)); Q_ASSERT(itm); - TQSize size_hint(itm->tqsizeHint()); + TQSize size_hint(itm->sizeHint()); int visible_width = 0; if(col == numCols() - 1) @@ -261,8 +261,8 @@ void TableLinkstatus::slotPopupContextMenu(int r, int w, const TQPoint& pos) TableItem* table_item = myItem(r, w); if(table_item) { - TQValueVector<KURL> referrers = table_item->linktqStatus()->referrers(); - loadContextTableMenu(referrers, table_item->linktqStatus()->isRoot()); + TQValueVector<KURL> referrers = table_item->linkStatus()->referrers(); + loadContextTableMenu(referrers, table_item->linkStatus()->isRoot()); context_table_menu_.popup(pos); } } @@ -313,7 +313,7 @@ void TableLinkstatus::loadContextTableMenu(TQValueVector<KURL> const& referrers, void TableLinkstatus::slotCopyUrlToClipboard() const { TableItem* _item = myItem(currentRow(), currentColumn()); - TQString content(_item->linktqStatus()->absoluteUrl().prettyURL()); + TQString content(_item->linkStatus()->absoluteUrl().prettyURL()); TQClipboard* cb = kapp->clipboard(); cb->setText(content); } @@ -321,7 +321,7 @@ void TableLinkstatus::slotCopyUrlToClipboard() const void TableLinkstatus::slotCopyParentUrlToClipboard() const { TableItem* _item = myItem(currentRow(), currentColumn()); - TQString content(_item->linktqStatus()->parent()->absoluteUrl().prettyURL()); + TQString content(_item->linkStatus()->parent()->absoluteUrl().prettyURL()); TQClipboard* cb = kapp->clipboard(); cb->setText(content); } @@ -336,7 +336,7 @@ void TableLinkstatus::slotCopyCellTextToClipboard() const void TableLinkstatus::slotEditReferrersWithQuanta() { TableItem* _item = myItem(currentRow(), currentColumn()); - TQValueVector<KURL> referrers = _item->linktqStatus()->referrers(); + TQValueVector<KURL> referrers = _item->linkStatus()->referrers(); if(Global::isQuantaAvailableViaDCOP()) { @@ -369,7 +369,7 @@ void TableLinkstatus::slotEditReferrerWithQuanta(int id) index -= 2; // The list of referrers starts on index = 2 TableItem* _item = myItem(currentRow(), currentColumn()); - TQValueVector<KURL> referrers = _item->linktqStatus()->referrers(); + TQValueVector<KURL> referrers = _item->linkStatus()->referrers(); Q_ASSERT(index >= 0 && (uint)index < referrers.size()); slotEditReferrerWithQuanta(referrers[index]); @@ -386,7 +386,7 @@ void TableLinkstatus::slotEditReferrerWithQuanta(KURL const& url) if(!success) { - TQString message = i18n("<qt>File <b>%1</b> cannot be opened. Might be a DCOP problem.</qt>").tqarg(filePath); + TQString message = i18n("<qt>File <b>%1</b> cannot be opened. Might be a DCOP problem.</qt>").arg(filePath); KMessageBox::error(parentWidget(), message); } } @@ -400,7 +400,7 @@ void TableLinkstatus::slotEditReferrerWithQuanta(KURL const& url) void TableLinkstatus::slotViewUrlInBrowser() { TableItem* _item = myItem(currentRow(), currentColumn()); - KURL url = _item->linktqStatus()->absoluteUrl(); + KURL url = _item->linkStatus()->absoluteUrl(); if(url.isValid()) { @@ -414,13 +414,13 @@ void TableLinkstatus::slotViewParentUrlInBrowser() { TableItem* _item = myItem(currentRow(), currentColumn()); - if(_item->linktqStatus()->isRoot()) + if(_item->linkStatus()->isRoot()) { KMessageBox::sorry(this, i18n("ROOT URL.")); } else { - LinktqStatus const* ls_parent = _item->linktqStatus()->parent(); + LinkStatus const* ls_parent = _item->linkStatus()->parent(); Q_ASSERT(ls_parent); KURL url = ls_parent->absoluteUrl(); @@ -439,11 +439,11 @@ void TableLinkstatus::slotViewParentUrlInBrowser() */ TableItem::TableItem(TQTable* table, EditType et, - LinktqStatus const* linkstatus, - int column_index, int tqalignment) + LinkStatus const* linkstatus, + int column_index, int alignment) : TQTableItem(table, et, ""), ResultViewItem(linkstatus, column_index), - /*ls_((LinktqStatus*)linkstatus), - column_index_(column_index),*/ alignment_(tqalignment) + /*ls_((LinkStatus*)linkstatus), + column_index_(column_index),*/ alignment_(alignment) { //Q_ASSERT(ls_); //Q_ASSERT(column_index_ > 0); @@ -467,17 +467,17 @@ int TableItem::columnIndex() const return ResultViewItem::columnIndex(); } -void TableItem::tqsetAlignment(int aFlags) +void TableItem::setAlignment(int aFlags) { alignment_ = aFlags; } -int TableItem::tqalignment() const +int TableItem::alignment() const { return alignment_; } /* -LinktqStatus const* const TableItem::linktqStatus() const +LinkStatus const* const TableItem::linkStatus() const { Q_ASSERT(ls_); return ls_; @@ -485,31 +485,31 @@ LinktqStatus const* const TableItem::linktqStatus() const TQColor const& TableItem::textStatusColor() const { - if(linktqStatus()->errorOccurred()) + if(linkStatus()->errorOccurred()) { - //kdDebug(23100) << "ERROR: " << linkStatus()->error() << ": " << linktqStatus()->absoluteUrl().prettyURL() << endl; - if(linktqStatus()->error() == i18n( "Javascript not supported" )) + //kdDebug(23100) << "ERROR: " << linkStatus()->error() << ": " << linkStatus()->absoluteUrl().prettyURL() << endl; + if(linkStatus()->error() == i18n( "Javascript not supported" )) return TQt::lightGray; else return TQt::red; } - else if(linktqStatus()->absoluteUrl().hasRef()) + else if(linkStatus()->absoluteUrl().hasRef()) return TQt::blue; - else if(linktqStatus()->absoluteUrl().protocol() != "http" && - linktqStatus()->absoluteUrl().protocol() != "https") + else if(linkStatus()->absoluteUrl().protocol() != "http" && + linkStatus()->absoluteUrl().protocol() != "https") return TQt::darkGreen; else { - TQString status_code(TQString::number(linktqStatus()->httpHeader().statusCode())); + TQString status_code(TQString::number(linkStatus()->httpHeader().statusCode())); if(status_code[0] == '0') { kdWarning(23100) << "status code == 0: " << endl; - kdWarning(23100) << linktqStatus()->toString() << endl; - kdWarning(23100) << linktqStatus()->httpHeader().toString() << endl; + kdWarning(23100) << linkStatus()->toString() << endl; + kdWarning(23100) << linkStatus()->httpHeader().toString() << endl; } //Q_ASSERT(status_code[0] != '0'); @@ -538,7 +538,7 @@ TQColor const& TableItem::textStatusColor() const */ TableItemURL::TableItemURL(TQTable* table, EditType et, - LinktqStatus const* linkstatus, int column_index) + LinkStatus const* linkstatus, int column_index) : TableItem(table, et, linkstatus, column_index) { setText(); @@ -546,17 +546,17 @@ TableItemURL::TableItemURL(TQTable* table, EditType et, void TableItemURL::setText() { - if(linktqStatus()->node() && linktqStatus()->malformed()) + if(linkStatus()->node() && linkStatus()->malformed()) { - if(linktqStatus()->node()->url().isEmpty()) - TQTableItem::setText( linktqStatus()->node()->content().simplifyWhiteSpace() ); + if(linkStatus()->node()->url().isEmpty()) + TQTableItem::setText( linkStatus()->node()->content().simplifyWhiteSpace() ); else - TQTableItem::setText( linktqStatus()->node()->url() ); + TQTableItem::setText( linkStatus()->node()->url() ); } else { - KURL url = linktqStatus()->absoluteUrl(); - TQTableItem::setText(::convertToLocal(linktqStatus())); + KURL url = linkStatus()->absoluteUrl(); + TQTableItem::setText(::convertToLocal(linkStatus())); } } @@ -583,19 +583,19 @@ TQColor const& TableItemURL::textStatusColor() const { // TODO clean this code - TQString status_code(TQString::number(linktqStatus()->httpHeader().statusCode())); + TQString status_code(TQString::number(linkStatus()->httpHeader().statusCode())); - if(linktqStatus()->errorOccurred()) + if(linkStatus()->errorOccurred()) { - if(linktqStatus()->error().contains(i18n( "Timeout" ))) + if(linkStatus()->error().contains(i18n( "Timeout" ))) return darkMagenta; - else if(linktqStatus()->error().contains(i18n( "not supported" ))) + else if(linkStatus()->error().contains(i18n( "not supported" ))) return lightGray; else return red; } - else if(linktqStatus()->absoluteUrl().protocol() != "http" && - linktqStatus()->absoluteUrl().protocol() != "https") + else if(linkStatus()->absoluteUrl().protocol() != "http" && + linkStatus()->absoluteUrl().protocol() != "https") return black; else if(status_code[0] == '5') @@ -610,53 +610,53 @@ TQColor const& TableItemURL::textStatusColor() const /* -********************* TableItemtqStatus *************************** +********************* TableItemStatus *************************** */ -TableItemtqStatus::TableItemtqStatus(TQTable* table, EditType et, - LinktqStatus const* linkstatus, int column_index) +TableItemStatus::TableItemStatus(TQTable* table, EditType et, + LinkStatus const* linkstatus, int column_index) : TableItem(table, et, linkstatus, column_index) { - tqsetAlignment(TQt::AlignHCenter /*| TQt :: AlignVCenter*/); + setAlignment(TQt::AlignHCenter /*| TQt :: AlignVCenter*/); setText(); setPixmap(); } -void TableItemtqStatus::setText() +void TableItemStatus::setText() { - if(linktqStatus()->errorOccurred() || - linktqStatus()->status() == "OK" || - linktqStatus()->status() == "304") + if(linkStatus()->errorOccurred() || + linkStatus()->status() == "OK" || + linkStatus()->status() == "304") { TQTableItem::setText(""); } else { /* - if(linktqStatus()->httpHeader().statusCode() == 0) + if(linkStatus()->httpHeader().statusCode() == 0) { kdDebug(23100) << "TableItemStatus::setText : statusCode() == 0" << endl; - kdDebug(23100) << linktqStatus()->toString() << endl; - kdDebug(23100) << linktqStatus()->docHtml() << endl; + kdDebug(23100) << linkStatus()->toString() << endl; + kdDebug(23100) << linkStatus()->docHtml() << endl; } */ - //Q_ASSERT(linktqStatus()->httpHeader().statusCode() != 0); //<------------------------------------------------------------ - //TQTableItem::setText( TQString::number(linktqStatus()->httpHeader().statusCode()) ); - TQTableItem::setText( linktqStatus()->status() ); + //Q_ASSERT(linkStatus()->httpHeader().statusCode() != 0); //<------------------------------------------------------------ + //TQTableItem::setText( TQString::number(linkStatus()->httpHeader().statusCode()) ); + TQTableItem::setText( linkStatus()->status() ); } } -void TableItemtqStatus::setPixmap() +void TableItemStatus::setPixmap() { - if(linktqStatus()->errorOccurred()) + if(linkStatus()->errorOccurred()) { - if(linktqStatus()->error().contains(i18n( "Timeout" ))) + if(linkStatus()->error().contains(i18n( "Timeout" ))) { TQTableItem::setPixmap(SmallIcon("kalarm")); } - else if(linktqStatus()->error() == i18n( "Malformed" )) + else if(linkStatus()->error() == i18n( "Malformed" )) { TQTableItem::setPixmap(SmallIcon("bug")); } @@ -665,27 +665,27 @@ void TableItemtqStatus::setPixmap() TQTableItem::setPixmap(SmallIcon("no")); } } - else if(linktqStatus()->status() == "304") + else if(linkStatus()->status() == "304") TQTableItem::setPixmap(UserIcon("304")); - else if(linktqStatus()->status() == "OK") + else if(linkStatus()->status() == "OK") TQTableItem::setPixmap(SmallIcon("ok")); } -TQString TableItemtqStatus::toolTip() const +TQString TableItemStatus::toolTip() const { - if(linktqStatus()->errorOccurred() || - linktqStatus()->absoluteUrl().hasRef() || - (linktqStatus()->absoluteUrl().protocol() != "http" && - linktqStatus()->absoluteUrl().protocol() != "https")) + if(linkStatus()->errorOccurred() || + linkStatus()->absoluteUrl().hasRef() || + (linkStatus()->absoluteUrl().protocol() != "http" && + linkStatus()->absoluteUrl().protocol() != "https")) { - return i18n("%1").tqarg(linktqStatus()->status()); + return i18n("%1").arg(linkStatus()->status()); } else - return i18n("%1").tqarg(linktqStatus()->httpHeader().reasonPhrase()); + return i18n("%1").arg(linkStatus()->httpHeader().reasonPhrase()); } -void TableItemtqStatus::paint( TQPainter *p, const TQColorGroup &cg, +void TableItemStatus::paint( TQPainter *p, const TQColorGroup &cg, const TQRect &cr, bool selected ) { p->fillRect( 0, 0, cr.width(), cr.height(), @@ -716,7 +716,7 @@ void TableItemtqStatus::paint( TQPainter *p, const TQColorGroup &cg, else p->setPen( m_cg.text() ); p->drawText( x + 2, 0, w - x - 4, h, - wordWrap() ? (tqalignment() | WordBreak) : tqalignment(), text() ); + wordWrap() ? (alignment() | WordBreak) : alignment(), text() ); } /* @@ -726,7 +726,7 @@ void TableItemtqStatus::paint( TQPainter *p, const TQColorGroup &cg, */ TableItemNome::TableItemNome(TQTable* table, EditType et, - LinktqStatus const* linkstatus, int column_index) + LinkStatus const* linkstatus, int column_index) : TableItem(table, et, linkstatus, column_index) { setText(); @@ -734,7 +734,7 @@ TableItemNome::TableItemNome(TQTable* table, EditType et, void TableItemNome::setText() { - TQString label(linktqStatus()->label()); + TQString label(linkStatus()->label()); if(!label.isNull()) TQTableItem::setText(label.simplifyWhiteSpace()); } diff --git a/klinkstatus/src/ui/tablelinkstatus.h b/klinkstatus/src/ui/tablelinkstatus.h index d3113ee0..6f601508 100644 --- a/klinkstatus/src/ui/tablelinkstatus.h +++ b/klinkstatus/src/ui/tablelinkstatus.h @@ -58,12 +58,12 @@ public: virtual void setColumns(TQStringList const& columns); /* Insere uma nova entrada no fim da tabela */ - virtual void insertResult(LinktqStatus const* linkstatus); + virtual void insertResult(LinkStatus const* linkstatus); virtual void clear(); void removeColunas(); - virtual void show(ResultView::tqStatus const& status); + virtual void show(ResultView::Status const& status); virtual void showAll(); @@ -90,7 +90,7 @@ private slots: private: - vector<TableItem*> generateRowOfTableItems(LinktqStatus const* linkstatus); + vector<TableItem*> generateRowOfTableItems(LinkStatus const* linkstatus); void insereLinha(vector<TableItem*> items); private: @@ -110,18 +110,18 @@ class TableItem: public TQTableItem, public ResultViewItem public: TableItem(TQTable* table, EditType et, - LinktqStatus const* linkstatus, - int column_index, int tqalignment = TQt::AlignLeft); + LinkStatus const* linkstatus, + int column_index, int alignment = TQt::AlignLeft); virtual ~TableItem(); virtual void setColumnIndex(int i); virtual int columnIndex() const; - void tqsetAlignment(int aFlags); - virtual int tqalignment() const; + void setAlignment(int aFlags); + virtual int alignment() const; virtual TQString toolTip() const = 0; - //LinktqStatus const* const linktqStatus() const; + //LinkStatus const* const linkStatus() const; protected: @@ -133,7 +133,7 @@ protected: private: - //LinktqStatus* ls_; + //LinkStatus* ls_; //int column_index_; int alignment_; }; @@ -144,7 +144,7 @@ class TableItemURL: public TableItem public: TableItemURL(TQTable* table, EditType et, - LinktqStatus const* linkstatus, int column_index = 3); + LinkStatus const* linkstatus, int column_index = 3); //virtual ~TableItemURL(){}; virtual TQString toolTip() const; @@ -158,13 +158,13 @@ protected: }; -class TableItemtqStatus: public TableItem +class TableItemStatus: public TableItem { public: - TableItemtqStatus(TQTable* table, EditType et, - LinktqStatus const* linkstatus, int column_index = 1); - //virtual ~TableItemtqStatus(){}; + TableItemStatus(TQTable* table, EditType et, + LinkStatus const* linkstatus, int column_index = 1); + //virtual ~TableItemStatus(){}; virtual TQString toolTip() const; @@ -181,7 +181,7 @@ class TableItemNome: public TableItem public: TableItemNome(TQTable* table, EditType et, - LinktqStatus const* linkstatus, int column_index = 2); + LinkStatus const* linkstatus, int column_index = 2); //virtual ~TableItemNome(){}; virtual TQString toolTip() const; diff --git a/klinkstatus/src/ui/tabwidgetsession.cpp b/klinkstatus/src/ui/tabwidgetsession.cpp index 7502d58b..bc7f1492 100644 --- a/klinkstatus/src/ui/tabwidgetsession.cpp +++ b/klinkstatus/src/ui/tabwidgetsession.cpp @@ -117,8 +117,8 @@ SessionWidget* TabWidgetSession::newSession() { // TODO: settings: number of connections, timeout SessionWidget* session_widget = newSessionWidget(); - connect(session_widget, TQT_SIGNAL(signalUpdateTabLabel(const LinktqStatus *, SessionWidget*)), - this, TQT_SLOT(updateTabLabel(const LinktqStatus *, SessionWidget*))); + connect(session_widget, TQT_SIGNAL(signalUpdateTabLabel(const LinkStatus *, SessionWidget*)), + this, TQT_SLOT(updateTabLabel(const LinkStatus *, SessionWidget*))); insertTab(session_widget, i18n("Session") + i18n(TQString::number(count() + 1).ascii())); @@ -166,7 +166,7 @@ SessionWidget* TabWidgetSession::newSessionWidget() return session_widget; } -void TabWidgetSession::updateTabLabel(LinktqStatus const* linkstatus, SessionWidget* page) +void TabWidgetSession::updateTabLabel(LinkStatus const* linkstatus, SessionWidget* page) { TQString label; KURL url = linkstatus->absoluteUrl(); diff --git a/klinkstatus/src/ui/tabwidgetsession.h b/klinkstatus/src/ui/tabwidgetsession.h index 4c83ba49..c98adb0a 100644 --- a/klinkstatus/src/ui/tabwidgetsession.h +++ b/klinkstatus/src/ui/tabwidgetsession.h @@ -27,7 +27,7 @@ class TQToolButton; class SessionWidget; -class LinktqStatus; +class LinkStatus; /** @@ -59,7 +59,7 @@ public slots: SessionWidget* newSession(); SessionWidget* newSession(KURL const& url); void closeSession(); - void updateTabLabel(LinktqStatus const* linkstatus, SessionWidget*); + void updateTabLabel(LinkStatus const* linkstatus, SessionWidget*); void slotLoadSettings(); void slotHideSearchPanel(); diff --git a/klinkstatus/src/ui/treeview.cpp b/klinkstatus/src/ui/treeview.cpp index 21bcdf02..8bc51471 100644 --- a/klinkstatus/src/ui/treeview.cpp +++ b/klinkstatus/src/ui/treeview.cpp @@ -30,7 +30,7 @@ #include <tqvaluevector.h> #include <tqheader.h> -#include <tqclipboard.h> +#include <clipboard.h> #include "treeview.h" #include "../global.h" @@ -114,16 +114,16 @@ void TreeView::removeColunas() clear(); } -void TreeView::show(ResultView::tqStatus const& status) +void TreeView::show(ResultView::Status const& status) { TQListViewItemIterator it(static_cast<KListView*> (this)); while(it.current()) { TreeViewItem* item = myItem(it.current()); - if(!ResultView::displayableWithtqStatus(item->linktqStatus(), status)) + if(!ResultView::displayableWithStatus(item->linkStatus(), status)) { item->setVisible(false); - //kdDebug(23100) << "Hide: " << item->linktqStatus()->absoluteUrl().url() << endl; + //kdDebug(23100) << "Hide: " << item->linkStatus()->absoluteUrl().url() << endl; } else { @@ -135,7 +135,7 @@ void TreeView::show(ResultView::tqStatus const& status) TreeViewItem* parent = myItem(item->parent()); while(parent) { - kdDebug(23100) << "Show: " << parent->linktqStatus()->absoluteUrl().url() << endl; + kdDebug(23100) << "Show: " << parent->linkStatus()->absoluteUrl().url() << endl; parent->setVisible(true); //parent->setEnabled(false); @@ -159,7 +159,7 @@ void TreeView::show(LinkMatcher link_matcher) while(it.current()) { TreeViewItem* item = myItem(it.current()); - bool match = link_matcher.matches(*(item->linktqStatus())); + bool match = link_matcher.matches(*(item->linkStatus())); if(tree_display_) item->setEnabled(match); @@ -199,7 +199,7 @@ void TreeView::resizeEvent(TQResizeEvent *e) { KListView::resizeEvent(e); resetColumns(); - clipper()->tqrepaint(); + clipper()->repaint(); } void TreeView::slotPopupContextMenu(TQListViewItem* item, const TQPoint& pos, int col) @@ -209,8 +209,8 @@ void TreeView::slotPopupContextMenu(TQListViewItem* item, const TQPoint& pos, in TreeViewItem* tree_item = myItem(item); if(tree_item) { - TQValueVector<KURL> referrers = tree_item->linktqStatus()->referrers(); - loadContextTableMenu(referrers, tree_item->linktqStatus()->isRoot()); + TQValueVector<KURL> referrers = tree_item->linkStatus()->referrers(); + loadContextTableMenu(referrers, tree_item->linkStatus()->isRoot()); context_table_menu_.popup(pos); } } @@ -218,16 +218,16 @@ void TreeView::slotPopupContextMenu(TQListViewItem* item, const TQPoint& pos, in void TreeView::slotCopyUrlToClipboard() const { TreeViewItem* _item = myItem(currentItem()); - TQString content(_item->linktqStatus()->absoluteUrl().prettyURL()); - TQClipboard* cb = kapp->tqclipboard(); + TQString content(_item->linkStatus()->absoluteUrl().prettyURL()); + TQClipboard* cb = kapp->clipboard(); cb->setText(content); } void TreeView::slotCopyParentUrlToClipboard() const { TreeViewItem* _item = myItem(currentItem()); - TQString content(_item->linktqStatus()->parent()->absoluteUrl().prettyURL()); - TQClipboard* cb = kapp->tqclipboard(); + TQString content(_item->linkStatus()->parent()->absoluteUrl().prettyURL()); + TQClipboard* cb = kapp->clipboard(); cb->setText(content); } @@ -235,14 +235,14 @@ void TreeView::slotCopyCellTextToClipboard() const { TreeViewItem* _item = myItem(currentItem()); TQString cell_text(_item->text(current_column_)); - TQClipboard* cb = kapp->tqclipboard(); + TQClipboard* cb = kapp->clipboard(); cb->setText(cell_text); } void TreeView::slotEditReferrersWithQuanta() { TreeViewItem* _item = myItem(currentItem()); - TQValueVector<KURL> referrers = _item->linktqStatus()->referrers(); + TQValueVector<KURL> referrers = _item->linkStatus()->referrers(); if(Global::isQuantaAvailableViaDCOP()) { @@ -275,7 +275,7 @@ void TreeView::slotEditReferrerWithQuanta(int id) index -= 2; // The list of referrers starts on index = 2 TreeViewItem* _item = myItem(currentItem()); - TQValueVector<KURL> referrers = _item->linktqStatus()->referrers(); + TQValueVector<KURL> referrers = _item->linkStatus()->referrers(); Q_ASSERT(index >= 0 && (uint)index < referrers.size()); slotEditReferrerWithQuanta(referrers[index]); @@ -292,7 +292,7 @@ void TreeView::slotEditReferrerWithQuanta(KURL const& url) if(!success) { - TQString message = i18n("<qt>File <b>%1</b> cannot be opened. Might be a DCOP problem.</qt>").tqarg(filePath); + TQString message = i18n("<qt>File <b>%1</b> cannot be opened. Might be a DCOP problem.</qt>").arg(filePath); KMessageBox::error(parentWidget(), message); } } @@ -306,7 +306,7 @@ void TreeView::slotEditReferrerWithQuanta(KURL const& url) void TreeView::slotViewUrlInBrowser() { TreeViewItem* _item = myItem(currentItem()); - KURL url = _item->linktqStatus()->absoluteUrl(); + KURL url = _item->linkStatus()->absoluteUrl(); if(url.isValid()) { @@ -320,13 +320,13 @@ void TreeView::slotViewParentUrlInBrowser() { TreeViewItem* _item = myItem(currentItem()); - if(_item->linktqStatus()->isRoot()) + if(_item->linkStatus()->isRoot()) { KMessageBox::sorry(this, i18n("ROOT URL.")); } else { - LinktqStatus const* ls_parent = _item->linktqStatus()->parent(); + LinkStatus const* ls_parent = _item->linkStatus()->parent(); Q_ASSERT(ls_parent); KURL url = ls_parent->absoluteUrl(); @@ -393,7 +393,7 @@ TreeViewItem* TreeView::myItem(TQListViewItem* item) const /* ******************************* TreeViewItem ******************************* */ TreeViewItem::TreeViewItem(TreeView* parent, TQListViewItem* after, - LinktqStatus const* linkstatus) + LinkStatus const* linkstatus) : KListViewItem(parent, after), last_child_(0), root_(parent) { @@ -401,7 +401,7 @@ TreeViewItem::TreeViewItem(TreeView* parent, TQListViewItem* after, } TreeViewItem::TreeViewItem(TreeView* root, TQListViewItem* listview_item, TQListViewItem* after, - LinktqStatus const* linkstatus) + LinkStatus const* linkstatus) : KListViewItem(listview_item, after), last_child_(0), root_(root) @@ -412,7 +412,7 @@ TreeViewItem::TreeViewItem(TreeView* root, TQListViewItem* listview_item, TQList TreeViewItem::~TreeViewItem() {} -void TreeViewItem::init(LinktqStatus const* linkstatus) +void TreeViewItem::init(LinkStatus const* linkstatus) { setOpen(true); @@ -450,15 +450,15 @@ TQString TreeViewItem::key(int column, bool) const switch(column) { case 1: // status column - return linktqStatus()->statusText(); + return linkStatus()->statusText(); } return text(column); } -LinktqStatus const* TreeViewItem::linktqStatus() const +LinkStatus const* TreeViewItem::linkStatus() const { - return column_items_[0].linktqStatus(); + return column_items_[0].linkStatus(); } void TreeViewItem::paintCell(TQPainter * p, const TQColorGroup & cg, int column, int width, int align) @@ -478,7 +478,7 @@ void TreeViewItem::paintCell(TQPainter * p, const TQColorGroup & cg, int column, /* ******************************* TreeColumnViewItem ******************************* */ -TreeColumnViewItem::TreeColumnViewItem(TreeView* root, LinktqStatus const* linkstatus, int column_index) +TreeColumnViewItem::TreeColumnViewItem(TreeView* root, LinkStatus const* linkstatus, int column_index) : root_(root), ls_(linkstatus), column_index_(column_index) { Q_ASSERT(ls_); @@ -501,7 +501,7 @@ int TreeColumnViewItem::columnIndex() const return column_index_; } -LinktqStatus const* TreeColumnViewItem::linktqStatus() const +LinkStatus const* TreeColumnViewItem::linkStatus() const { Q_ASSERT(ls_); return ls_; @@ -511,23 +511,23 @@ TQColor const& TreeColumnViewItem::textStatusColor() const { if(columnIndex() == root_->urlColumnIndex() || columnIndex() == root_->statusColumnIndex()) { - if(linktqStatus()->status() == LinktqStatus::BROKEN) + if(linkStatus()->status() == LinkStatus::BROKEN) return TQt::red; - else if(linktqStatus()->status() == LinktqStatus::HTTP_CLIENT_ERROR) + else if(linkStatus()->status() == LinkStatus::HTTP_CLIENT_ERROR) return TQt::red; - else if(linktqStatus()->status() == LinktqStatus::HTTP_REDIRECTION) + else if(linkStatus()->status() == LinkStatus::HTTP_REDIRECTION) return TQt::black; - else if(linktqStatus()->status() == LinktqStatus::HTTP_SERVER_ERROR) + else if(linkStatus()->status() == LinkStatus::HTTP_SERVER_ERROR) return TQt::darkMagenta; - else if(linktqStatus()->status() == LinktqStatus::MALFORMED) + else if(linkStatus()->status() == LinkStatus::MALFORMED) return TQt::red; - else if(linktqStatus()->status() == LinktqStatus::NOT_SUPPORTED) + else if(linkStatus()->status() == LinkStatus::NOT_SUPPORTED) return TQt::lightGray; - else if(linktqStatus()->status() == LinktqStatus::SUCCESSFULL) + else if(linkStatus()->status() == LinkStatus::SUCCESSFULL) return TQt::black; - else if(linktqStatus()->status() == LinktqStatus::TIMEOUT) + else if(linkStatus()->status() == LinkStatus::TIMEOUT) return TQt::darkMagenta; - else if(linktqStatus()->status() == LinktqStatus::UNDETERMINED) + else if(linkStatus()->status() == LinkStatus::UNDETERMINED) return TQt::blue; return TQt::red; @@ -544,17 +544,17 @@ TQString TreeColumnViewItem::text(int column) const if(column == root_->urlColumnIndex()) { - if(linktqStatus()->node() && linktqStatus()->malformed()) + if(linkStatus()->node() && linkStatus()->malformed()) { - if(linktqStatus()->node()->url().isEmpty()) - return linktqStatus()->node()->content().simplifyWhiteSpace(); + if(linkStatus()->node()->url().isEmpty()) + return linkStatus()->node()->content().simplifyWhiteSpace(); else - return linktqStatus()->node()->url(); + return linkStatus()->node()->url(); } else { - KURL url = linktqStatus()->absoluteUrl(); - return Url::convertToLocal(linktqStatus()); + KURL url = linkStatus()->absoluteUrl(); + return Url::convertToLocal(linkStatus()); } } else if(column == root_->statusColumnIndex()) @@ -563,7 +563,7 @@ TQString TreeColumnViewItem::text(int column) const } else if(column == root_->labelColumnIndex()) { - TQString label(linktqStatus()->label()); + TQString label(linkStatus()->label()); if(!label.isNull()) return label.simplifyWhiteSpace(); } @@ -577,28 +577,28 @@ TQPixmap TreeColumnViewItem::pixmap(int column) const if(column == root_->statusColumnIndex()) { - if(linktqStatus()->status() == LinktqStatus::BROKEN) + if(linkStatus()->status() == LinkStatus::BROKEN) return SmallIcon("no"); - else if(linktqStatus()->status() == LinktqStatus::HTTP_CLIENT_ERROR) + else if(linkStatus()->status() == LinkStatus::HTTP_CLIENT_ERROR) return SmallIcon("no"); - else if(linktqStatus()->status() == LinktqStatus::HTTP_REDIRECTION) + else if(linkStatus()->status() == LinkStatus::HTTP_REDIRECTION) { - if(linktqStatus()->statusText() == "304") + if(linkStatus()->statusText() == "304") return UserIcon("304"); else return SmallIcon("redo"); } - else if(linktqStatus()->status() == LinktqStatus::HTTP_SERVER_ERROR) + else if(linkStatus()->status() == LinkStatus::HTTP_SERVER_ERROR) return SmallIcon("no"); - else if(linktqStatus()->status() == LinktqStatus::MALFORMED) + else if(linkStatus()->status() == LinkStatus::MALFORMED) return SmallIcon("editdelete"); - else if(linktqStatus()->status() == LinktqStatus::NOT_SUPPORTED) + else if(linkStatus()->status() == LinkStatus::NOT_SUPPORTED) return SmallIcon("help"); - else if(linktqStatus()->status() == LinktqStatus::SUCCESSFULL) + else if(linkStatus()->status() == LinkStatus::SUCCESSFULL) return SmallIcon("ok"); - else if(linktqStatus()->status() == LinktqStatus::TIMEOUT) + else if(linkStatus()->status() == LinkStatus::TIMEOUT) return SmallIcon("history_clear"); - else if(linktqStatus()->status() == LinktqStatus::UNDETERMINED) + else if(linkStatus()->status() == LinkStatus::UNDETERMINED) return SmallIcon("help"); } diff --git a/klinkstatus/src/ui/treeview.h b/klinkstatus/src/ui/treeview.h index 6b48cc63..8735a595 100644 --- a/klinkstatus/src/ui/treeview.h +++ b/klinkstatus/src/ui/treeview.h @@ -38,7 +38,7 @@ public: virtual void setColumns(TQStringList const& columns); virtual void clear(); void removeColunas(); - virtual void show(ResultView::tqStatus const& status); + virtual void show(ResultView::Status const& status); void show(LinkMatcher link_matcher); virtual void showAll(); @@ -92,22 +92,22 @@ class TreeViewItem: public KListViewItem public: TreeViewItem(TreeView* parent, TQListViewItem* after, - LinktqStatus const* linkstatus); + LinkStatus const* linkstatus); TreeViewItem(TreeView* root, TQListViewItem* parent_item, TQListViewItem* after, - LinktqStatus const* linkstatus); + LinkStatus const* linkstatus); virtual ~TreeViewItem(); void setLastChild(TQListViewItem* last_child); TQListViewItem* lastChild() const; TQString key(int column, bool) const; - LinktqStatus const* linktqStatus() const; + LinkStatus const* linkStatus() const; protected: virtual void paintCell(TQPainter * p, const TQColorGroup & cg, int column, int width, int align); private: - void init(LinktqStatus const* linkstatus); + void init(LinkStatus const* linkstatus); private: TQValueVector<TreeColumnViewItem> column_items_; @@ -124,19 +124,19 @@ public: TreeColumnViewItem() {} ; - TreeColumnViewItem(TreeView* root, LinktqStatus const* linkstatus, int column_index); + TreeColumnViewItem(TreeView* root, LinkStatus const* linkstatus, int column_index); ~TreeColumnViewItem(); //void setColumnIndex(int i); int columnIndex() const; - LinktqStatus const* linktqStatus() const; + LinkStatus const* linkStatus() const; TQColor const& textStatusColor() const; TQString text(int column) const; TQPixmap pixmap(int column) const; private: TreeView* root_; - LinktqStatus const* ls_; + LinkStatus const* ls_; int column_index_; }; |