From 2ea8296a80cea67f07d15d6994579dfcc0022885 Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Sun, 14 Jan 2024 16:30:02 +0900 Subject: Use new TQ_METHOD, TQ_SIGNAL, TQ_SLOT defines Signed-off-by: Michele Calgaro (cherry picked from commit 1a2c703f4d5f22e9f8a0e74a2976895d85318e51) --- tde-i18n-da/docs/tdebase/ksplashml/index.docbook | 2 +- .../docs/tdevelop/kde_app_devel/index.docbook | 14 +++++------ tde-i18n-da/docs/tdevelop/kdearch/index.docbook | 28 +++++++++++----------- 3 files changed, 22 insertions(+), 22 deletions(-) (limited to 'tde-i18n-da') diff --git a/tde-i18n-da/docs/tdebase/ksplashml/index.docbook b/tde-i18n-da/docs/tdebase/ksplashml/index.docbook index 6b5bd5f3b4a..12f1637a36f 100644 --- a/tde-i18n-da/docs/tdebase/ksplashml/index.docbook +++ b/tde-i18n-da/docs/tdebase/ksplashml/index.docbook @@ -990,7 +990,7 @@ c2, int sp ) preparePixmap( i ); m_stepTimer = new QTimer( this ); - connect(m_stepTimer, SIGNAL(timeout()), this, SLOT(stepEvent())); + connect(m_stepTimer, TQ_SIGNAL(timeout()), this, TQ_SLOT(stepEvent())); m_stepTimer->start( 50 ); } diff --git a/tde-i18n-da/docs/tdevelop/kde_app_devel/index.docbook b/tde-i18n-da/docs/tdevelop/kde_app_devel/index.docbook index 47ae77a6a71..5db3b727f6b 100644 --- a/tde-i18n-da/docs/tdevelop/kde_app_devel/index.docbook +++ b/tde-i18n-da/docs/tdevelop/kde_app_devel/index.docbook @@ -255,14 +255,14 @@ hello.resize( 100, 30 ); a.setMainWidget( &hello ); -TQObject::connect(&hello, SIGNAL( clicked() ), &a, SLOT( quit() )); +TQObject::connect(&hello, TQ_SIGNAL( clicked() ), &a, TQ_SLOT( quit() )); hello.show(); return a.exec(); } -Du mærker at alt du skal tilføje for at give knappen mere kommunikation er metoden connect(): connect (&hello, SIGNAL( clicked() ), &a, SLOT( quit() ));. Hvad er betydningen nu? Klassedeklarationen af TQObject siger følgende om metoden connect(): +Du mærker at alt du skal tilføje for at give knappen mere kommunikation er metoden connect(): connect (&hello, TQ_SIGNAL( clicked() ), &a, TQ_SLOT( quit() ));. Hvad er betydningen nu? Klassedeklarationen af TQObject siger følgende om metoden connect(): bool connect ( const TQObject * afsender, const char * signal, const TQObject * modtager, const char * medlem ) Dette betyder at du skal angive en TQObject-instanspeger som er signalets afsender, hvilket betyder at den kan sende signalet, som første parameter. Derefter skal du angive signalet som du vil forbinde til. De to sidste parametre er modtagerobjektet som sørger for en slot, fulgt af medlemsfunktionen som er en virkelig slot som vil køres når signalet sendes. Ved at bruge signaler og slots, kan programmets objekter nemt kommunikere med hinanden uden udtrykkeligt at afhænge af typen af modtagarobjektet. Du vil lære mere om hvordan denne mekanisme bruges produktivt senere i håndbogen. Mere information om signal/slot-mekanismen findes også i KDE's biblioteksreferenceguide og QT's reference på nettet. @@ -304,7 +304,7 @@ hello.resize( 100, 30 ); a.setTopWidget( &hello ); -TQObject::connect(&hello, SIGNAL( clicked() ), &a, SLOT( quit() )); +TQObject::connect(&hello, TQ_SIGNAL( clicked() ), &a, TQ_SLOT( quit() )); hello.show(); return a.exec(); @@ -549,10 +549,10 @@ return a.exec(); 16 statusBar()->show(); 17 18 // tillad visningen at ændre statuslinjen og overskriften -19 connect(m_view, SIGNAL(signalChangeStatusbar(const TQString&)), -20 this, SLOT(changeStatusbar(const TQString&))); -21 connect(m_view, SIGNAL(signalChangeCaption(const TQString&)), -22 this, SLOT(changeCaption(const TQString&))); +19 connect(m_view, TQ_SIGNAL(signalChangeStatusbar(const TQString&)), +20 this, TQ_SLOT(changeStatusbar(const TQString&))); +21 connect(m_view, TQ_SIGNAL(signalChangeCaption(const TQString&)), +22 this, TQ_SLOT(changeCaption(const TQString&))); 23 24 } diff --git a/tde-i18n-da/docs/tdevelop/kdearch/index.docbook b/tde-i18n-da/docs/tdevelop/kdearch/index.docbook index 973d66fddb1..6b84fa2f39d 100644 --- a/tde-i18n-da/docs/tdevelop/kdearch/index.docbook +++ b/tde-i18n-da/docs/tdevelop/kdearch/index.docbook @@ -881,23 +881,23 @@ rc_DATA = kviewui.rc Den tilsvarende del til at oprette dette i C++ er: -KStdAction::zoomIn ( this, SLOT(slotZoomIn()), actionCollection() ); - KStdAction::zoomOut ( this, SLOT(slotZoomOut()), actionCollection() ); - KStdAction::zoom ( this, SLOT(slotZoom()), actionCollection() ); +KStdAction::zoomIn ( this, TQ_SLOT(slotZoomIn()), actionCollection() ); + KStdAction::zoomOut ( this, TQ_SLOT(slotZoomOut()), actionCollection() ); + KStdAction::zoom ( this, TQ_SLOT(slotZoom()), actionCollection() ); new TDEAction ( i18n("&Half size"), ALT+Key_0, - this, SLOT(slotHalfSize()), + this, TQ_SLOT(slotHalfSize()), actionCollection(), "zoom50" ); new TDEAction ( i18n("&Normal size"), ALT+Key_1, - this, SLOT(slotDoubleSize()), + this, TQ_SLOT(slotDoubleSize()), actionCollection(), "zoom100" ); new TDEAction ( i18n("&Double size"), ALT+Key_2, - this, SLOT(slotDoubleSize()), + this, TQ_SLOT(slotDoubleSize()), actionCollection(), "zoom200" ); new TDEAction ( i18n("&Fill Screen"), ALT+Key_3, - this, SLOT(slotFillScreen()), + this, TQ_SLOT(slotFillScreen()), actionCollection(), "zoomMaxpect" ); new TDEAction ( i18n("Fullscreen &Mode"), CTRL+SHIFT+Key_F, - this, SLOT(slotFullScreen()), + this, TQ_SLOT(slotFullScreen()), actionCollection(), "fullscreen" ); @@ -1400,8 +1400,8 @@ else { KURL url("http://developer.kde.org/favicon.ico"); TDEIO::MimetypeJob *job = TDEIO::mimetype(url); - connect( job, SIGNAL(result(TDEIO::Job*)), - this, SLOT(mimeResult(TDEIO::Job*)) ); + connect( job, TQ_SIGNAL(result(TDEIO::Job*)), + this, TQ_SLOT(mimeResult(TDEIO::Job*)) ); } void FooClass::mimeResult(TDEIO::Job *job) @@ -1507,8 +1507,8 @@ new KRun(url); void FooClass::makeDirectory() { SimpleJob *job = TDEIO::mkdir(KURL("file:/home/bernd/kiodir")); - connect( job, SIGNAL(result(TDEIO::Job*)), - this, SLOT(mkdirResult(TDEIO::Job*)) ); + connect( job, TQ_SIGNAL(result(TDEIO::Job*)), + this, TQ_SLOT(mkdirResult(TDEIO::Job*)) ); } void FooClass::mkdirResult(TDEIO::Job *job) @@ -1692,8 +1692,8 @@ if (TDEIO::NetAccess::download(url, tempFile) { { KURL url("http://developer.kde.org/documentation/kde2arch/index.html"); TDEIO::TransferJob *job = TDEIO::get(url, true, false); - connect( job, SIGNAL(result(TDEIO::Job*)), - this, SLOT(transferResult(TDEIO::Job*)) ); + connect( job, TQ_SIGNAL(result(TDEIO::Job*)), + this, TQ_SLOT(transferResult(TDEIO::Job*)) ); } void FooClass::transferResult(TDEIO::Job *job) -- cgit v1.2.1