• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • interfaces
 

interfaces

  • interfaces
  • tdescript
scriptmanager.h
1/* This file is part of the KDE project
2 Copyright (C) 2001 Ian Reinhart Geiser (geiseri@kde.org)
3
4 This library is free software; you can redistribute it and/or
5 modify it under the terms of the GNU Library General Public
6 License as published by the Free Software Foundation; either
7 version 2 of the License, or (at your option) any later version.
8
9 This library is distributed in the hope that it will be useful,
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 Library General Public License for more details.
13
14 You should have received a copy of the GNU Library General Public License
15 along with this library; see the file COPYING.LIB. If not, write to
16 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 Boston, MA 02110-1301, USA.
18*/
19#ifndef __scriptmanager_h__
20#define __scriptmanager_h__
21
22#include <tqvariant.h>
23#include <scriptclientinterface.h>
24#include <scriptinterface.h>
25#include <tqdict.h>
26#include <tqobject.h>
27
28#include <tdelibs_export.h>
29
30class ScriptInfo;
31//namespace KScriptInterface
32//{
33
39 class TDE_EXPORT KScriptManager : public TQObject, public KScriptClientInterface
40 {
41 TQ_OBJECT
42 friend class KScriptInterface;
43 public:
47 KScriptManager(TQObject *parent, const char *name);
51 virtual ~KScriptManager();
57 bool addScript( const TQString &scriptDesktopFile);
62 bool removeScript( const TQString &scriptName );
67 TQStringList scripts();
71 void clear();
76 void error( const TQString &msg ) {emit scriptError(msg);}
81 void warning( const TQString &msg ) {emit scriptWarning(msg);}
86 void output( const TQString &msg ) {emit scriptOutput(msg);}
93 void progress( int percent ) {emit scriptProgress(percent);}
99 void done( KScriptClientInterface::Result result, const TQVariant &returned ) {emit scriptDone(result, returned);}
100
101 public slots:
105 void runScript( const TQString &scriptName, TQObject *context = 0, const TQVariant &arg = 0 );
106 signals:
111 void scriptError( const TQString &msg );
116 void scriptWarning( const TQString &msg );
121 void scriptOutput( const TQString &msg );
126 void scriptProgress( int percent);
131 void scriptDone( KScriptClientInterface::Result result, const TQVariant &returned);
132 protected:
133 TQDict<ScriptInfo> m_scripts;
134 TQDict<KScriptInterface> m_scriptCache;
135 //TQStringList m_scriptNames;
136 TQString m_currentScript;
137 };
138//};
139#endif
KScriptClientInterface
This class is used for allowing feedback to the main system.
Definition: scriptclientinterface.h:74
KScriptInterface
This class is the base for all script engines.
Definition: scriptinterface.h:48
KScriptManager
This class is the base for all script engines.
Definition: scriptmanager.h:40
KScriptManager::scriptDone
void scriptDone(KScriptClientInterface::Result result, const TQVariant &returned)
Send out a signal of the exit status of the script.
KScriptManager::warning
void warning(const TQString &msg)
This function will allow the main application of any warnings that have occurred during the processin...
Definition: scriptmanager.h:81
KScriptManager::scriptError
void scriptError(const TQString &msg)
Send out a signal of the error message from the current running script.
KScriptManager::scriptOutput
void scriptOutput(const TQString &msg)
Send out a signal of the output message from the current running script.
KScriptManager::scriptWarning
void scriptWarning(const TQString &msg)
Send out a signal of the warning message from the current running script.
KScriptManager::output
void output(const TQString &msg)
This function will allow the main application of any normal output that has occurred during the proce...
Definition: scriptmanager.h:86
KScriptManager::error
void error(const TQString &msg)
This function will allow the main application of any errors that have occurred during processing of t...
Definition: scriptmanager.h:76
KScriptManager::done
void done(KScriptClientInterface::Result result, const TQVariant &returned)
This function will allow feedback on completion of the script.
Definition: scriptmanager.h:99
KScriptManager::scriptProgress
void scriptProgress(int percent)
Send out a signal of the progress of the current running script.
KScriptManager::progress
void progress(int percent)
This function will allow feedback to any progress bars in the main application as to how far along th...
Definition: scriptmanager.h:93

interfaces

Skip menu "interfaces"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

interfaces

Skip menu "interfaces"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for interfaces by doxygen 1.9.4
This website is maintained by Timothy Pearson.