diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:46:43 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:46:43 +0000 |
commit | ffe8a83e053396df448e9413828527613ca3bd46 (patch) | |
tree | a73d4169e02df4a50f9a12cb165fcd0ab5bac7c6 /kdeui/kwhatsthismanager.cpp | |
parent | 682bf3bfdcbcbb1fca85e8a36ed03e062e0555d5 (diff) | |
download | tdelibs-ffe8a83e053396df448e9413828527613ca3bd46.tar.gz tdelibs-ffe8a83e053396df448e9413828527613ca3bd46.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1157647 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdeui/kwhatsthismanager.cpp')
-rw-r--r-- | kdeui/kwhatsthismanager.cpp | 52 |
1 files changed, 26 insertions, 26 deletions
diff --git a/kdeui/kwhatsthismanager.cpp b/kdeui/kwhatsthismanager.cpp index 77c957a62..a2f3cf0f6 100644 --- a/kdeui/kwhatsthismanager.cpp +++ b/kdeui/kwhatsthismanager.cpp @@ -17,10 +17,10 @@ * Boston, MA 02110-1301, USA. */ #include "kwhatsthismanager_p.h" -#include "qwhatsthis.h" -#include <qvariant.h> +#include "tqwhatsthis.h" +#include <tqvariant.h> #include <kdebug.h> -#include <qtextedit.h> +#include <tqtextedit.h> #include <klocale.h> #include <kapplication.h> @@ -29,57 +29,57 @@ KWhatsThisManager *KWhatsThisManager::s_instance = 0; class KWhatsThisUndefined : public QWhatsThis { public: - KWhatsThisUndefined (QWidget *); - QString text (const QPoint &); + KWhatsThisUndefined (TQWidget *); + TQString text (const TQPoint &); public slots: - bool clicked (const QString &); + bool clicked (const TQString &); protected: - QWidget *m_widget; + TQWidget *m_widget; }; -KWhatsThisUndefined::KWhatsThisUndefined (QWidget *w) - : QWhatsThis (w) +KWhatsThisUndefined::KWhatsThisUndefined (TQWidget *w) + : TQWhatsThis (w) { m_widget = w; } -QString KWhatsThisUndefined::text (const QPoint &) +TQString KWhatsThisUndefined::text (const TQPoint &) { if (!m_widget) return ""; - QString txt = i18n ("<b>Not Defined</b><br>There is no \"What's This?\"" + TQString txt = i18n ("<b>Not Defined</b><br>There is no \"What's This?\"" " help assigned to this widget. If you want to help us to " " describe the widget, you are welcome to <a href=\"submit" "-whatsthis\">send us your own \"What's This?\" help</a> for it."); - QString parent; + TQString parent; if (m_widget -> parentWidget ()) - parent = QWhatsThis::textFor (m_widget -> parentWidget ()); + parent = TQWhatsThis::textFor (m_widget -> parentWidget ()); if (parent != txt) if (! parent . isEmpty ()) return parent; return txt; } -bool KWhatsThisUndefined::clicked (const QString& href) +bool KWhatsThisUndefined::clicked (const TQString& href) { if (href == "submit-whatsthis") { - QWidget *w = m_widget; - QString body; + TQWidget *w = m_widget; + TQString body; body . append ("Widget text: '" + (m_widget -> property ("text") . toString ()) + "'\n"); - QString dsc = QString ("current --> ") + m_widget -> name (); - dsc . append (QString (" (") + m_widget -> className () + ")\n"); + TQString dsc = TQString ("current --> ") + m_widget -> name (); + dsc . append (TQString (" (") + m_widget -> className () + ")\n"); for (w = m_widget; w && w != m_widget -> topLevelWidget (); w = w -> parentWidget ()) { dsc . append (w -> name ()); - dsc . append (QString (" (") + w -> className () + ")\n"); + dsc . append (TQString (" (") + w -> className () + ")\n"); } w = m_widget -> topLevelWidget (); if (w) { dsc . append ("toplevel --> "); dsc . append (w -> name ()); - dsc . append (QString (" (") + w -> className () + ")\n"); + dsc . append (TQString (" (") + w -> className () + ")\n"); } body . append (dsc); - QString subj ("What's This submission: "); + TQString subj ("What's This submission: "); subj . append (qApp -> argv () [0]); body . append ("\nPlease type in your what's this help between these lines: " "\n--%-----------------------------------------------------------------------\n" @@ -102,15 +102,15 @@ KWhatsThisManager::KWhatsThisManager () // qApp -> installEventFilter (this); } -bool KWhatsThisManager::eventFilter (QObject * /*o*/, QEvent *e) +bool KWhatsThisManager::eventFilter (TQObject * /*o*/, TQEvent *e) { - if (e -> type () == QEvent::ChildInserted) { - QChildEvent *ce = (QChildEvent *)e; + if (e -> type () == TQEvent::ChildInserted) { + TQChildEvent *ce = (TQChildEvent *)e; // kdDebug () << "new qobject:" << ce -> child () << endl; if (ce -> child () -> isWidgetType ()) { - QWidget *w = (QWidget *) (ce -> child ()); + TQWidget *w = (TQWidget *) (ce -> child ()); // kdDebug () << "new qwidget:" << w << endl; - if (QWhatsThis::textFor (w) . isEmpty ()) + if (TQWhatsThis::textFor (w) . isEmpty ()) new KWhatsThisUndefined (w); } } |