diff options
author | Michele Calgaro <[email protected]> | 2025-01-20 18:26:11 +0900 |
---|---|---|
committer | Michele Calgaro <[email protected]> | 2025-02-03 21:44:11 +0900 |
commit | 02ed3f2d62dfb2efb4f3610ca96098341518483f (patch) | |
tree | 7156180f5dd4044ad1614ddf50407c1cc3e516bf /kturtle/src | |
parent | 0b13a7b9e0f99415119eef29f05c54a01e5ec90a (diff) | |
download | tdeedu-02ed3f2d62dfb2efb4f3610ca96098341518483f.tar.gz tdeedu-02ed3f2d62dfb2efb4f3610ca96098341518483f.zip |
Use tdeApp
Signed-off-by: Michele Calgaro <[email protected]>
Diffstat (limited to 'kturtle/src')
-rw-r--r-- | kturtle/src/dialogs.cpp | 6 | ||||
-rw-r--r-- | kturtle/src/executer.cpp | 28 | ||||
-rw-r--r-- | kturtle/src/kturtle.cpp | 14 |
3 files changed, 24 insertions, 24 deletions
diff --git a/kturtle/src/dialogs.cpp b/kturtle/src/dialogs.cpp index d358860c..0499b7db 100644 --- a/kturtle/src/dialogs.cpp +++ b/kturtle/src/dialogs.cpp @@ -125,13 +125,13 @@ void ErrorMessage::updateSelection() void ErrorMessage::showHelpOnError() { // #if 0 // FIXME -// kapp->invokeHelp(tokenTypeNames[currentError.tok.type], "", ""); +// tdeApp->invokeHelp(tokenTypeNames[currentError.tok.type], "", ""); // #endif } void ErrorMessage::errorMessageHelp() { - kapp->invokeHelp("anchorname", "", ""); + tdeApp->invokeHelp("anchorname", "", ""); } // END @@ -288,7 +288,7 @@ void ColorPicker::slotEmitColorCode() void ColorPicker::slotColorPickerHelp() { - kapp->invokeHelp("tools-color-picker", "", ""); + tdeApp->invokeHelp("tools-color-picker", "", ""); } // END diff --git a/kturtle/src/executer.cpp b/kturtle/src/executer.cpp index eec03261..d98f5df8 100644 --- a/kturtle/src/executer.cpp +++ b/kturtle/src/executer.cpp @@ -61,7 +61,7 @@ bool Executer::run() for (i = tree->begin(); i != tree->end(); ++i) { if (bAbort) return false; - kapp->processEvents(); + tdeApp->processEvents(); execute(*i); symbolTables.pop(); //free up stack @@ -103,7 +103,7 @@ void Executer::pause() // The next line is within all loops of the Executer // if (bAbort) return; // mostly before - // kapp->processEvents(); + // tdeApp->processEvents(); // this to keep the GUI of KTurtle accessible while executing the logo code // so the Abort button can be clicked, and will function bPause = true; @@ -114,7 +114,7 @@ void Executer::abort() // The next line is within all loops of the Executer // if(bAbort) return; // mostly before - // kapp->processEvents(); + // tdeApp->processEvents(); // this to keep the GUI of KTurtle accessible while executing the logo code // so the Abort button can be clicked, and will function bAbort = true; @@ -244,7 +244,7 @@ void Executer::execFunction(TreeNode* node) { if (bAbort) return; if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); // execute the parameters which can be expressions execute(*pfrom); @@ -305,7 +305,7 @@ void Executer::execBlock(TreeNode* node) if (runSpeed != 0) slowDown(*i); if (bAbort) return; if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); execute(*i); @@ -334,7 +334,7 @@ void Executer::execForEach(TreeNode* node) { if (bAbort) return; if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); execute(statements); if (bBreak || bReturn) break; //jump out loop @@ -369,7 +369,7 @@ void Executer::execFor(TreeNode* node) { if (bAbort) return; if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); ( symbolTables.top() )[name] = d; execute( statements ); if (bBreak || bReturn) break; //jump out loop @@ -390,7 +390,7 @@ void Executer::execFor(TreeNode* node) { if (bAbort) return; if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); (symbolTables.top() )[name] = d; execute( statements ); @@ -403,7 +403,7 @@ void Executer::execFor(TreeNode* node) { if (bAbort) return; if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); ( symbolTables.top() )[name] = d; execute(statements); @@ -427,7 +427,7 @@ void Executer::execRepeat(TreeNode* node) { if (bAbort) return; if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); execute(statements); if (bBreak || bReturn) break; //jump out loop @@ -447,7 +447,7 @@ void Executer::execWhile(TreeNode* node) { if (bAbort) return; if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); execute(statements); if (bBreak || bReturn) break; //jump out loop @@ -647,7 +647,7 @@ TQString Executer::runCommand(const TQString& command) while( fgets(buf, sizeof(buf), pstream) !=NULL) { if (bAbort) return (""); - kapp->processEvents(); + tdeApp->processEvents(); Line += buf; } @@ -1020,7 +1020,7 @@ void Executer::startWaiting(int msec) { if (bAbort) return; // waits need to be interrupted by the stop action if (bPause) startPausing(); - kapp->processEvents(); + tdeApp->processEvents(); // only 10 times per second is enough... else the CPU gets 100% loaded ( not nice :) usleep(100000); @@ -1037,7 +1037,7 @@ void Executer::startPausing() while (bPause == true) { if (bAbort) return; // waits need to be interrupted by the stop action - kapp->processEvents(); + tdeApp->processEvents(); // only 10 times per second is enough... else the CPU gets 100% loaded ( not nice :) usleep(100000); } diff --git a/kturtle/src/kturtle.cpp b/kturtle/src/kturtle.cpp index b62f5e4c..04416053 100644 --- a/kturtle/src/kturtle.cpp +++ b/kturtle/src/kturtle.cpp @@ -86,7 +86,7 @@ MainWindow::MainWindow(KTextEditor::Document *document) : editor(0) { KMessageBox::error( this, i18n("A TDE text-editor component could not be found;\n" "please check your TDE installation.") ); - kapp->exit(1); + tdeApp->exit(1); } // docList.append(doc); } @@ -101,9 +101,9 @@ MainWindow::MainWindow(KTextEditor::Document *document) : editor(0) setMinimumSize(200,200); // init with more usefull size, stolen from kwite (they stole it from konq) - if ( !initialGeometrySet() && !kapp->config()->hasGroup("MainWindow Settings") ) resize(640, 480); + if ( !initialGeometrySet() && !tdeApp->config()->hasGroup("MainWindow Settings") ) resize(640, 480); - TDEConfig *config = kapp->config(); + TDEConfig *config = tdeApp->config(); readConfig(config); } @@ -490,7 +490,7 @@ bool MainWindow::queryClose() } } } - TDEConfig *config = kapp->config(); + TDEConfig *config = tdeApp->config(); config->setGroup("General Options"); m_recentFiles->saveEntries(config, "Recent Files"); config->sync(); @@ -520,7 +520,7 @@ void MainWindow::slotExecute() // start paring slotStatusBar(i18n("Parsing commands..."), IDS_STATUS); kdDebug(0)<<"############## PARSING STARTED ##############"<<endl; - kapp->processEvents(); + tdeApp->processEvents(); errMsg = new ErrorMessage(this); // create an empty errorDialog TQString txt = editorInterface->text() + "\x0a\x0a"; // parser expects input to have 2 delimiting newlines TQTextIStream in(&txt); // create the stream @@ -984,7 +984,7 @@ void MainWindow::readConfig(TDEConfig *config) void MainWindow::slotSettingsHelp() { - kapp->invokeHelp("settings-configure", "", ""); + tdeApp->invokeHelp("settings-configure", "", ""); } // END @@ -1040,7 +1040,7 @@ void MainWindow::slotContextHelp() kdDebug(0)<<"trying to open a help page using this keyword: "<<helpWord<<endl; - kapp->invokeHelp(helpWord, "", ""); + tdeApp->invokeHelp(helpWord, "", ""); TQString help2statusBar; if ( helpKeyword.startsWith("<") ) help2statusBar = helpKeyword; |