summaryrefslogtreecommitdiffstats
path: root/khotkeys/shared
diff options
context:
space:
mode:
Diffstat (limited to 'khotkeys/shared')
-rw-r--r--khotkeys/shared/action_data.cpp22
-rw-r--r--khotkeys/shared/action_data.h84
-rw-r--r--khotkeys/shared/actions.cpp48
-rw-r--r--khotkeys/shared/actions.h92
-rw-r--r--khotkeys/shared/conditions.cpp44
-rw-r--r--khotkeys/shared/conditions.h46
-rw-r--r--khotkeys/shared/gestures.cpp18
-rw-r--r--khotkeys/shared/gestures.h28
-rw-r--r--khotkeys/shared/input.cpp36
-rw-r--r--khotkeys/shared/input.h20
-rw-r--r--khotkeys/shared/khlistbox.cpp32
-rw-r--r--khotkeys/shared/khlistbox.h16
-rw-r--r--khotkeys/shared/khlistview.cpp28
-rw-r--r--khotkeys/shared/khlistview.h18
-rw-r--r--khotkeys/shared/khotkeysglobal.cpp10
-rw-r--r--khotkeys/shared/khotkeysglobal.h6
-rw-r--r--khotkeys/shared/settings.cpp22
-rw-r--r--khotkeys/shared/settings.h2
-rw-r--r--khotkeys/shared/sound.cpp34
-rw-r--r--khotkeys/shared/sound.h10
-rw-r--r--khotkeys/shared/soundrecorder.cpp6
-rw-r--r--khotkeys/shared/soundrecorder.h8
-rw-r--r--khotkeys/shared/triggers.cpp48
-rw-r--r--khotkeys/shared/triggers.h58
-rw-r--r--khotkeys/shared/voices.cpp26
-rw-r--r--khotkeys/shared/voices.h16
-rw-r--r--khotkeys/shared/voicesignature.cpp30
-rw-r--r--khotkeys/shared/voicesignature.h14
-rw-r--r--khotkeys/shared/windows.cpp48
-rw-r--r--khotkeys/shared/windows.h74
30 files changed, 472 insertions, 472 deletions
diff --git a/khotkeys/shared/action_data.cpp b/khotkeys/shared/action_data.cpp
index 96e3e5559..472259268 100644
--- a/khotkeys/shared/action_data.cpp
+++ b/khotkeys/shared/action_data.cpp
@@ -25,8 +25,8 @@ namespace KHotKeys
// Action_data_base
-Action_data_base::Action_data_base( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, Condition_list* conditions_P, bool enabled_P )
+Action_data_base::Action_data_base( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, Condition_list* conditions_P, bool enabled_P )
: _parent( parent_P ), _conditions( conditions_P ), _name( name_P ), _comment( comment_P ),
_enabled( enabled_P )
{
@@ -39,7 +39,7 @@ Action_data_base::Action_data_base( Action_data_group* parent_P, const QString&
Action_data_base::Action_data_base( KConfig& cfg_P, Action_data_group* parent_P )
: _parent( parent_P )
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
_name = cfg_P.readEntry( "Name" );
_comment = cfg_P.readEntry( "Comment" );
_enabled = cfg_P.readBoolEntry( "Enabled", true );
@@ -64,7 +64,7 @@ void Action_data_base::cfg_write( KConfig& cfg_P ) const
cfg_P.writeEntry( "Name", name());
cfg_P.writeEntry( "Comment", comment());
cfg_P.writeEntry( "Enabled", enabled( true ));
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Conditions" );
assert( conditions() != NULL );
conditions()->cfg_write( cfg_P );
@@ -74,7 +74,7 @@ void Action_data_base::cfg_write( KConfig& cfg_P ) const
Action_data_base* Action_data_base::create_cfg_read( KConfig& cfg_P, Action_data_group* parent_P )
{
- QString type = cfg_P.readEntry( "Type" );
+ TQString type = cfg_P.readEntry( "Type" );
if( type == "ACTION_DATA_GROUP" )
{
if( cfg_P.readBoolEntry( "AllowMerge", false ))
@@ -169,7 +169,7 @@ void Action_data_group::update_triggers()
Action_data::Action_data( KConfig& cfg_P, Action_data_group* parent_P )
: Action_data_base( cfg_P, parent_P )
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Triggers" );
_triggers = new Trigger_list( cfg_P, this );
cfg_P.setGroup( save_cfg_group + "Actions" );
@@ -188,7 +188,7 @@ Action_data::~Action_data()
void Action_data::cfg_write( KConfig& cfg_P ) const
{
Action_data_base::cfg_write( cfg_P );
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Triggers" );
triggers()->cfg_write( cfg_P );
cfg_P.setGroup( save_cfg_group + "Actions" );
@@ -286,8 +286,8 @@ void Generic_action_data::cfg_write( KConfig& cfg_P ) const
// Command_url_shortcut_action_data
Command_url_shortcut_action_data::Command_url_shortcut_action_data( Action_data_group* parent_P,
- const QString& name_P, const QString& comment_P,
- const KShortcut& shortcut_P, const QString& command_url_P, bool enabled_P )
+ const TQString& name_P, const TQString& comment_P,
+ const KShortcut& shortcut_P, const TQString& command_url_P, bool enabled_P )
: Simple_action_data< Shortcut_trigger, Command_url_action >( parent_P, name_P,
comment_P, enabled_P )
{
@@ -306,8 +306,8 @@ void Simple_action_data< Shortcut_trigger, Command_url_action >
// Menuentry_shortcut_action_data
Menuentry_shortcut_action_data::Menuentry_shortcut_action_data( Action_data_group* parent_P,
- const QString& name_P, const QString& comment_P,
- const KShortcut& shortcut_P, const QString& menuentry_P, bool enabled_P )
+ const TQString& name_P, const TQString& comment_P,
+ const KShortcut& shortcut_P, const TQString& menuentry_P, bool enabled_P )
: Simple_action_data< Shortcut_trigger, Menuentry_action >( parent_P, name_P,
comment_P, enabled_P )
{
diff --git a/khotkeys/shared/action_data.h b/khotkeys/shared/action_data.h
index 9d6018c2c..4de5e715b 100644
--- a/khotkeys/shared/action_data.h
+++ b/khotkeys/shared/action_data.h
@@ -12,8 +12,8 @@
#define _ACTION_DATA_H_
#include <assert.h>
-#include <qstring.h>
-#include <qptrlist.h>
+#include <tqstring.h>
+#include <tqptrlist.h>
#include <kdebug.h>
@@ -34,8 +34,8 @@ class Action_data_group;
class KDE_EXPORT Action_data_base
{
public:
- Action_data_base( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, Condition_list* condition_P, bool enabled_P );
+ Action_data_base( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, Condition_list* condition_P, bool enabled_P );
Action_data_base( KConfig& cfg_P, Action_data_group* parent_P );
virtual ~Action_data_base();
virtual void cfg_write( KConfig& cfg_P ) const = 0;
@@ -44,9 +44,9 @@ class KDE_EXPORT Action_data_base
void reparent( Action_data_group* new_parent_P );
virtual void update_triggers() = 0;
bool conditions_match() const;
- const QString& name() const;
- void set_name( const QString& name_P );
- const QString& comment() const;
+ const TQString& name() const;
+ void set_name( const TQString& name_P );
+ const TQString& comment() const;
bool enabled( bool ignore_group_P ) const;
static Action_data_base* create_cfg_read( KConfig& cfg_P, Action_data_group* parent_P );
static bool cfg_is_enabled( KConfig& cfg_P );
@@ -55,8 +55,8 @@ class KDE_EXPORT Action_data_base
private:
Action_data_group* _parent;
Condition_list* _conditions;
- QString _name;
- QString _comment;
+ TQString _name;
+ TQString _comment;
bool _enabled; // is not really important, only used in conf. module and when reading cfg. file
KHOTKEYS_DISABLE_COPY( Action_data_base );
};
@@ -67,20 +67,20 @@ class KDE_EXPORT Action_data_group
public:
enum system_group_t { SYSTEM_NONE, SYSTEM_MENUENTRIES,
SYSTEM_ROOT, /* last one*/ SYSTEM_MAX }; // don't remove entries
- Action_data_group( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, Condition_list* conditions_P, system_group_t system_group_P,
+ Action_data_group( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, Condition_list* conditions_P, system_group_t system_group_P,
bool enabled_P );
Action_data_group( KConfig& cfg_P, Action_data_group* parent_P );
virtual ~Action_data_group();
virtual void update_triggers();
virtual void cfg_write( KConfig& cfg_P ) const;
- typedef QPtrListIterator< Action_data_base > Iterator; // CHECKME neni const :(
+ typedef TQPtrListIterator< Action_data_base > Iterator; // CHECKME neni const :(
Iterator first_child() const;
bool is_system_group() const;
system_group_t system_group() const;
using Action_data_base::set_conditions; // make public
protected:
- QPtrList< Action_data_base > list;
+ TQPtrList< Action_data_base > list;
system_group_t _system_group; // e.g. menuedit entries, can't be deleted or renamed
friend class Action_data_base; // CHECKME
void add_child( Action_data_base* child_P );
@@ -93,8 +93,8 @@ class KDE_EXPORT Action_data
{
typedef Action_data_base base;
public:
- Action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, Trigger_list* triggers_P, Condition_list* conditions_P,
+ Action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, Trigger_list* triggers_P, Condition_list* conditions_P,
Action_list* actions_P, bool enabled_P = true );
Action_data( KConfig& cfg_P, Action_data_group* parent_P );
virtual ~Action_data();
@@ -126,8 +126,8 @@ class KDE_EXPORT Generic_action_data
{
typedef Action_data base;
public:
- Generic_action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, Trigger_list* triggers_P, Condition_list* conditions_P,
+ Generic_action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, Trigger_list* triggers_P, Condition_list* conditions_P,
Action_list* actions_P, bool enabled_P = true );
Generic_action_data( KConfig& cfg_P, Action_data_group* parent_P );
virtual void cfg_write( KConfig& cfg_P ) const;
@@ -146,8 +146,8 @@ class KDE_EXPORT Simple_action_data
{
typedef Action_data base;
public:
- Simple_action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, bool enabled_P = true );
+ Simple_action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, bool enabled_P = true );
Simple_action_data( KConfig& cfg_P, Action_data_group* parent_P );
const A* action() const;
const T* trigger() const;
@@ -162,10 +162,10 @@ class KDE_EXPORT Command_url_shortcut_action_data
{
typedef Simple_action_data< Shortcut_trigger, Command_url_action > base;
public:
- Command_url_shortcut_action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, bool enabled_P = true );
- Command_url_shortcut_action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, const KShortcut& shortcut_P, const QString& command_url_P,
+ Command_url_shortcut_action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, bool enabled_P = true );
+ Command_url_shortcut_action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, const KShortcut& shortcut_P, const TQString& command_url_P,
bool enabled_P = true );
Command_url_shortcut_action_data( KConfig& cfg_P, Action_data_group* parent_P );
};
@@ -175,10 +175,10 @@ class KDE_EXPORT Menuentry_shortcut_action_data
{
typedef Simple_action_data< Shortcut_trigger, Menuentry_action > base;
public:
- Menuentry_shortcut_action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, bool enabled_P = true );
- Menuentry_shortcut_action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, const KShortcut& shortcut_P, const QString& command_url_P,
+ Menuentry_shortcut_action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, bool enabled_P = true );
+ Menuentry_shortcut_action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, const KShortcut& shortcut_P, const TQString& command_url_P,
bool enabled_P = true );
Menuentry_shortcut_action_data( KConfig& cfg_P, Action_data_group* parent_P );
};
@@ -194,8 +194,8 @@ class KDE_EXPORT Keyboard_input_gesture_action_data
{
typedef Action_data base;
public:
- Keyboard_input_gesture_action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, bool enabled_P = true );
+ Keyboard_input_gesture_action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, bool enabled_P = true );
Keyboard_input_gesture_action_data( KConfig& cfg_P, Action_data_group* parent_P );
const Keyboard_input_action* action() const;
// CHECKME kontrola, ze se dava jen jedna akce ?
@@ -233,19 +233,19 @@ Action_data_group* Action_data_base::parent() const
}
inline
-void Action_data_base::set_name( const QString& name_P )
+void Action_data_base::set_name( const TQString& name_P )
{
_name = name_P;
}
inline
-const QString& Action_data_base::name() const
+const TQString& Action_data_base::name() const
{
return _name;
}
inline
-const QString& Action_data_base::comment() const
+const TQString& Action_data_base::comment() const
{
return _comment;
}
@@ -253,8 +253,8 @@ const QString& Action_data_base::comment() const
// Action_data_group
inline
-Action_data_group::Action_data_group( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, Condition_list* conditions_P, system_group_t system_group_P,
+Action_data_group::Action_data_group( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, Condition_list* conditions_P, system_group_t system_group_P,
bool enabled_P )
: Action_data_base( parent_P, name_P, comment_P, conditions_P, enabled_P ),
_system_group( system_group_P )
@@ -302,8 +302,8 @@ void Action_data_group::remove_child( Action_data_base* child_P )
// Action_data
inline
-Action_data::Action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, Trigger_list* triggers_P, Condition_list* conditions_P,
+Action_data::Action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, Trigger_list* triggers_P, Condition_list* conditions_P,
Action_list* actions_P, bool enabled_P )
: Action_data_base( parent_P, name_P, comment_P, conditions_P, enabled_P ),
_triggers( triggers_P ), _actions( actions_P )
@@ -327,8 +327,8 @@ const Action_list* Action_data::actions() const
// Generic_action_data
inline
-Generic_action_data::Generic_action_data( Action_data_group* parent_P, const QString& name_P,
- const QString& comment_P, Trigger_list* triggers_P, Condition_list* conditions_P,
+Generic_action_data::Generic_action_data( Action_data_group* parent_P, const TQString& name_P,
+ const TQString& comment_P, Trigger_list* triggers_P, Condition_list* conditions_P,
Action_list* actions_P, bool enabled_P )
: Action_data( parent_P, name_P, comment_P, triggers_P, conditions_P, actions_P, enabled_P )
{
@@ -345,7 +345,7 @@ Generic_action_data::Generic_action_data( KConfig& cfg_P, Action_data_group* par
template< typename T, typename A >
inline
Simple_action_data< T, A >::Simple_action_data( Action_data_group* parent_P,
- const QString& name_P, const QString& comment_P, bool enabled_P )
+ const TQString& name_P, const TQString& comment_P, bool enabled_P )
: Action_data( parent_P, name_P, comment_P, NULL,
new Condition_list( "", this ), NULL, enabled_P )
{
@@ -394,7 +394,7 @@ const T* Simple_action_data< T, A >::trigger() const
inline
Command_url_shortcut_action_data::Command_url_shortcut_action_data( Action_data_group* parent_P,
- const QString& name_P, const QString& comment_P, bool enabled_P )
+ const TQString& name_P, const TQString& comment_P, bool enabled_P )
: Simple_action_data< Shortcut_trigger, Command_url_action >( parent_P, name_P,
comment_P, enabled_P )
{
@@ -411,7 +411,7 @@ Command_url_shortcut_action_data::Command_url_shortcut_action_data( KConfig& cfg
inline
Menuentry_shortcut_action_data::Menuentry_shortcut_action_data( Action_data_group* parent_P,
- const QString& name_P, const QString& comment_P, bool enabled_P )
+ const TQString& name_P, const TQString& comment_P, bool enabled_P )
: Simple_action_data< Shortcut_trigger, Menuentry_action >( parent_P, name_P,
comment_P, enabled_P )
{
@@ -428,7 +428,7 @@ Menuentry_shortcut_action_data::Menuentry_shortcut_action_data( KConfig& cfg_P,
inline
Keyboard_input_gesture_action_data::Keyboard_input_gesture_action_data(
- Action_data_group* parent_P, const QString& name_P, const QString& comment_P, bool enabled_P )
+ Action_data_group* parent_P, const TQString& name_P, const TQString& comment_P, bool enabled_P )
: Action_data( parent_P, name_P, comment_P, NULL,
new Condition_list( "", this ), NULL, enabled_P )
{
diff --git a/khotkeys/shared/actions.cpp b/khotkeys/shared/actions.cpp
index 144a277af..e37ef395f 100644
--- a/khotkeys/shared/actions.cpp
+++ b/khotkeys/shared/actions.cpp
@@ -42,7 +42,7 @@ namespace KHotKeys
Action* Action::create_cfg_read( KConfig& cfg_P, Action_data* data_P )
{
- QString type = cfg_P.readEntry( "Type" );
+ TQString type = cfg_P.readEntry( "Type" );
if( type == "COMMAND_URL" )
return new Command_url_action( cfg_P, data_P );
if( type == "MENUENTRY" )
@@ -65,16 +65,16 @@ void Action::cfg_write( KConfig& cfg_P ) const
// Action_list
Action_list::Action_list( KConfig& cfg_P, Action_data* data_P )
- : QPtrList< Action >()
+ : TQPtrList< Action >()
{
setAutoDelete( true );
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int cnt = cfg_P.readNumEntry( "ActionsCount", 0 );
for( int i = 0;
i < cnt;
++i )
{
- cfg_P.setGroup( save_cfg_group + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + TQString::number( i ));
Action* action = Action::create_cfg_read( cfg_P, data_P );
if( action )
append( action );
@@ -84,13 +84,13 @@ Action_list::Action_list( KConfig& cfg_P, Action_data* data_P )
void Action_list::cfg_write( KConfig& cfg_P ) const
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int i = 0;
for( Iterator it( *this );
it;
++it, ++i )
{
- cfg_P.setGroup( save_cfg_group + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + TQString::number( i ));
it.current()->cfg_write( cfg_P );
}
cfg_P.setGroup( save_cfg_group );
@@ -117,7 +117,7 @@ void Command_url_action::execute()
if( command_url().isEmpty())
return;
KURIFilterData uri;
- QString cmd = command_url();
+ TQString cmd = command_url();
static bool sm_ready = false;
if( !sm_ready )
{
@@ -176,7 +176,7 @@ void Command_url_action::execute()
timeout.start( 1000, true ); // 1sec timeout
}
-QString Command_url_action::description() const
+TQString Command_url_action::description() const
{
return i18n( "Command/URL : " ) + command_url();
}
@@ -212,10 +212,10 @@ void Menuentry_action::execute()
timeout.start( 1000, true ); // 1sec timeout
}
-QString Menuentry_action::description() const
+TQString Menuentry_action::description() const
{
(void) service();
- return i18n( "Menuentry : " ) + (_service ? _service->name() : QString::null);
+ return i18n( "Menuentry : " ) + (_service ? _service->name() : TQString::null);
}
Action* Menuentry_action::copy( Action_data* data_P ) const
@@ -248,8 +248,8 @@ void Dcop_action::execute()
{
if( app.isEmpty() || obj.isEmpty() || call.isEmpty())
return;
- QStringList args_list;
- QString args_str = args;
+ TQStringList args_list;
+ TQString args_str = args;
while( !args_str.isEmpty())
{
unsigned int pos = 0;
@@ -257,8 +257,8 @@ void Dcop_action::execute()
++pos;
if( args_str[ pos ] == '\"' || args_str[ pos ] == '\'' )
{
- QString val = "";
- QChar sep = args_str[ pos ];
+ TQString val = "";
+ TQChar sep = args_str[ pos ];
bool skip = false;
++pos;
for(;
@@ -297,7 +297,7 @@ void Dcop_action::execute()
proc.start( KProcess::DontCare );
}
-QString Dcop_action::description() const
+TQString Dcop_action::description() const
{
return i18n( "DCOP : " ) + remote_application() + "::" + remote_object() + "::"
+ called_function();
@@ -317,7 +317,7 @@ Keyboard_input_action::Keyboard_input_action( KConfig& cfg_P, Action_data* data_
_input = cfg_P.readEntry( "Input" );
if( cfg_P.readBoolEntry( "IsDestinationWindow" ))
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "DestinationWindow" );
_dest_window = new Windowdef_list( cfg_P );
_active_window = false; // ignored with _dest_window set anyway
@@ -343,7 +343,7 @@ void Keyboard_input_action::cfg_write( KConfig& cfg_P ) const
if( dest_window() != NULL )
{
cfg_P.writeEntry( "IsDestinationWindow", true );
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "DestinationWindow" );
dest_window()->cfg_write( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -374,23 +374,23 @@ void Keyboard_input_action::execute()
int last_index = -1, start = 0;
while(( last_index = input().find( ':', last_index + 1 )) != -1 ) // find next ';'
{
- QString key = input().mid( start, last_index - start ).stripWhiteSpace();
+ TQString key = input().mid( start, last_index - start ).stripWhiteSpace();
if( key == "Enter" && KKey( key ).keyCodeQt() == 0 )
key = "Return"; // CHECKE hack
keyboard_handler->send_macro_key( KKey( key ), w );
start = last_index + 1;
}
// and the last one
- QString key = input().mid( start, input().length()).stripWhiteSpace();
+ TQString key = input().mid( start, input().length()).stripWhiteSpace();
if( key == "Enter" && KKey( key ).keyCodeQt() == 0 )
key = "Return";
keyboard_handler->send_macro_key( KKey( key ), w ); // the rest
XFlush( qt_xdisplay());
}
-QString Keyboard_input_action::description() const
+TQString Keyboard_input_action::description() const
{
- QString tmp = input();
+ TQString tmp = input();
tmp.replace( '\n', ' ' );
tmp.truncate( 30 );
return i18n( "Keyboard input : " ) + tmp;
@@ -407,7 +407,7 @@ Action* Keyboard_input_action::copy( Action_data* data_P ) const
Activate_window_action::Activate_window_action( KConfig& cfg_P, Action_data* data_P )
: Action( cfg_P, data_P )
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Window" );
_window = new Windowdef_list( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -422,7 +422,7 @@ void Activate_window_action::cfg_write( KConfig& cfg_P ) const
{
base::cfg_write( cfg_P );
cfg_P.writeEntry( "Type", "ACTIVATE_WINDOW" ); // overwrites value set in base::cfg_write()
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Window" );
window()->cfg_write( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -437,7 +437,7 @@ void Activate_window_action::execute()
windows_handler->activate_window( win_id );
}
-QString Activate_window_action::description() const
+TQString Activate_window_action::description() const
{
return i18n( "Activate window : " ) + window()->comment();
}
diff --git a/khotkeys/shared/actions.h b/khotkeys/shared/actions.h
index 5295d5be9..828bbdb70 100644
--- a/khotkeys/shared/actions.h
+++ b/khotkeys/shared/actions.h
@@ -12,9 +12,9 @@
#define _ACTIONS_H_
-#include <qstring.h>
-#include <qptrlist.h>
-#include <qtimer.h>
+#include <tqstring.h>
+#include <tqptrlist.h>
+#include <tqtimer.h>
#include <kservice.h>
@@ -37,7 +37,7 @@ class KDE_EXPORT Action
Action( KConfig& cfg_P, Action_data* data_P );
virtual ~Action();
virtual void execute() = 0;
- virtual QString description() const = 0;
+ virtual TQString description() const = 0;
virtual void cfg_write( KConfig& cfg_P ) const;
virtual Action* copy( Action_data* data_P ) const = 0;
static Action* create_cfg_read( KConfig& cfg_P, Action_data* data_P );
@@ -47,16 +47,16 @@ class KDE_EXPORT Action
};
class KDE_EXPORT Action_list
- : public QPtrList< Action >
+ : public TQPtrList< Action >
{
public:
- Action_list( const QString& comment_P ); // CHECKME nebo i data ?
+ Action_list( const TQString& comment_P ); // CHECKME nebo i data ?
Action_list( KConfig& cfg_P, Action_data* data_P );
void cfg_write( KConfig& cfg_P ) const;
- typedef QPtrListIterator< Action > Iterator;
- const QString& comment() const;
+ typedef TQPtrListIterator< Action > Iterator;
+ const TQString& comment() const;
private:
- QString _comment;
+ TQString _comment;
KHOTKEYS_DISABLE_COPY( Action_list );
};
@@ -65,17 +65,17 @@ class KDE_EXPORT Command_url_action
{
typedef Action base;
public:
- Command_url_action( Action_data* data_P, const QString& command_url_P );
+ Command_url_action( Action_data* data_P, const TQString& command_url_P );
Command_url_action( KConfig& cfg_P, Action_data* data_P );
virtual void cfg_write( KConfig& cfg_P ) const;
virtual void execute();
- virtual QString description() const;
- const QString& command_url() const;
+ virtual TQString description() const;
+ const TQString& command_url() const;
virtual Action* copy( Action_data* data_P ) const;
protected:
- QTimer timeout;
+ TQTimer timeout;
private:
- QString _command_url;
+ TQString _command_url;
};
class KDE_EXPORT Menuentry_action
@@ -83,11 +83,11 @@ class KDE_EXPORT Menuentry_action
{
typedef Command_url_action base;
public:
- Menuentry_action( Action_data* data_P, const QString& menuentry_P );
+ Menuentry_action( Action_data* data_P, const TQString& menuentry_P );
Menuentry_action( KConfig& cfg_P, Action_data* data_P );
virtual void cfg_write( KConfig& cfg_P ) const;
virtual void execute();
- virtual QString description() const;
+ virtual TQString description() const;
virtual Action* copy( Action_data* data_P ) const;
KService::Ptr service() const;
private:
@@ -99,22 +99,22 @@ class KDE_EXPORT Dcop_action
{
typedef Action base;
public:
- Dcop_action( Action_data* data_P, const QString& app_P, const QString& obj_P,
- const QString& call_P, const QString& args_P );
+ Dcop_action( Action_data* data_P, const TQString& app_P, const TQString& obj_P,
+ const TQString& call_P, const TQString& args_P );
Dcop_action( KConfig& cfg_P, Action_data* data_P );
virtual void cfg_write( KConfig& cfg_P ) const;
virtual void execute();
- const QString& remote_application() const;
- const QString& remote_object() const;
- const QString& called_function() const;
- const QString& arguments() const;
- virtual QString description() const;
+ const TQString& remote_application() const;
+ const TQString& remote_object() const;
+ const TQString& called_function() const;
+ const TQString& arguments() const;
+ virtual TQString description() const;
virtual Action* copy( Action_data* data_P ) const;
private:
- QString app; // CHECKME QCString ?
- QString obj;
- QString call;
- QString args;
+ TQString app; // CHECKME TQCString ?
+ TQString obj;
+ TQString call;
+ TQString args;
};
class KDE_EXPORT Keyboard_input_action
@@ -122,22 +122,22 @@ class KDE_EXPORT Keyboard_input_action
{
typedef Action base;
public:
- Keyboard_input_action( Action_data* data_P, const QString& input_P,
+ Keyboard_input_action( Action_data* data_P, const TQString& input_P,
const Windowdef_list* dest_window_P, bool active_window_P );
Keyboard_input_action( KConfig& cfg_P, Action_data* data_P );
virtual ~Keyboard_input_action();
virtual void cfg_write( KConfig& cfg_P ) const;
virtual void execute();
- const QString& input() const;
+ const TQString& input() const;
// send to specific window: dest_window != NULL
// send to active window: dest_window == NULL && activeWindow() == true
// send to action window: dest_window == NULL && activeWindow() == false
const Windowdef_list* dest_window() const;
bool activeWindow() const;
- virtual QString description() const;
+ virtual TQString description() const;
virtual Action* copy( Action_data* data_P ) const;
private:
- QString _input;
+ TQString _input;
const Windowdef_list* _dest_window;
bool _active_window;
};
@@ -153,7 +153,7 @@ class KDE_EXPORT Activate_window_action
virtual void cfg_write( KConfig& cfg_P ) const;
virtual void execute();
const Windowdef_list* window() const;
- virtual QString description() const;
+ virtual TQString description() const;
virtual Action* copy( Action_data* data_P ) const;
private:
const Windowdef_list* _window;
@@ -185,14 +185,14 @@ Action::~Action()
// Action_list
inline
-Action_list::Action_list( const QString& comment_P )
- : QPtrList< Action >(), _comment( comment_P )
+Action_list::Action_list( const TQString& comment_P )
+ : TQPtrList< Action >(), _comment( comment_P )
{
setAutoDelete( true );
}
inline
-const QString& Action_list::comment() const
+const TQString& Action_list::comment() const
{
return _comment;
}
@@ -200,13 +200,13 @@ const QString& Action_list::comment() const
// Command_url_action
inline
-Command_url_action::Command_url_action( Action_data* data_P, const QString& command_url_P )
+Command_url_action::Command_url_action( Action_data* data_P, const TQString& command_url_P )
: Action( data_P ), _command_url( command_url_P )
{
}
inline
-const QString& Command_url_action::command_url() const
+const TQString& Command_url_action::command_url() const
{
return _command_url;
}
@@ -214,7 +214,7 @@ const QString& Command_url_action::command_url() const
// Menuentry_action
inline
-Menuentry_action::Menuentry_action( Action_data* data_P, const QString& menuentry_P )
+Menuentry_action::Menuentry_action( Action_data* data_P, const TQString& menuentry_P )
: Command_url_action( data_P, menuentry_P )
{
}
@@ -228,32 +228,32 @@ Menuentry_action::Menuentry_action( KConfig& cfg_P, Action_data* data_P )
// DCOP_action
inline
-Dcop_action::Dcop_action( Action_data* data_P, const QString& app_P, const QString& obj_P,
- const QString& call_P, const QString& args_P )
+Dcop_action::Dcop_action( Action_data* data_P, const TQString& app_P, const TQString& obj_P,
+ const TQString& call_P, const TQString& args_P )
: Action( data_P ), app( app_P ), obj( obj_P ), call( call_P ), args( args_P )
{
}
inline
-const QString& Dcop_action::remote_application() const
+const TQString& Dcop_action::remote_application() const
{
return app;
}
inline
-const QString& Dcop_action::remote_object() const
+const TQString& Dcop_action::remote_object() const
{
return obj;
}
inline
-const QString& Dcop_action::called_function() const
+const TQString& Dcop_action::called_function() const
{
return call;
}
inline
-const QString& Dcop_action::arguments() const
+const TQString& Dcop_action::arguments() const
{
return args;
}
@@ -261,14 +261,14 @@ const QString& Dcop_action::arguments() const
// Keyboard_input_action
inline
-Keyboard_input_action::Keyboard_input_action( Action_data* data_P, const QString& input_P,
+Keyboard_input_action::Keyboard_input_action( Action_data* data_P, const TQString& input_P,
const Windowdef_list* dest_window_P, bool active_window_P )
: Action( data_P ), _input( input_P ), _dest_window( dest_window_P ), _active_window( active_window_P )
{
}
inline
-const QString& Keyboard_input_action::input() const
+const TQString& Keyboard_input_action::input() const
{
return _input;
}
diff --git a/khotkeys/shared/conditions.cpp b/khotkeys/shared/conditions.cpp
index 01d236934..fb819f6c7 100644
--- a/khotkeys/shared/conditions.cpp
+++ b/khotkeys/shared/conditions.cpp
@@ -51,7 +51,7 @@ Condition::Condition( KConfig&, Condition_list_base* parent_P )
Condition* Condition::create_cfg_read( KConfig& cfg_P, Condition_list_base* parent_P )
{
- QString type = cfg_P.readEntry( "Type" );
+ TQString type = cfg_P.readEntry( "Type" );
if( type == "ACTIVE_WINDOW" )
return new Active_window_condition( cfg_P, parent_P );
if( type == "EXISTING_WINDOW" )
@@ -99,7 +99,7 @@ void Condition::debug( int depth_P )
kdDebug( 1217 ) << tmp << description() << ":(" << this << ")" << endl;
}
-void Condition::debug_list( const QPtrList< Condition >& list_P, int depth_P )
+void Condition::debug_list( const TQPtrList< Condition >& list_P, int depth_P )
{
char tmp[ 1024 ];
int i;
@@ -108,7 +108,7 @@ void Condition::debug_list( const QPtrList< Condition >& list_P, int depth_P )
++i )
tmp[ i ] = ' ';
tmp[ i ] = '\0';
- for( QPtrListIterator< Condition > it( list_P );
+ for( TQPtrListIterator< Condition > it( list_P );
it;
++it )
(*it)->debug( depth_P + 1 );
@@ -121,13 +121,13 @@ void Condition::debug_list( const QPtrList< Condition >& list_P, int depth_P )
Condition_list_base::Condition_list_base( KConfig& cfg_P, Condition_list_base* parent_P )
: Condition( parent_P )
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int cnt = cfg_P.readNumEntry( "ConditionsCount", 0 );
for( int i = 0;
i < cnt;
++i )
{
- cfg_P.setGroup( save_cfg_group + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + TQString::number( i ));
(void) Condition::create_cfg_read( cfg_P, this );
}
cfg_P.setGroup( save_cfg_group );
@@ -145,13 +145,13 @@ Condition_list_base::~Condition_list_base()
void Condition_list_base::cfg_write( KConfig& cfg_P ) const
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int i = 0;
for( Iterator it( *this );
it;
++it, ++i )
{
- cfg_P.setGroup( save_cfg_group + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + TQString::number( i ));
it.current()->cfg_write( cfg_P );
}
cfg_P.setGroup( save_cfg_group );
@@ -230,10 +230,10 @@ void Condition_list::set_data( Action_data_base* data_P )
data = data_P;
}
-const QString Condition_list::description() const
+const TQString Condition_list::description() const
{
assert( false );
- return QString::null;
+ return TQString::null;
}
Condition_list* Condition_list::copy( Condition_list_base* ) const
@@ -247,7 +247,7 @@ Condition_list* Condition_list::copy( Condition_list_base* ) const
Active_window_condition::Active_window_condition( KConfig& cfg_P, Condition_list_base* parent_P )
: Condition( cfg_P, parent_P )
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Window" );
_window = new Windowdef_list( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -257,8 +257,8 @@ Active_window_condition::Active_window_condition( KConfig& cfg_P, Condition_list
void Active_window_condition::init()
{
- connect( windows_handler, SIGNAL( active_window_changed( WId )),
- this, SLOT( active_window_changed( WId )));
+ connect( windows_handler, TQT_SIGNAL( active_window_changed( WId )),
+ this, TQT_SLOT( active_window_changed( WId )));
}
bool Active_window_condition::match() const
@@ -276,7 +276,7 @@ void Active_window_condition::set_match()
void Active_window_condition::cfg_write( KConfig& cfg_P ) const
{
base::cfg_write( cfg_P );
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Window" );
window()->cfg_write( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -292,7 +292,7 @@ Condition* Active_window_condition::copy( Condition_list_base* parent_P ) const
return new Active_window_condition( window()->copy(), parent_P );
}
-const QString Active_window_condition::description() const
+const TQString Active_window_condition::description() const
{
return i18n( "Active window: " ) + window()->comment();
}
@@ -313,7 +313,7 @@ Active_window_condition::~Active_window_condition()
Existing_window_condition::Existing_window_condition( KConfig& cfg_P, Condition_list_base* parent_P )
: Condition( cfg_P, parent_P )
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Window" );
_window = new Windowdef_list( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -323,8 +323,8 @@ Existing_window_condition::Existing_window_condition( KConfig& cfg_P, Condition_
void Existing_window_condition::init()
{
- connect( windows_handler, SIGNAL( window_added( WId )), this, SLOT( window_added( WId )));
- connect( windows_handler, SIGNAL( window_removed( WId )), this, SLOT( window_removed( WId )));
+ connect( windows_handler, TQT_SIGNAL( window_added( WId )), this, TQT_SLOT( window_added( WId )));
+ connect( windows_handler, TQT_SIGNAL( window_removed( WId )), this, TQT_SLOT( window_removed( WId )));
}
bool Existing_window_condition::match() const
@@ -345,7 +345,7 @@ void Existing_window_condition::set_match( WId w_P )
void Existing_window_condition::cfg_write( KConfig& cfg_P ) const
{
base::cfg_write( cfg_P );
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Window" );
window()->cfg_write( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -361,7 +361,7 @@ Condition* Existing_window_condition::copy( Condition_list_base* parent_P ) cons
return new Existing_window_condition( window()->copy(), parent_P );
}
-const QString Existing_window_condition::description() const
+const TQString Existing_window_condition::description() const
{
return i18n( "Existing window: " ) + window()->comment();
}
@@ -409,7 +409,7 @@ Not_condition* Not_condition::copy( Condition_list_base* parent_P ) const
return ret;
}
-const QString Not_condition::description() const
+const TQString Not_condition::description() const
{
return i18n( "Not_condition", "Not" );
}
@@ -453,7 +453,7 @@ And_condition* And_condition::copy( Condition_list_base* parent_P ) const
return ret;
}
-const QString And_condition::description() const
+const TQString And_condition::description() const
{
return i18n( "And_condition", "And" );
}
@@ -494,7 +494,7 @@ Or_condition* Or_condition::copy( Condition_list_base* parent_P ) const
return ret;
}
-const QString Or_condition::description() const
+const TQString Or_condition::description() const
{
return i18n( "Or_condition", "Or" );
}
diff --git a/khotkeys/shared/conditions.h b/khotkeys/shared/conditions.h
index 59133f4d3..bc0ca5d6e 100644
--- a/khotkeys/shared/conditions.h
+++ b/khotkeys/shared/conditions.h
@@ -11,9 +11,9 @@
#ifndef _CONDITIONS_H_
#define _CONDITIONS_H_
-#include <qobject.h>
-#include <qptrlist.h>
-#include <qstring.h>
+#include <tqobject.h>
+#include <tqptrlist.h>
+#include <tqstring.h>
#include "khotkeysglobal.h"
#include "windows.h"
@@ -39,7 +39,7 @@ class KDE_EXPORT Condition
virtual bool match() const = 0;
virtual void updated() const; // called when the condition changes
virtual void cfg_write( KConfig& cfg_P ) const = 0;
- virtual const QString description() const = 0;
+ virtual const TQString description() const = 0;
virtual Condition* copy( Condition_list_base* parent_P ) const = 0;
const Condition_list_base* parent() const;
Condition_list_base* parent();
@@ -50,18 +50,18 @@ class KDE_EXPORT Condition
};
class KDE_EXPORT Condition_list_base
- : public Condition, public QPtrList< Condition > // inheritance ?
+ : public Condition, public TQPtrList< Condition > // inheritance ?
{
typedef Condition base;
public:
Condition_list_base( Condition_list_base* parent_P );
- Condition_list_base( const QPtrList< Condition >& children_P,
+ Condition_list_base( const TQPtrList< Condition >& children_P,
Condition_list_base* parent_P );
Condition_list_base( KConfig& cfg_P, Condition_list_base* parent_P );
virtual ~Condition_list_base();
virtual void cfg_write( KConfig& cfg_P ) const;
virtual bool accepts_children() const;
- typedef QPtrListIterator< Condition > Iterator;
+ typedef TQPtrListIterator< Condition > Iterator;
};
class KDE_EXPORT Condition_list
@@ -69,23 +69,23 @@ class KDE_EXPORT Condition_list
{
typedef Condition_list_base base;
public:
- Condition_list( const QString& comment_P, Action_data_base* data_P );
+ Condition_list( const TQString& comment_P, Action_data_base* data_P );
Condition_list( KConfig& cfg_P, Action_data_base* data_P );
void cfg_write( KConfig& cfg_P ) const;
Condition_list* copy( Action_data_base* data_P ) const;
virtual bool match() const;
- const QString& comment() const;
+ const TQString& comment() const;
void set_data( Action_data_base* data_P );
virtual void updated() const;
virtual Condition_list* copy( Condition_list_base* parent_P ) const;
- virtual const QString description() const;
+ virtual const TQString description() const;
private:
- QString _comment;
+ TQString _comment;
Action_data_base* data;
};
class KDE_EXPORT Active_window_condition
- : public QObject, public Condition
+ : public TQObject, public Condition
{
Q_OBJECT
typedef Condition base;
@@ -101,7 +101,7 @@ class KDE_EXPORT Active_window_condition
#else
virtual Condition* copy( Condition_list_base* parent_P ) const;
#endif
- virtual const QString description() const;
+ virtual const TQString description() const;
public slots:
void active_window_changed( WId );
private:
@@ -112,7 +112,7 @@ class KDE_EXPORT Active_window_condition
};
class KDE_EXPORT Existing_window_condition
- : public QObject, public Condition
+ : public TQObject, public Condition
{
Q_OBJECT
typedef Condition base;
@@ -128,7 +128,7 @@ class KDE_EXPORT Existing_window_condition
#else
virtual Condition* copy( Condition_list_base* parent_P ) const;
#endif
- virtual const QString description() const;
+ virtual const TQString description() const;
public slots:
void window_added( WId w_P );
void window_removed( WId w_P );
@@ -149,7 +149,7 @@ class KDE_EXPORT Not_condition
virtual bool match() const;
virtual void cfg_write( KConfig& cfg_P ) const;
virtual Not_condition* copy( Condition_list_base* parent_P ) const;
- virtual const QString description() const;
+ virtual const TQString description() const;
const Condition* condition() const;
virtual bool accepts_children() const;
};
@@ -164,7 +164,7 @@ class KDE_EXPORT And_condition
virtual bool match() const;
virtual void cfg_write( KConfig& cfg_P ) const;
virtual And_condition* copy( Condition_list_base* parent_P ) const;
- virtual const QString description() const;
+ virtual const TQString description() const;
};
class KDE_EXPORT Or_condition
@@ -177,7 +177,7 @@ class KDE_EXPORT Or_condition
virtual bool match() const;
virtual void cfg_write( KConfig& cfg_P ) const;
virtual Or_condition* copy( Condition_list_base* parent_P ) const;
- virtual const QString description() const;
+ virtual const TQString description() const;
};
//***************************************************************************
@@ -202,27 +202,27 @@ Condition_list_base* Condition::parent()
inline
Condition_list_base::Condition_list_base( Condition_list_base* parent_P )
- : Condition( parent_P ), QPtrList< Condition >()
+ : Condition( parent_P ), TQPtrList< Condition >()
{
}
inline
-Condition_list_base::Condition_list_base( const QPtrList< Condition >& children_P,
+Condition_list_base::Condition_list_base( const TQPtrList< Condition >& children_P,
Condition_list_base* parent_P )
- : Condition( parent_P ), QPtrList< Condition >( children_P )
+ : Condition( parent_P ), TQPtrList< Condition >( children_P )
{
}
// Condition_list
inline
-Condition_list::Condition_list( const QString& comment_P, Action_data_base* data_P )
+Condition_list::Condition_list( const TQString& comment_P, Action_data_base* data_P )
: Condition_list_base( NULL ), _comment( comment_P ), data( data_P )
{
}
inline
-const QString& Condition_list::comment() const
+const TQString& Condition_list::comment() const
{
return _comment;
}
diff --git a/khotkeys/shared/gestures.cpp b/khotkeys/shared/gestures.cpp
index 11cc44e22..60b1d93b4 100644
--- a/khotkeys/shared/gestures.cpp
+++ b/khotkeys/shared/gestures.cpp
@@ -43,15 +43,15 @@ namespace KHotKeys
Gesture* gesture_handler;
-Gesture::Gesture( bool /*enabled_P*/, QObject* parent_P )
+Gesture::Gesture( bool /*enabled_P*/, TQObject* parent_P )
: _enabled( false ), recording( false ), button( 0 ), exclude( NULL )
{
(void) new DeleteObject( this, parent_P );
assert( gesture_handler == NULL );
gesture_handler = this;
- connect( &nostroke_timer, SIGNAL( timeout()), SLOT( stroke_timeout()));
- connect( windows_handler, SIGNAL( active_window_changed( WId )),
- SLOT( active_window_changed( WId )));
+ connect( &nostroke_timer, TQT_SIGNAL( timeout()), TQT_SLOT( stroke_timeout()));
+ connect( windows_handler, TQT_SIGNAL( active_window_changed( WId )),
+ TQT_SLOT( active_window_changed( WId )));
}
Gesture::~Gesture()
@@ -103,23 +103,23 @@ void Gesture::active_window_changed( WId )
update_grab();
}
-void Gesture::register_handler( QObject* receiver_P, const char* slot_P )
+void Gesture::register_handler( TQObject* receiver_P, const char* slot_P )
{
if( handlers.contains( receiver_P ))
return;
handlers[ receiver_P ] = true;
- connect( this, SIGNAL( handle_gesture( const QString&, WId )),
+ connect( this, TQT_SIGNAL( handle_gesture( const TQString&, WId )),
receiver_P, slot_P );
if( handlers.count() == 1 )
update_grab();
}
-void Gesture::unregister_handler( QObject* receiver_P, const char* slot_P )
+void Gesture::unregister_handler( TQObject* receiver_P, const char* slot_P )
{
if( !handlers.contains( receiver_P ))
return;
handlers.remove( receiver_P );
- disconnect( this, SIGNAL( handle_gesture( const QString&, WId )),
+ disconnect( this, TQT_SIGNAL( handle_gesture( const TQString&, WId )),
receiver_P, slot_P );
if( handlers.count() == 0 )
update_grab();
@@ -150,7 +150,7 @@ bool Gesture::x11Event( XEvent* ev_P )
recording = false;
nostroke_timer.stop();
stroke.record( ev_P->xbutton.x, ev_P->xbutton.y );
- QString gesture( stroke.translate());
+ TQString gesture( stroke.translate());
if( gesture.isEmpty())
{
kdDebug( 1217 ) << "GESTURE: replay" << endl;
diff --git a/khotkeys/shared/gestures.h b/khotkeys/shared/gestures.h
index 4c210528a..d423be8a6 100644
--- a/khotkeys/shared/gestures.h
+++ b/khotkeys/shared/gestures.h
@@ -11,8 +11,8 @@
#ifndef _GESTURES_H_
#define _GESTURES_H_
-#include <qwidget.h>
-#include <qtimer.h>
+#include <tqwidget.h>
+#include <tqtimer.h>
#include <X11/Xlib.h>
#include <fixx11h.h>
@@ -63,25 +63,25 @@ class KDE_EXPORT Stroke
};
class KDE_EXPORT Gesture
- : public QWidget // not QObject because of x11EventFilter()
+ : public TQWidget // not TQObject because of x11EventFilter()
{
Q_OBJECT
public:
- Gesture( bool enabled_P, QObject* parent_P );
+ Gesture( bool enabled_P, TQObject* parent_P );
virtual ~Gesture();
void enable( bool enable_P );
void set_mouse_button( unsigned int button_P );
void set_timeout( int time_P );
void set_exclude( Windowdef_list* windows_P );
- void register_handler( QObject* receiver_P, const char* slot_P );
- void unregister_handler( QObject* receiver_P, const char* slot_P );
+ void register_handler( TQObject* receiver_P, const char* slot_P );
+ void unregister_handler( TQObject* receiver_P, const char* slot_P );
protected:
virtual bool x11Event( XEvent* ev_P );
private slots:
void stroke_timeout();
void active_window_changed( WId window_P );
signals:
- void handle_gesture( const QString &gesture, WId window );
+ void handle_gesture( const TQString &gesture, WId window );
private:
void update_grab();
void grab_mouse( bool grab_P );
@@ -89,27 +89,27 @@ class KDE_EXPORT Gesture
bool _enabled;
Stroke stroke;
int start_x, start_y;
- QTimer nostroke_timer;
+ TQTimer nostroke_timer;
bool recording;
unsigned int button;
int timeout;
WId gesture_window;
Windowdef_list* exclude;
- QMap< QObject*, bool > handlers; // bool is just a dummy
+ TQMap< TQObject*, bool > handlers; // bool is just a dummy
};
-// Gesture class must be QWidget derived because of x11Event()
-// but it should be QObject owned -> use a QObject proxy that will delete it
+// Gesture class must be TQWidget derived because of x11Event()
+// but it should be TQObject owned -> use a TQObject proxy that will delete it
class DeleteObject
: public QObject
{
Q_OBJECT
public:
- DeleteObject( QWidget* widget_P, QObject* parent_P )
- : QObject( parent_P ), widget( widget_P ) {}
+ DeleteObject( TQWidget* widget_P, TQObject* parent_P )
+ : TQObject( parent_P ), widget( widget_P ) {}
virtual ~DeleteObject() { delete widget; }
private:
- QWidget* widget;
+ TQWidget* widget;
};
diff --git a/khotkeys/shared/input.cpp b/khotkeys/shared/input.cpp
index 021dedf93..f9bfec6d3 100644
--- a/khotkeys/shared/input.cpp
+++ b/khotkeys/shared/input.cpp
@@ -17,13 +17,13 @@
#include "input.h"
#include <assert.h>
-#include <qwidget.h>
+#include <tqwidget.h>
#include <kglobalaccel.h>
#include <kdebug.h>
#include <kapplication.h>
#include <kdeversion.h>
-#include <qtimer.h>
+#include <tqtimer.h>
#include <kkeynative.h>
#include "khotkeysglobal.h"
@@ -38,8 +38,8 @@ namespace KHotKeys
// Kbd
-Kbd::Kbd( bool grabbing_enabled_P, QObject* parent_P )
- : QObject( parent_P )
+Kbd::Kbd( bool grabbing_enabled_P, TQObject* parent_P )
+ : TQObject( parent_P )
{
assert( keyboard_handler == NULL );
keyboard_handler = this;
@@ -77,7 +77,7 @@ void Kbd::activate_receiver( Kbd_receiver* receiver_P )
if( rcv.active )
return;
rcv.active = true;
- for( QValueList< KShortcut >::ConstIterator it( rcv.shortcuts.begin());
+ for( TQValueList< KShortcut >::ConstIterator it( rcv.shortcuts.begin());
it != rcv.shortcuts.end();
++it )
grab_shortcut( *it );
@@ -89,7 +89,7 @@ void Kbd::deactivate_receiver( Kbd_receiver* receiver_P )
if( !rcv.active )
return;
rcv.active = false;
- for( QValueList< KShortcut >::ConstIterator it( rcv.shortcuts.begin());
+ for( TQValueList< KShortcut >::ConstIterator it( rcv.shortcuts.begin());
it != rcv.shortcuts.end();
++it )
ungrab_shortcut( *it );
@@ -104,14 +104,14 @@ void Kbd::grab_shortcut( const KShortcut& shortcut_P )
grabs[ shortcut_P ] = 1;
#if 0
// CHECKME ugly ugly hack
- QString name = ' ' + QString::number( keycode_P );
+ TQString name = ' ' + TQString::number( keycode_P );
kga->insertItem( "", name, keycode_P );
- kga->connectItem( name, this, SLOT( key_slot( int )));
+ kga->connectItem( name, this, TQT_SLOT( key_slot( int )));
#endif
- QString name = ' ' + shortcut_P.toStringInternal();
- kga->insert( name, name, QString::null, shortcut_P, shortcut_P,
- this, SLOT( key_slot( QString )));
- QTimer::singleShot( 0, this, SLOT( update_connections()));
+ TQString name = ' ' + shortcut_P.toStringInternal();
+ kga->insert( name, name, TQString::null, shortcut_P, shortcut_P,
+ this, TQT_SLOT( key_slot( TQString )));
+ TQTimer::singleShot( 0, this, TQT_SLOT( update_connections()));
}
}
@@ -123,13 +123,13 @@ void Kbd::ungrab_shortcut( const KShortcut& shortcut_P )
{
#if 0
// CHECKME workaround for KGlobalAccel::disconnectItem() not working
- kga->setItemEnabled( ' ' + QString::number( keycode_P ), false );
- // kga->disconnectItem( ' ' + QString::number( keycode_P ), NULL, NULL );
- kga->removeItem( ' ' + QString::number( keycode_P ));
+ kga->setItemEnabled( ' ' + TQString::number( keycode_P ), false );
+ // kga->disconnectItem( ' ' + TQString::number( keycode_P ), NULL, NULL );
+ kga->removeItem( ' ' + TQString::number( keycode_P ));
#endif
kga->remove( ' ' + shortcut_P.toStringInternal());
grabs.remove( shortcut_P );
- QTimer::singleShot( 0, this, SLOT( update_connections()));
+ TQTimer::singleShot( 0, this, TQT_SLOT( update_connections()));
}
}
@@ -138,13 +138,13 @@ void Kbd::update_connections()
kga->updateConnections();
}
-void Kbd::key_slot( QString key_P )
+void Kbd::key_slot( TQString key_P )
{
kdDebug( 1217 ) << "Key pressed:" << key_P << endl;
KShortcut shortcut( key_P );
if( !grabs.contains( shortcut ))
return;
- for( QMap< Kbd_receiver*, Receiver_data >::ConstIterator it = receivers.begin();
+ for( TQMap< Kbd_receiver*, Receiver_data >::ConstIterator it = receivers.begin();
it != receivers.end();
++it )
if( ( *it ).shortcuts.contains( shortcut ) && ( *it ).active
diff --git a/khotkeys/shared/input.h b/khotkeys/shared/input.h
index 1983bcf0b..22df89284 100644
--- a/khotkeys/shared/input.h
+++ b/khotkeys/shared/input.h
@@ -11,11 +11,11 @@
#ifndef _INPUT_H_
#define _INPUT_H_
-#include <qobject.h>
-#include <qwindowdefs.h>
-#include <qmap.h>
-#include <qwidget.h>
-#include <qvaluelist.h>
+#include <tqobject.h>
+#include <tqwindowdefs.h>
+#include <tqmap.h>
+#include <tqwidget.h>
+#include <tqvaluelist.h>
#include <kshortcut.h>
#include <X11/X.h>
@@ -37,7 +37,7 @@ class Kbd
{
Q_OBJECT
public:
- Kbd( bool grabbing_enabled_P, QObject* parent_P );
+ Kbd( bool grabbing_enabled_P, TQObject* parent_P );
virtual ~Kbd();
void insert_item( const KShortcut& shortcut_P, Kbd_receiver* receiver_P );
void remove_item( const KShortcut& shortcut_P, Kbd_receiver* receiver_P );
@@ -49,17 +49,17 @@ class Kbd
void grab_shortcut( const KShortcut& shortcut_P );
void ungrab_shortcut( const KShortcut& shortcut_P );
private slots:
- void key_slot( QString key_P );
+ void key_slot( TQString key_P );
void update_connections();
private:
struct Receiver_data
{
Receiver_data();
- QValueList< KShortcut > shortcuts;
+ TQValueList< KShortcut > shortcuts;
bool active;
};
- QMap< Kbd_receiver*, Receiver_data > receivers;
- QMap< KShortcut, int > grabs;
+ TQMap< Kbd_receiver*, Receiver_data > receivers;
+ TQMap< KShortcut, int > grabs;
KGlobalAccel* kga;
};
diff --git a/khotkeys/shared/khlistbox.cpp b/khotkeys/shared/khlistbox.cpp
index 694fb658b..ff6d96221 100644
--- a/khotkeys/shared/khlistbox.cpp
+++ b/khotkeys/shared/khlistbox.cpp
@@ -21,19 +21,19 @@
namespace KHotKeys
{
-KHListBox::KHListBox( QWidget* parent_P, const char* name_P )
- : QListBox( parent_P, name_P ), saved_current_item( NULL ),
+KHListBox::KHListBox( TQWidget* parent_P, const char* name_P )
+ : TQListBox( parent_P, name_P ), saved_current_item( NULL ),
in_clear( false ), force_select( false )
{
- connect( this, SIGNAL( selectionChanged( QListBoxItem* )),
- SLOT( slot_selection_changed( QListBoxItem* )));
- connect( this, SIGNAL( currentChanged( QListBoxItem* )),
- SLOT( slot_current_changed( QListBoxItem* )));
+ connect( this, TQT_SIGNAL( selectionChanged( TQListBoxItem* )),
+ TQT_SLOT( slot_selection_changed( TQListBoxItem* )));
+ connect( this, TQT_SIGNAL( currentChanged( TQListBoxItem* )),
+ TQT_SLOT( slot_current_changed( TQListBoxItem* )));
// CHECKME grrr
- connect( this, SIGNAL( selectionChanged()),
- SLOT( slot_selection_changed()));
- connect( &insert_select_timer, SIGNAL( timeout()),
- SLOT( slot_insert_select()));
+ connect( this, TQT_SIGNAL( selectionChanged()),
+ TQT_SLOT( slot_selection_changed()));
+ connect( &insert_select_timer, TQT_SIGNAL( timeout()),
+ TQT_SLOT( slot_insert_select()));
}
void KHListBox::slot_selection_changed()
@@ -44,7 +44,7 @@ void KHListBox::slot_selection_changed()
setSelected( saved_current_item, true );
}
-void KHListBox::slot_selection_changed( QListBoxItem* item_P )
+void KHListBox::slot_selection_changed( TQListBoxItem* item_P )
{
if( item_P == saved_current_item )
return;
@@ -53,7 +53,7 @@ void KHListBox::slot_selection_changed( QListBoxItem* item_P )
emit current_changed( saved_current_item );
}
-void KHListBox::slot_current_changed( QListBoxItem* item_P )
+void KHListBox::slot_current_changed( TQListBoxItem* item_P )
{
insert_select_timer.stop();
if( item_P == saved_current_item )
@@ -67,19 +67,19 @@ void KHListBox::slot_current_changed( QListBoxItem* item_P )
void KHListBox::clear()
{
in_clear = true;
- QListBox::clear();
+ TQListBox::clear();
in_clear = false;
slot_selection_changed( NULL );
}
// neni virtual :(( a vubec nefunguje
-void KHListBox::insertItem( QListBoxItem* item_P )
+void KHListBox::insertItem( TQListBoxItem* item_P )
{
bool set = false;
if( !in_clear )
set = count() == 0;
- QListBox::insertItem( item_P );
+ TQListBox::insertItem( item_P );
if( set && force_select )
{
bool block = signalsBlocked();
@@ -90,7 +90,7 @@ void KHListBox::insertItem( QListBoxItem* item_P )
}
}
-// items are often inserted using the QListBoxItem constructor,
+// items are often inserted using the TQListBoxItem constructor,
// which means that a derived class are not yet fully created
void KHListBox::slot_insert_select()
{
diff --git a/khotkeys/shared/khlistbox.h b/khotkeys/shared/khlistbox.h
index 95bd32963..ddb988c36 100644
--- a/khotkeys/shared/khlistbox.h
+++ b/khotkeys/shared/khlistbox.h
@@ -11,7 +11,7 @@
#ifndef _KHLISTBOX_H_
#define _KHLISTBOX_H_
-#include <qtimer.h>
+#include <tqtimer.h>
#include <klistbox.h>
@@ -24,23 +24,23 @@ class KHListBox
Q_OBJECT
Q_PROPERTY( bool forceSelect READ forceSelect WRITE setForceSelect )
public:
- KHListBox( QWidget* parent_P, const char* name_P = NULL );
+ KHListBox( TQWidget* parent_P, const char* name_P = NULL );
virtual void clear();
- virtual void insertItem( QListBoxItem* item_P );
+ virtual void insertItem( TQListBoxItem* item_P );
bool forceSelect() const;
void setForceSelect( bool force_P );
signals:
- void current_changed( QListBoxItem* item_P );
+ void current_changed( TQListBoxItem* item_P );
private slots:
- void slot_selection_changed( QListBoxItem* item_P );
+ void slot_selection_changed( TQListBoxItem* item_P );
void slot_selection_changed();
- void slot_current_changed( QListBoxItem* item_P );
+ void slot_current_changed( TQListBoxItem* item_P );
void slot_insert_select();
private:
- QListBoxItem* saved_current_item;
+ TQListBoxItem* saved_current_item;
bool in_clear;
bool force_select;
- QTimer insert_select_timer;
+ TQTimer insert_select_timer;
};
//***************************************************************************
diff --git a/khotkeys/shared/khlistview.cpp b/khotkeys/shared/khlistview.cpp
index 45a1d04f9..2afa9db17 100644
--- a/khotkeys/shared/khlistview.cpp
+++ b/khotkeys/shared/khlistview.cpp
@@ -21,19 +21,19 @@
namespace KHotKeys
{
-KHListView::KHListView( QWidget* parent_P, const char* name_P )
+KHListView::KHListView( TQWidget* parent_P, const char* name_P )
: KListView( parent_P, name_P ), saved_current_item( NULL ),
in_clear( false ), ignore( false ), force_select( false )
{
- connect( this, SIGNAL( selectionChanged( QListViewItem* )),
- SLOT( slot_selection_changed( QListViewItem* )));
- connect( this, SIGNAL( currentChanged( QListViewItem* )),
- SLOT( slot_current_changed( QListViewItem* )));
+ connect( this, TQT_SIGNAL( selectionChanged( TQListViewItem* )),
+ TQT_SLOT( slot_selection_changed( TQListViewItem* )));
+ connect( this, TQT_SIGNAL( currentChanged( TQListViewItem* )),
+ TQT_SLOT( slot_current_changed( TQListViewItem* )));
// CHECKME grrr
- connect( this, SIGNAL( selectionChanged()),
- SLOT( slot_selection_changed()));
- connect( &insert_select_timer, SIGNAL( timeout()),
- SLOT( slot_insert_select()));
+ connect( this, TQT_SIGNAL( selectionChanged()),
+ TQT_SLOT( slot_selection_changed()));
+ connect( &insert_select_timer, TQT_SIGNAL( timeout()),
+ TQT_SLOT( slot_insert_select()));
}
void KHListView::slot_selection_changed()
@@ -46,7 +46,7 @@ void KHListView::slot_selection_changed()
setSelected( saved_current_item, true );
}
-void KHListView::slot_selection_changed( QListViewItem* item_P )
+void KHListView::slot_selection_changed( TQListViewItem* item_P )
{
if( ignore )
return;
@@ -57,7 +57,7 @@ void KHListView::slot_selection_changed( QListViewItem* item_P )
emit current_changed( saved_current_item );
}
-void KHListView::slot_current_changed( QListViewItem* item_P )
+void KHListView::slot_current_changed( TQListViewItem* item_P )
{
if( ignore )
return;
@@ -77,7 +77,7 @@ void KHListView::clear()
slot_selection_changed( NULL );
}
-void KHListView::insertItem( QListViewItem* item_P )
+void KHListView::insertItem( TQListViewItem* item_P )
{
bool set = false;
if( !in_clear )
@@ -100,7 +100,7 @@ void KHListView::clearSelection()
slot_current_changed( currentItem());
}
-// items are often inserted using the QListViewItem constructor,
+// items are often inserted using the TQListViewItem constructor,
// which means that a derived class are not yet fully created
void KHListView::slot_insert_select()
{
@@ -109,7 +109,7 @@ void KHListView::slot_insert_select()
slot_current_changed( currentItem());
}
-void KHListView::contentsDropEvent( QDropEvent* e )
+void KHListView::contentsDropEvent( TQDropEvent* e )
{
bool save_ignore = ignore;
ignore = true;
diff --git a/khotkeys/shared/khlistview.h b/khotkeys/shared/khlistview.h
index 69986299d..c475b2d6c 100644
--- a/khotkeys/shared/khlistview.h
+++ b/khotkeys/shared/khlistview.h
@@ -11,7 +11,7 @@
#ifndef _KHLISTVIEW_H_
#define _KHLISTVIEW_H_
-#include <qtimer.h>
+#include <tqtimer.h>
#include <klistview.h>
#include <kdemacros.h>
@@ -25,27 +25,27 @@ class KDE_EXPORT KHListView
Q_OBJECT
Q_PROPERTY( bool forceSelect READ forceSelect WRITE setForceSelect )
public:
- KHListView( QWidget* parent_P, const char* name_P = NULL );
+ KHListView( TQWidget* parent_P, const char* name_P = NULL );
virtual void clear();
- virtual void insertItem( QListViewItem* item_P );
+ virtual void insertItem( TQListViewItem* item_P );
virtual void clearSelection();
bool forceSelect() const;
void setForceSelect( bool force_P );
signals:
- void current_changed( QListViewItem* item_P );
+ void current_changed( TQListViewItem* item_P );
protected:
- virtual void contentsDropEvent (QDropEvent*);
+ virtual void contentsDropEvent (TQDropEvent*);
private slots:
- void slot_selection_changed( QListViewItem* item_P );
+ void slot_selection_changed( TQListViewItem* item_P );
void slot_selection_changed();
- void slot_current_changed( QListViewItem* item_P );
+ void slot_current_changed( TQListViewItem* item_P );
void slot_insert_select();
private:
- QListViewItem* saved_current_item;
+ TQListViewItem* saved_current_item;
bool in_clear;
bool ignore;
bool force_select;
- QTimer insert_select_timer;
+ TQTimer insert_select_timer;
};
//***************************************************************************
diff --git a/khotkeys/shared/khotkeysglobal.cpp b/khotkeys/shared/khotkeysglobal.cpp
index 2b430fc8c..4c6b8360c 100644
--- a/khotkeys/shared/khotkeysglobal.cpp
+++ b/khotkeys/shared/khotkeysglobal.cpp
@@ -35,7 +35,7 @@ Kbd* keyboard_handler;
Windows* windows_handler;
static bool _khotkeys_active = false;
-void init_global_data( bool active_P, QObject* owner_P )
+void init_global_data( bool active_P, TQObject* owner_P )
{
assert( keyboard_handler == NULL );
assert( windows_handler == NULL );
@@ -59,15 +59,15 @@ bool khotkeys_active()
// does the opposite of KStandardDirs::findResource() i.e. e.g.
// "/opt/kde2/share/applnk/System/konsole.desktop" -> "System/konsole.desktop"
-QString get_menu_entry_from_path( const QString& path_P )
+TQString get_menu_entry_from_path( const TQString& path_P )
{
- QStringList dirs = KGlobal::dirs()->resourceDirs( "apps" );
- for( QStringList::ConstIterator it = dirs.begin();
+ TQStringList dirs = KGlobal::dirs()->resourceDirs( "apps" );
+ for( TQStringList::ConstIterator it = dirs.begin();
it != dirs.end();
++it )
if( path_P.find( *it ) == 0 )
{
- QString ret = path_P;
+ TQString ret = path_P;
ret.remove( 0, (*it).length());
if( ret[ 0 ] == '/' )
ret.remove( 0, 1 );
diff --git a/khotkeys/shared/khotkeysglobal.h b/khotkeys/shared/khotkeysglobal.h
index 873473e0f..9ca469584 100644
--- a/khotkeys/shared/khotkeysglobal.h
+++ b/khotkeys/shared/khotkeysglobal.h
@@ -18,7 +18,7 @@
//#define KHOTKEYS_DEBUG
//#endif
-#include <qstring.h>
+#include <tqstring.h>
#include <klocale.h>
@@ -41,9 +41,9 @@ extern Windows* windows_handler;
KDE_EXPORT bool khotkeys_active();
KDE_EXPORT void khotkeys_set_active( bool active_P );
-QString get_menu_entry_from_path( const QString& path_P );
+TQString get_menu_entry_from_path( const TQString& path_P );
-KDE_EXPORT void init_global_data( bool active_P, QObject* owner_P );
+KDE_EXPORT void init_global_data( bool active_P, TQObject* owner_P );
const char* const MENU_EDITOR_ENTRIES_GROUP_NAME = I18N_NOOP( "Menu Editor entries" );
diff --git a/khotkeys/shared/settings.cpp b/khotkeys/shared/settings.cpp
index 829c8521a..fdab2be56 100644
--- a/khotkeys/shared/settings.cpp
+++ b/khotkeys/shared/settings.cpp
@@ -60,7 +60,7 @@ bool Settings::read_settings( KConfig& cfg_P, bool include_disabled_P, ImportTyp
already_imported = cfg_P.readListEntry( "AlreadyImported" );
else
{
- QString import_id = cfg_P.readEntry( "ImportId" );
+ TQString import_id = cfg_P.readEntry( "ImportId" );
if( !import_id.isEmpty())
{
if( already_imported.contains( import_id ))
@@ -122,8 +122,8 @@ void Settings::write_settings()
{
KConfig cfg( KHOTKEYS_CONFIG_FILE, false );
// CHECKME smazat stare sekce ?
- QStringList groups = cfg.groupList();
- for( QStringList::ConstIterator it = groups.begin();
+ TQStringList groups = cfg.groupList();
+ for( TQStringList::ConstIterator it = groups.begin();
it != groups.end();
++it )
cfg.deleteGroup( *it );
@@ -157,7 +157,7 @@ void Settings::write_settings()
int Settings::write_actions_recursively_v2( KConfig& cfg_P, Action_data_group* parent_P, bool enabled_P )
{
int enabled_cnt = 0;
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int cnt = 0;
for( Action_data_group::Iterator it = parent_P->first_child();
it;
@@ -166,7 +166,7 @@ int Settings::write_actions_recursively_v2( KConfig& cfg_P, Action_data_group* p
++cnt;
if( enabled_P && (*it)->enabled( true ))
++enabled_cnt;
- cfg_P.setGroup( save_cfg_group + "_" + QString::number( cnt ));
+ cfg_P.setGroup( save_cfg_group + "_" + TQString::number( cnt ));
( *it )->cfg_write( cfg_P );
Action_data_group* grp = dynamic_cast< Action_data_group* >( *it );
if( grp != NULL )
@@ -186,13 +186,13 @@ void Settings::read_settings_v2( KConfig& cfg_P, bool include_disabled_P )
void Settings::read_actions_recursively_v2( KConfig& cfg_P, Action_data_group* parent_P,
bool include_disabled_P )
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int cnt = cfg_P.readNumEntry( "DataCount" );
for( int i = 1;
i <= cnt;
++i )
{
- cfg_P.setGroup( save_cfg_group + "_" + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + "_" + TQString::number( i ));
if( include_disabled_P || Action_data_base::cfg_is_enabled( cfg_P ))
{
Action_data_base* new_action = Action_data_base::create_cfg_read( cfg_P, parent_P );
@@ -226,17 +226,17 @@ void Settings::read_settings_v1( KConfig& cfg_P )
sect <= sections;
++sect )
{
- QString group = QString( "Section%1" ).arg( sect );
+ TQString group = TQString( "Section%1" ).arg( sect );
if( !cfg_P.hasGroup( group ))
continue;
cfg_P.setGroup( group );
- QString name = cfg_P.readEntry( "Name" );
+ TQString name = cfg_P.readEntry( "Name" );
if( name.isNull() )
continue;
- QString shortcut = cfg_P.readEntry( "Shortcut" );
+ TQString shortcut = cfg_P.readEntry( "Shortcut" );
if( shortcut.isNull() )
continue;
- QString run = cfg_P.readEntry( "Run" );
+ TQString run = cfg_P.readEntry( "Run" );
if( run.isNull() )
continue;
bool menuentry = cfg_P.readBoolEntry( "MenuEntry", false );
diff --git a/khotkeys/shared/settings.h b/khotkeys/shared/settings.h
index cf05dcd31..fa6754160 100644
--- a/khotkeys/shared/settings.h
+++ b/khotkeys/shared/settings.h
@@ -48,7 +48,7 @@ class KDE_EXPORT Settings
void read_actions_recursively_v2( KConfig& cfg_P, Action_data_group* parent_P,
bool include_disabled_P );
private:
- QStringList already_imported;
+ TQStringList already_imported;
KHOTKEYS_DISABLE_COPY( Settings );
};
diff --git a/khotkeys/shared/sound.cpp b/khotkeys/shared/sound.cpp
index e8d4191eb..c90eb2e02 100644
--- a/khotkeys/shared/sound.cpp
+++ b/khotkeys/shared/sound.cpp
@@ -19,8 +19,8 @@
***************************************************************************/
#include "sound.h"
-#include <qfile.h>
-#include <qdatastream.h>
+#include <tqfile.h>
+#include <tqdatastream.h>
#include <kdebug.h>
@@ -47,18 +47,18 @@ Sound::~Sound()
#define ABS(X) ( (X>0) ? X : -X )
-void Sound::load(const QString& filename)
+void Sound::load(const TQString& filename)
{
kdDebug() << k_funcinfo << filename << endl;
- data=QMemArray<Q_INT32>();
- QFile file(filename);
+ data=TQMemArray<Q_INT32>();
+ TQFile file(filename);
if(!file.open(IO_ReadOnly))
{
kdWarning() << k_funcinfo <<"unable to open file" << endl;
return;
}
- QDataStream stream(&file);
- stream.setByteOrder( QDataStream::LittleEndian );
+ TQDataStream stream(&file);
+ stream.setByteOrder( TQDataStream::LittleEndian );
Q_INT32 magic;
MAGIC("RIFF");
@@ -74,7 +74,7 @@ void Sound::load(const QString& filename)
READ_FROM_STREAM(Q_UINT16,BlockAlign);
READ_FROM_STREAM(Q_UINT16,BitsPerSample);
MAGIC("data");
- READ_FROM_STREAM(QByteArray,SoundData);
+ READ_FROM_STREAM(TQByteArray,SoundData);
NumberOfChannels=1; //Wav i play are broken
file.close();
@@ -105,27 +105,27 @@ void Sound::load(const QString& filename)
}
/* static int q=0;
- QString name="test" + QString::number(q++) + ".wav";
+ TQString name="test" + TQString::number(q++) + ".wav";
save(name);*/
}
#define SMAGIC(CH) { stream << ( Q_INT32) ( (CH)[0] | (CH)[1]<<8 | (CH)[2]<< 16 | (CH)[3] << 24 ) ; }
-void Sound::save(const QString& filename) const
+void Sound::save(const TQString& filename) const
{
kdDebug( 1217 ) << k_funcinfo << filename << " - " << data.size() << endl;
- QFile file(filename);
+ TQFile file(filename);
if(!file.open(IO_WriteOnly))
{
kdWarning() << k_funcinfo <<"unable to open file" << endl;
return;
}
- QDataStream stream(&file);
- stream.setByteOrder( QDataStream::LittleEndian );
+ TQDataStream stream(&file);
+ stream.setByteOrder( TQDataStream::LittleEndian );
- QByteArray SoundData(data.size()*2);
+ TQByteArray SoundData(data.size()*2);
for(unsigned long int f=0;f<data.size();f++)
{
@@ -159,7 +159,7 @@ void Sound::save(const QString& filename) const
//READ_FROM_STREAM(Q_UINT16,BitsPerSample);
stream << (Q_UINT16)(16);
SMAGIC("data");
- //READ_FROM_STREAM(QByteArray,SoundData);
+ //READ_FROM_STREAM(TQByteArray,SoundData);
stream << SoundData;
file.close();
@@ -170,10 +170,10 @@ void Sound::save(const QString& filename) const
#if 0
-void Sound::load(const QString& filename)
+void Sound::load(const TQString& filename)
{
cout << "saout \n";
- data=QMemArray<long unsigned int>();
+ data=TQMemArray<long unsigned int>();
static const int BUFFER_LEN = 4096;
//code from libtunepimp
diff --git a/khotkeys/shared/sound.h b/khotkeys/shared/sound.h
index 1a38f182f..2c2d97d93 100644
--- a/khotkeys/shared/sound.h
+++ b/khotkeys/shared/sound.h
@@ -20,8 +20,8 @@
#ifndef SOUND_H
#define SOUND_H
-#include <qmemarray.h>
-#include <qstring.h>
+#include <tqmemarray.h>
+#include <tqstring.h>
#include <kdemacros.h>
/**
@@ -32,8 +32,8 @@ public:
Sound();
~Sound();
- void load(const QString &filename);
- void save(const QString &filename) const;
+ void load(const TQString &filename);
+ void save(const TQString &filename) const;
unsigned int size() const
{
@@ -50,7 +50,7 @@ public:
return _fs;
}
- QMemArray<Q_INT32> data;
+ TQMemArray<Q_INT32> data;
Q_UINT32 max;
uint _fs;
};
diff --git a/khotkeys/shared/soundrecorder.cpp b/khotkeys/shared/soundrecorder.cpp
index fc2031113..266bbc7ce 100644
--- a/khotkeys/shared/soundrecorder.cpp
+++ b/khotkeys/shared/soundrecorder.cpp
@@ -27,7 +27,7 @@
#include <kdebug.h>
#include <klocale.h>
-#include <qtimer.h>
+#include <tqtimer.h>
#include <klibloader.h>
#include "khotkeysglobal.h"
@@ -47,7 +47,7 @@ bool SoundRecorder::init( KLibrary* lib )
return create_fun != NULL;
}
-SoundRecorder* SoundRecorder::create( QObject* parent, const char* name )
+SoundRecorder* SoundRecorder::create( TQObject* parent, const char* name )
{
#ifdef HAVE_ARTS
if( create_fun != NULL )
@@ -56,7 +56,7 @@ SoundRecorder* SoundRecorder::create( QObject* parent, const char* name )
return new SoundRecorder( parent, name );
}
-SoundRecorder::SoundRecorder(QObject *parent, const char *name) : QObject(parent, name) {}
+SoundRecorder::SoundRecorder(TQObject *parent, const char *name) : TQObject(parent, name) {}
SoundRecorder::~SoundRecorder()
{
diff --git a/khotkeys/shared/soundrecorder.h b/khotkeys/shared/soundrecorder.h
index d9539c4c5..c00f73527 100644
--- a/khotkeys/shared/soundrecorder.h
+++ b/khotkeys/shared/soundrecorder.h
@@ -20,7 +20,7 @@
#ifndef RECORDER_H
#define RECORDER_H
-#include <qobject.h>
+#include <tqobject.h>
#include "sound.h"
#include <kdemacros.h>
@@ -38,7 +38,7 @@ class KDE_EXPORT SoundRecorder : public QObject
{
Q_OBJECT
public:
- static SoundRecorder* create( QObject* parent = 0, const char* name = 0 );
+ static SoundRecorder* create( TQObject* parent = 0, const char* name = 0 );
virtual ~SoundRecorder();
virtual void start();
@@ -51,8 +51,8 @@ signals:
void recorded(const Sound&);
protected:
- SoundRecorder(QObject *parent = 0, const char *name = 0);
- typedef SoundRecorder* (*create_ptr)( QObject*, const char* );
+ SoundRecorder(TQObject *parent = 0, const char *name = 0);
+ typedef SoundRecorder* (*create_ptr)( TQObject*, const char* );
private:
static create_ptr create_fun;
};
diff --git a/khotkeys/shared/triggers.cpp b/khotkeys/shared/triggers.cpp
index 1febedfa9..7cac2b98c 100644
--- a/khotkeys/shared/triggers.cpp
+++ b/khotkeys/shared/triggers.cpp
@@ -46,7 +46,7 @@ void Trigger::cfg_write( KConfig& cfg_P ) const
Trigger* Trigger::create_cfg_read( KConfig& cfg_P, Action_data* data_P )
{
- QString type = cfg_P.readEntry( "Type" );
+ TQString type = cfg_P.readEntry( "Type" );
if( type == "SHORTCUT" || type == "SINGLE_SHORTCUT" )
return new Shortcut_trigger( cfg_P, data_P );
if( type == "WINDOW" )
@@ -63,17 +63,17 @@ Trigger* Trigger::create_cfg_read( KConfig& cfg_P, Action_data* data_P )
// Trigger_list
Trigger_list::Trigger_list( KConfig& cfg_P, Action_data* data_P )
- : QPtrList< Trigger >()
+ : TQPtrList< Trigger >()
{
setAutoDelete( true );
_comment = cfg_P.readEntry( "Comment" );
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int cnt = cfg_P.readNumEntry( "TriggersCount", 0 );
for( int i = 0;
i < cnt;
++i )
{
- cfg_P.setGroup( save_cfg_group + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + TQString::number( i ));
Trigger* trigger = Trigger::create_cfg_read( cfg_P, data_P );
if( trigger )
append( trigger );
@@ -84,13 +84,13 @@ Trigger_list::Trigger_list( KConfig& cfg_P, Action_data* data_P )
void Trigger_list::cfg_write( KConfig& cfg_P ) const
{
cfg_P.writeEntry( "Comment", comment());
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int i = 0;
for( Iterator it( *this );
it;
++it, ++i )
{
- cfg_P.setGroup( save_cfg_group + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + TQString::number( i ));
it.current()->cfg_write( cfg_P );
}
cfg_P.setGroup( save_cfg_group );
@@ -147,7 +147,7 @@ Shortcut_trigger* Shortcut_trigger::copy( Action_data* data_P ) const
return new Shortcut_trigger( data_P ? data_P : data, shortcut());
}
-const QString Shortcut_trigger::description() const
+const TQString Shortcut_trigger::description() const
{
// CHECKME vice mods
return i18n( "Shortcut trigger: " ) + _shortcut.toString();
@@ -179,7 +179,7 @@ Window_trigger::Window_trigger( KConfig& cfg_P, Action_data* data_P )
: Trigger( cfg_P, data_P ), active( false )
{
// kdDebug( 1217 ) << "Window_trigger" << endl;
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Windows" );
_windows = new Windowdef_list( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -197,13 +197,13 @@ Window_trigger::~Window_trigger()
void Window_trigger::init()
{
kdDebug( 1217 ) << "Window_trigger::init()" << endl;
- connect( windows_handler, SIGNAL( window_added( WId )), this, SLOT( window_added( WId )));
- connect( windows_handler, SIGNAL( window_removed( WId )), this, SLOT( window_removed( WId )));
+ connect( windows_handler, TQT_SIGNAL( window_added( WId )), this, TQT_SLOT( window_added( WId )));
+ connect( windows_handler, TQT_SIGNAL( window_removed( WId )), this, TQT_SLOT( window_removed( WId )));
if( window_actions & ( WINDOW_ACTIVATES | WINDOW_DEACTIVATES /*| WINDOW_DISAPPEARS*/ ))
- connect( windows_handler, SIGNAL( active_window_changed( WId )),
- this, SLOT( active_window_changed( WId )));
- connect( windows_handler, SIGNAL( window_changed( WId, unsigned int )),
- this, SLOT( window_changed( WId, unsigned int )));
+ connect( windows_handler, TQT_SIGNAL( active_window_changed( WId )),
+ this, TQT_SLOT( active_window_changed( WId )));
+ connect( windows_handler, TQT_SIGNAL( window_changed( WId, unsigned int )),
+ this, TQT_SLOT( window_changed( WId, unsigned int )));
}
void Window_trigger::activate( bool activate_P )
@@ -293,7 +293,7 @@ void Window_trigger::window_changed( WId window_P, unsigned int dirty_P )
void Window_trigger::cfg_write( KConfig& cfg_P ) const
{
base::cfg_write( cfg_P );
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
cfg_P.setGroup( save_cfg_group + "Windows" );
windows()->cfg_write( cfg_P );
cfg_P.setGroup( save_cfg_group );
@@ -313,14 +313,14 @@ Trigger* Window_trigger::copy( Action_data* data_P ) const
return ret;
}
-const QString Window_trigger::description() const
+const TQString Window_trigger::description() const
{
return i18n( "Window trigger: " ) + windows()->comment();
}
// Gesture_trigger
-Gesture_trigger::Gesture_trigger( Action_data* data_P, const QString &gesturecode_P )
+Gesture_trigger::Gesture_trigger( Action_data* data_P, const TQString &gesturecode_P )
: Trigger( data_P ), _gesturecode( gesturecode_P )
{
}
@@ -333,7 +333,7 @@ Gesture_trigger::Gesture_trigger( KConfig& cfg_P, Action_data* data_P )
Gesture_trigger::~Gesture_trigger()
{
- gesture_handler->unregister_handler( this, SLOT( handle_gesture( const QString&, WId )));
+ gesture_handler->unregister_handler( this, TQT_SLOT( handle_gesture( const TQString&, WId )));
}
void Gesture_trigger::cfg_write( KConfig& cfg_P ) const
@@ -349,12 +349,12 @@ Trigger* Gesture_trigger::copy( Action_data* data_P ) const
return new Gesture_trigger( data_P ? data_P : data, gesturecode());
}
-const QString Gesture_trigger::description() const
+const TQString Gesture_trigger::description() const
{
return i18n( "Gesture trigger: " ) + gesturecode();
}
-void Gesture_trigger::handle_gesture( const QString &gesture_P, WId window_P )
+void Gesture_trigger::handle_gesture( const TQString &gesture_P, WId window_P )
{
if( gesturecode() == gesture_P )
{
@@ -366,15 +366,15 @@ void Gesture_trigger::handle_gesture( const QString &gesture_P, WId window_P )
void Gesture_trigger::activate( bool activate_P )
{
if( activate_P )
- gesture_handler->register_handler( this, SLOT( handle_gesture( const QString&, WId )));
+ gesture_handler->register_handler( this, TQT_SLOT( handle_gesture( const TQString&, WId )));
else
- gesture_handler->unregister_handler( this, SLOT( handle_gesture( const QString&, WId )));
+ gesture_handler->unregister_handler( this, TQT_SLOT( handle_gesture( const TQString&, WId )));
}
// Voice_trigger
- Voice_trigger::Voice_trigger( Action_data* data_P, const QString &Voicecode_P, const VoiceSignature& signature1_P, const VoiceSignature& signature2_P )
+ Voice_trigger::Voice_trigger( Action_data* data_P, const TQString &Voicecode_P, const VoiceSignature& signature1_P, const VoiceSignature& signature2_P )
: Trigger( data_P ), _voicecode( Voicecode_P )
{
_voicesignature[0]=signature1_P;
@@ -409,7 +409,7 @@ Trigger* Voice_trigger::copy( Action_data* data_P ) const
return new Voice_trigger( data_P ? data_P : data, voicecode(), voicesignature(1) , voicesignature(2) );
}
-const QString Voice_trigger::description() const
+const TQString Voice_trigger::description() const
{
return i18n( "Voice trigger: " ) + voicecode();
}
diff --git a/khotkeys/shared/triggers.h b/khotkeys/shared/triggers.h
index 2f921beff..9a8fe6bee 100644
--- a/khotkeys/shared/triggers.h
+++ b/khotkeys/shared/triggers.h
@@ -11,9 +11,9 @@
#ifndef _TRIGGERS_H_
#define _TRIGGERS_H_
-#include <qptrlist.h>
-#include <qtimer.h>
-#include <qmap.h>
+#include <tqptrlist.h>
+#include <tqtimer.h>
+#include <tqmap.h>
#include <kdemacros.h>
#include "khotkeysglobal.h"
@@ -37,7 +37,7 @@ class KDE_EXPORT Trigger
virtual ~Trigger();
virtual void cfg_write( KConfig& cfg_P ) const = 0;
virtual Trigger* copy( Action_data* data_P ) const = 0;
- virtual const QString description() const = 0;
+ virtual const TQString description() const = 0;
static Trigger* create_cfg_read( KConfig& cfg_P, Action_data* data_P );
virtual void activate( bool activate_P ) = 0;
protected:
@@ -46,18 +46,18 @@ class KDE_EXPORT Trigger
};
class KDE_EXPORT Trigger_list
- : public QPtrList< Trigger >
+ : public TQPtrList< Trigger >
{
public:
- Trigger_list( const QString& comment_P ); // CHECKME nebo i data ?
+ Trigger_list( const TQString& comment_P ); // CHECKME nebo i data ?
Trigger_list( KConfig& cfg_P, Action_data* data_P );
void activate( bool activate_P );
void cfg_write( KConfig& cfg_P ) const;
- typedef QPtrListIterator< Trigger > Iterator;
- const QString& comment() const;
+ typedef TQPtrListIterator< Trigger > Iterator;
+ const TQString& comment() const;
Trigger_list* copy( Action_data* data_P ) const;
private:
- QString _comment;
+ TQString _comment;
KHOTKEYS_DISABLE_COPY( Trigger_list );
};
@@ -71,7 +71,7 @@ class KDE_EXPORT Shortcut_trigger
virtual ~Shortcut_trigger();
virtual void cfg_write( KConfig& cfg_P ) const;
virtual Shortcut_trigger* copy( Action_data* data_P ) const;
- virtual const QString description() const;
+ virtual const TQString description() const;
const KShortcut& shortcut() const;
virtual bool handle_key( const KShortcut& shortcut_P );
virtual void activate( bool activate_P );
@@ -80,7 +80,7 @@ class KDE_EXPORT Shortcut_trigger
};
class KDE_EXPORT Window_trigger
- : public QObject, public Trigger
+ : public TQObject, public Trigger
{
Q_OBJECT
typedef Trigger base;
@@ -101,7 +101,7 @@ class KDE_EXPORT Window_trigger
#else
virtual Trigger* copy( Action_data* data_P ) const;
#endif
- virtual const QString description() const;
+ virtual const TQString description() const;
const Windowdef_list* windows() const;
bool triggers_on( window_action_t w_action_P ) const;
virtual void activate( bool activate_P );
@@ -109,7 +109,7 @@ class KDE_EXPORT Window_trigger
Windowdef_list* _windows;
int window_actions;
void init();
- typedef QMap< WId, bool > Windows_map;
+ typedef TQMap< WId, bool > Windows_map;
Windows_map existing_windows;
WId last_active_window;
protected slots:
@@ -122,45 +122,45 @@ class KDE_EXPORT Window_trigger
};
class KDE_EXPORT Gesture_trigger
- : public QObject, public Trigger
+ : public TQObject, public Trigger
{
Q_OBJECT
typedef Trigger base;
public:
- Gesture_trigger( Action_data* data_P, const QString& gesture_P );
+ Gesture_trigger( Action_data* data_P, const TQString& gesture_P );
Gesture_trigger( KConfig& cfg_P, Action_data* data_P );
virtual ~Gesture_trigger();
virtual void cfg_write( KConfig& cfg_P ) const;
virtual Trigger* copy( Action_data* data_P ) const;
- virtual const QString description() const;
- const QString& gesturecode() const;
+ virtual const TQString description() const;
+ const TQString& gesturecode() const;
virtual void activate( bool activate_P );
protected slots:
- void handle_gesture( const QString& gesture_P, WId window_P );
+ void handle_gesture( const TQString& gesture_P, WId window_P );
private:
- QString _gesturecode;
+ TQString _gesturecode;
};
class KDE_EXPORT Voice_trigger
- : public QObject, public Trigger
+ : public TQObject, public Trigger
{
Q_OBJECT
typedef Trigger base;
public:
- Voice_trigger( Action_data* data_P, const QString& Voice_P, const VoiceSignature & signature1_P, const VoiceSignature & signature2_P );
+ Voice_trigger( Action_data* data_P, const TQString& Voice_P, const VoiceSignature & signature1_P, const VoiceSignature & signature2_P );
Voice_trigger( KConfig& cfg_P, Action_data* data_P );
virtual ~Voice_trigger();
virtual void cfg_write( KConfig& cfg_P ) const;
virtual Trigger* copy( Action_data* data_P ) const;
- virtual const QString description() const;
- const QString& voicecode() const;
+ virtual const TQString description() const;
+ const TQString& voicecode() const;
virtual void activate( bool activate_P );
VoiceSignature voicesignature( int ech ) const;
public slots:
void handle_Voice( );
private:
- QString _voicecode;
+ TQString _voicecode;
VoiceSignature _voicesignature[2];
};
@@ -191,14 +191,14 @@ Trigger::~Trigger()
// Trigger_list
inline
-Trigger_list::Trigger_list( const QString& comment_P )
- : QPtrList< Trigger >(), _comment( comment_P )
+Trigger_list::Trigger_list( const TQString& comment_P )
+ : TQPtrList< Trigger >(), _comment( comment_P )
{
setAutoDelete( true );
}
inline
-const QString& Trigger_list::comment() const
+const TQString& Trigger_list::comment() const
{
return _comment;
}
@@ -237,14 +237,14 @@ bool Window_trigger::triggers_on( window_action_t w_action_P ) const
// Gesture_trigger
inline
-const QString& Gesture_trigger::gesturecode() const
+const TQString& Gesture_trigger::gesturecode() const
{
return _gesturecode;
}
// Voice_trigger
inline
-const QString& Voice_trigger::voicecode() const
+const TQString& Voice_trigger::voicecode() const
{
return _voicecode;
}
diff --git a/khotkeys/shared/voices.cpp b/khotkeys/shared/voices.cpp
index e0dc95613..a6515fecf 100644
--- a/khotkeys/shared/voices.cpp
+++ b/khotkeys/shared/voices.cpp
@@ -27,7 +27,7 @@
#include <kdebug.h>
#include <kxerrorhandler.h>
#include <kkeynative.h>
-#include <qtimer.h>
+#include <tqtimer.h>
#include <kglobalaccel.h>
@@ -39,8 +39,8 @@ namespace KHotKeys
Voice* voice_handler;
-Voice::Voice( bool enabled_P, QObject* parent_P )
- : QObject( parent_P) ,_enabled( enabled_P ), _recording( false ), _recorder(0)
+Voice::Voice( bool enabled_P, TQObject* parent_P )
+ : TQObject( parent_P) ,_enabled( enabled_P ), _recording( false ), _recorder(0)
{
assert( voice_handler == NULL );
voice_handler = this;
@@ -95,7 +95,7 @@ void Voice::record_start()
if(!_recorder)
{
_recorder= SoundRecorder::create(this);
- connect(_recorder, SIGNAL(recorded(const Sound& )), this, SLOT(slot_sound_recorded(const Sound& )));
+ connect(_recorder, TQT_SIGNAL(recorded(const Sound& )), this, TQT_SLOT(slot_sound_recorded(const Sound& )));
}
_recorder->start();
@@ -125,7 +125,7 @@ void Voice::slot_sound_recorded(const Sound &sound_P)
double minimum=800000;
double second_minimum=80000;
int got_count=0;
- QValueList<Voice_trigger*>::Iterator it;
+ TQValueList<Voice_trigger*>::Iterator it;
for ( it = _references.begin(); it != _references.end(); ++it )
{
for(int ech=1; ech<=2 ; ech++)
@@ -208,7 +208,7 @@ void Voice::set_shortcut( const KShortcut &shortcut)
_kga = new KGlobalAccel( this );
_kga->remove("voice");
- _kga->insert( "voice", i18n("Voice"), QString::null, shortcut, 0, this, SLOT(slot_key_pressed())) ;
+ _kga->insert( "voice", i18n("Voice"), TQString::null, shortcut, 0, this, TQT_SLOT(slot_key_pressed())) ;
_kga->updateConnections();
}
@@ -223,8 +223,8 @@ void Voice::slot_key_pressed()
record_start();
if(!_timer)
{
- _timer=new QTimer(this);
- connect(_timer, SIGNAL(timeout()) , this, SLOT(slot_timeout()));
+ _timer=new TQTimer(this);
+ connect(_timer, TQT_SIGNAL(timeout()) , this, TQT_SLOT(slot_timeout()));
}
_timer->start(1000*20,true);
@@ -244,14 +244,14 @@ void Voice::slot_timeout()
}
-QString Voice::isNewSoundFarEnough(const VoiceSignature& signature, const QString &currentTrigger)
+TQString Voice::isNewSoundFarEnough(const VoiceSignature& signature, const TQString &currentTrigger)
{
Voice_trigger *trig=0L;
Voice_trigger *sec_trig=0L;
double minimum=800000;
double second_minimum=80000;
int got_count=0;
- QValueList<Voice_trigger*>::Iterator it;
+ TQValueList<Voice_trigger*>::Iterator it;
for ( it = _references.begin(); it != _references.end(); ++it )
{
Voice_trigger *t=*it;
@@ -283,12 +283,12 @@ QString Voice::isNewSoundFarEnough(const VoiceSignature& signature, const QStrin
kdDebug(1217) << k_funcinfo << "**** " << trig->voicecode() << " : " << minimum << endl;
bool selected=trig && ((got_count==1 && minimum < REJECT_FACTOR_DIFF*0.7 ) || ( minimum < REJECT_FACTOR_DIFF && trig==sec_trig ) );
- return selected ? trig->voicecode() : QString::null;
+ return selected ? trig->voicecode() : TQString::null;
}
-bool Voice::doesVoiceCodeExists(const QString &vc)
+bool Voice::doesVoiceCodeExists(const TQString &vc)
{
- QValueList<Voice_trigger*>::Iterator it;
+ TQValueList<Voice_trigger*>::Iterator it;
for ( it = _references.begin(); it != _references.end(); ++it )
{
Voice_trigger *t=*it;
diff --git a/khotkeys/shared/voices.h b/khotkeys/shared/voices.h
index b0193e7c2..89329ba5d 100644
--- a/khotkeys/shared/voices.h
+++ b/khotkeys/shared/voices.h
@@ -11,7 +11,7 @@
#ifndef VOICES_H_
#define VOICES_H_
-#include <qwidget.h>
+#include <tqwidget.h>
#include <kshortcut.h>
class Sound;
@@ -32,7 +32,7 @@ class KDE_EXPORT Voice : public QObject
{
Q_OBJECT
public:
- Voice( bool enabled_P, QObject* parent_P );
+ Voice( bool enabled_P, TQObject* parent_P );
virtual ~Voice();
void enable( bool enable_P );
@@ -43,12 +43,12 @@ class KDE_EXPORT Voice : public QObject
void set_shortcut( const KShortcut &k);
/**
- * return QString::null is a new signature is far enough from others signature
+ * return TQString::null is a new signature is far enough from others signature
* otherwise, return the stringn which match.
*/
- QString isNewSoundFarEnough(const VoiceSignature& s, const QString& currentTrigger);
+ TQString isNewSoundFarEnough(const VoiceSignature& s, const TQString& currentTrigger);
- bool doesVoiceCodeExists(const QString &s);
+ bool doesVoiceCodeExists(const TQString &s);
public slots:
void record_start();
@@ -60,19 +60,19 @@ class KDE_EXPORT Voice : public QObject
void slot_timeout();
signals:
- void handle_voice( const QString &voice );
+ void handle_voice( const TQString &voice );
private:
bool _enabled;
bool _recording;
- QValueList<Voice_trigger *> _references;
+ TQValueList<Voice_trigger *> _references;
SoundRecorder *_recorder;
KShortcut _shortcut;
KGlobalAccel *_kga;
- QTimer *_timer;
+ TQTimer *_timer;
};
diff --git a/khotkeys/shared/voicesignature.cpp b/khotkeys/shared/voicesignature.cpp
index c77c278b3..773f28731 100644
--- a/khotkeys/shared/voicesignature.cpp
+++ b/khotkeys/shared/voicesignature.cpp
@@ -29,7 +29,7 @@
#include <kdebug.h>
-#include <qdatetime.h>
+#include <tqdatetime.h>
#undef Complex
@@ -109,10 +109,10 @@ static inline double hamming(uint n, uint size)
}
-static QMemArray<double> fft(const Sound& sound, unsigned int start, unsigned int stop)
+static TQMemArray<double> fft(const Sound& sound, unsigned int start, unsigned int stop)
{
if(start>=stop || sound.size() == 0)
- return QMemArray<double>();
+ return TQMemArray<double>();
//We need a sample with a size of a power of two
uint size=stop-start;
@@ -146,7 +146,7 @@ static QMemArray<double> fft(const Sound& sound, unsigned int start, unsigned in
}
//Generate an array to work in
- QMemArray<Complex> samples(size);
+ TQMemArray<Complex> samples(size);
//Fill it with samples in the "reversed carry" order
int rev_carry = 0;
@@ -188,7 +188,7 @@ static QMemArray<double> fft(const Sound& sound, unsigned int start, unsigned in
}
}
- QMemArray<double> result(size);
+ TQMemArray<double> result(size);
for(uint f=0;f<size;f++)
{
result[f]=samples[f].Mod() / size;
@@ -200,10 +200,10 @@ static QMemArray<double> fft(const Sound& sound, unsigned int start, unsigned in
-QMemArray<double> VoiceSignature::fft(const Sound& sound, unsigned int start, unsigned int stop)
+TQMemArray<double> VoiceSignature::fft(const Sound& sound, unsigned int start, unsigned int stop)
{
return KHotKeys::fft(sound, start, stop);
- /*QMemArray<double> result(8000);
+ /*TQMemArray<double> result(8000);
for(int f=0; f<8000;f++)
{
Complex c(0);
@@ -276,7 +276,7 @@ bool VoiceSignature::window(const Sound& sound, unsigned int *_start, unsigned i
VoiceSignature::VoiceSignature(const Sound& sound)
{
static uint temp_wind=0, temp_fft=0, temp_moy=0;
- QTime t;
+ TQTime t;
t.start();
unsigned int start , stop;
@@ -296,7 +296,7 @@ VoiceSignature::VoiceSignature(const Sound& sound)
unsigned int w_stop =MIN(stop , start+ (int)((wind+1.0+WINDOW_SUPER)*length/WINDOW_NUMBER));
- QMemArray<double> fourrier=fft(sound, w_start,w_stop);
+ TQMemArray<double> fourrier=fft(sound, w_start,w_stop);
temp_fft+=t.restart();
@@ -394,24 +394,24 @@ int VoiceSignature::size2()
return FOUR_NUMBER;
}
-QMap<int, QMap<int, double> > VoiceSignature::pond;
+TQMap<int, TQMap<int, double> > VoiceSignature::pond;
-void VoiceSignature::write(KConfigBase *cfg, const QString &key) const
+void VoiceSignature::write(KConfigBase *cfg, const TQString &key) const
{
- QStringList sl;
+ TQStringList sl;
for(int x=0;x<WINDOW_NUMBER;x++)
for(int y=0;y<FOUR_NUMBER;y++)
{
- sl.append( QString::number(data[x][y]) );
+ sl.append( TQString::number(data[x][y]) );
}
cfg->writeEntry(key,sl);
}
-void VoiceSignature::read(KConfigBase *cfg, const QString &key)
+void VoiceSignature::read(KConfigBase *cfg, const TQString &key)
{
- QStringList sl=cfg->readListEntry(key);
+ TQStringList sl=cfg->readListEntry(key);
for(int x=0;x<WINDOW_NUMBER;x++)
for(int y=0;y<FOUR_NUMBER;y++)
{
diff --git a/khotkeys/shared/voicesignature.h b/khotkeys/shared/voicesignature.h
index b4857efd2..82556864f 100644
--- a/khotkeys/shared/voicesignature.h
+++ b/khotkeys/shared/voicesignature.h
@@ -21,8 +21,8 @@
#define SIGNATURE_H
-#include <qmemarray.h>
-#include <qmap.h>
+#include <tqmemarray.h>
+#include <tqmap.h>
#include <kdemacros.h>
class Sound;
@@ -73,9 +73,9 @@ public:
VoiceSignature(){}
~VoiceSignature();
- QMap<int, QMap<int, double> > data;
+ TQMap<int, TQMap<int, double> > data;
- static QMap<int, QMap<int, double> > pond;
+ static TQMap<int, TQMap<int, double> > pond;
static float diff(const VoiceSignature &s1, const VoiceSignature &s2);
@@ -84,11 +84,11 @@ public:
static int size2();
- static QMemArray<double> fft(const Sound& sound, unsigned int start, unsigned int stop);
+ static TQMemArray<double> fft(const Sound& sound, unsigned int start, unsigned int stop);
static bool window(const Sound& sound, unsigned int *start, unsigned int *stop);
- void write(KConfigBase *cfg, const QString &key) const;
- void read(KConfigBase *cfg, const QString &key);
+ void write(KConfigBase *cfg, const TQString &key) const;
+ void read(KConfigBase *cfg, const TQString &key);
inline bool isNull() const
{
diff --git a/khotkeys/shared/windows.cpp b/khotkeys/shared/windows.cpp
index d269ef2fe..b8e86f694 100644
--- a/khotkeys/shared/windows.cpp
+++ b/khotkeys/shared/windows.cpp
@@ -17,7 +17,7 @@
#include "windows.h"
#include <assert.h>
-#include <qregexp.h>
+#include <tqregexp.h>
#include <kconfig.h>
#include <kdebug.h>
@@ -37,18 +37,18 @@ namespace KHotKeys
// Windows
-Windows::Windows( bool enable_signal_P, QObject* parent_P )
- : QObject( parent_P ), signals_enabled( enable_signal_P ),
+Windows::Windows( bool enable_signal_P, TQObject* parent_P )
+ : TQObject( parent_P ), signals_enabled( enable_signal_P ),
kwin_module( new KWinModule( this )), _action_window( 0 )
{
assert( windows_handler == NULL );
windows_handler = this;
if( signals_enabled )
{
- connect( kwin_module, SIGNAL( windowAdded( WId )), SLOT( window_added_slot( WId )));
- connect( kwin_module, SIGNAL( windowRemoved( WId )), SLOT( window_removed_slot( WId )));
- connect( kwin_module, SIGNAL( activeWindowChanged( WId )),
- SLOT( active_window_changed_slot( WId )));
+ connect( kwin_module, TQT_SIGNAL( windowAdded( WId )), TQT_SLOT( window_added_slot( WId )));
+ connect( kwin_module, TQT_SIGNAL( windowRemoved( WId )), TQT_SLOT( window_removed_slot( WId )));
+ connect( kwin_module, TQT_SIGNAL( activeWindowChanged( WId )),
+ TQT_SLOT( active_window_changed_slot( WId )));
}
}
@@ -91,18 +91,18 @@ void Windows::window_changed_slot( WId window_P, unsigned int flags_P )
emit window_changed( window_P, flags_P );
}
-QString Windows::get_window_role( WId id_P )
+TQString Windows::get_window_role( WId id_P )
{
// TODO this is probably just a hack
return KWin::readNameProperty( id_P, qt_window_role );
}
-QString Windows::get_window_class( WId id_P )
+TQString Windows::get_window_class( WId id_P )
{
XClassHint hints_ret;
if( XGetClassHint( qt_xdisplay(), id_P, &hints_ret ) == 0 ) // 0 means error
return "";
- QString ret( hints_ret.res_name );
+ TQString ret( hints_ret.res_name );
ret += ' ';
ret += hints_ret.res_class;
XFree( hints_ret.res_name );
@@ -127,7 +127,7 @@ void Windows::set_action_window( WId window_P )
WId Windows::find_window( const Windowdef_list* window_P )
{
- for( QValueList< WId >::ConstIterator it = kwin_module->windows().begin();
+ for( TQValueList< WId >::ConstIterator it = kwin_module->windows().begin();
it != kwin_module->windows().end();
++it )
{
@@ -214,7 +214,7 @@ Windowdef::Windowdef( KConfig& cfg_P )
Windowdef* Windowdef::create_cfg_read( KConfig& cfg_P )
{
- QString type = cfg_P.readEntry( "Type" );
+ TQString type = cfg_P.readEntry( "Type" );
if( type == "SIMPLE" )
return new Windowdef_simple( cfg_P );
kdWarning( 1217 ) << "Unknown Windowdef type read from cfg file\n";
@@ -224,17 +224,17 @@ Windowdef* Windowdef::create_cfg_read( KConfig& cfg_P )
// Windowdef_list
Windowdef_list::Windowdef_list( KConfig& cfg_P )
- : QPtrList< Windowdef >()
+ : TQPtrList< Windowdef >()
{
setAutoDelete( true );
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
_comment = cfg_P.readEntry( "Comment" );
int cnt = cfg_P.readNumEntry( "WindowsCount", 0 );
for( int i = 0;
i < cnt;
++i )
{
- cfg_P.setGroup( save_cfg_group + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + TQString::number( i ));
Windowdef* window = Windowdef::create_cfg_read( cfg_P );
if( window )
append( window );
@@ -244,13 +244,13 @@ Windowdef_list::Windowdef_list( KConfig& cfg_P )
void Windowdef_list::cfg_write( KConfig& cfg_P ) const
{
- QString save_cfg_group = cfg_P.group();
+ TQString save_cfg_group = cfg_P.group();
int i = 0;
for( Iterator it( *this );
it;
++it, ++i )
{
- cfg_P.setGroup( save_cfg_group + QString::number( i ));
+ cfg_P.setGroup( save_cfg_group + TQString::number( i ));
it.current()->cfg_write( cfg_P );
}
cfg_P.setGroup( save_cfg_group );
@@ -283,9 +283,9 @@ bool Windowdef_list::match( const Window_data& window_P ) const
// Windowdef_simple
-Windowdef_simple::Windowdef_simple( const QString& comment_P, const QString& title_P,
- substr_type_t title_type_P, const QString& wclass_P, substr_type_t wclass_type_P,
- const QString& role_P, substr_type_t role_type_P, int window_types_P )
+Windowdef_simple::Windowdef_simple( const TQString& comment_P, const TQString& title_P,
+ substr_type_t title_type_P, const TQString& wclass_P, substr_type_t wclass_type_P,
+ const TQString& role_P, substr_type_t role_type_P, int window_types_P )
: Windowdef( comment_P ), _title( title_P ), title_type( title_type_P ),
_wclass( wclass_P ), wclass_type( wclass_type_P ), _role( role_P ),
role_type( role_type_P ), _window_types( window_types_P )
@@ -331,7 +331,7 @@ bool Windowdef_simple::match( const Window_data& window_P )
return true;
}
-bool Windowdef_simple::is_substr_match( const QString& str1_P, const QString& str2_P,
+bool Windowdef_simple::is_substr_match( const TQString& str1_P, const TQString& str2_P,
substr_type_t type_P )
{
switch( type_P )
@@ -344,7 +344,7 @@ bool Windowdef_simple::is_substr_match( const QString& str1_P, const QString& st
return str1_P == str2_P;
case REGEXP :
{
- QRegExp rg( str2_P );
+ TQRegExp rg( str2_P );
return rg.search( str1_P ) >= 0;
}
case CONTAINS_NOT :
@@ -353,7 +353,7 @@ bool Windowdef_simple::is_substr_match( const QString& str1_P, const QString& st
return str1_P != str2_P;
case REGEXP_NOT :
{
- QRegExp rg( str2_P );
+ TQRegExp rg( str2_P );
return rg.search( str1_P ) < 0;
}
}
@@ -366,7 +366,7 @@ Windowdef* Windowdef_simple::copy() const
wclass_match_type(), role(), role_match_type(), window_types());
}
-const QString Windowdef_simple::description() const
+const TQString Windowdef_simple::description() const
{
return i18n( "Window simple: " ) + comment();
}
diff --git a/khotkeys/shared/windows.h b/khotkeys/shared/windows.h
index f048ce6b9..d145efa87 100644
--- a/khotkeys/shared/windows.h
+++ b/khotkeys/shared/windows.h
@@ -13,9 +13,9 @@
#include <sys/types.h>
-#include <qobject.h>
-#include <qstring.h>
-#include <qptrlist.h>
+#include <tqobject.h>
+#include <tqstring.h>
+#include <tqptrlist.h>
#include <netwm_def.h>
@@ -39,10 +39,10 @@ class KDE_EXPORT Windows
{
Q_OBJECT
public:
- Windows( bool enable_signals_P, QObject* parent_P );
+ Windows( bool enable_signals_P, TQObject* parent_P );
virtual ~Windows();
- QString get_window_class( WId id_P );
- QString get_window_role( WId id_P );
+ TQString get_window_class( WId id_P );
+ TQString get_window_role( WId id_P );
WId active_window();
void set_action_window( WId window );
WId action_window();
@@ -70,42 +70,42 @@ class KDE_EXPORT Windows
struct KDE_EXPORT Window_data
{
Window_data( WId id_P );
- QString title; // _NET_WM_NAME or WM_NAME
- QString role; // WM_WINDOW_ROLE
- QString wclass; // WM_CLASS
+ TQString title; // _NET_WM_NAME or WM_NAME
+ TQString role; // WM_WINDOW_ROLE
+ TQString wclass; // WM_CLASS
NET::WindowType type;
};
class KDE_EXPORT Windowdef
{
public:
- Windowdef( const QString& comment_P );
+ Windowdef( const TQString& comment_P );
Windowdef( KConfig& cfg_P );
virtual ~Windowdef();
- const QString& comment() const;
+ const TQString& comment() const;
virtual bool match( const Window_data& window_P ) = 0;
static Windowdef* create_cfg_read( KConfig& cfg_P/*, Action_data_base* data_P*/ );
virtual void cfg_write( KConfig& cfg_P ) const = 0;
virtual Windowdef* copy( /*Action_data_base* data_P*/ ) const = 0;
- virtual const QString description() const = 0;
+ virtual const TQString description() const = 0;
private:
- QString _comment;
+ TQString _comment;
KHOTKEYS_DISABLE_COPY( Windowdef ); // CHECKME asi pak udelat i pro vsechny potomky, at se nezapomene
};
class KDE_EXPORT Windowdef_list
- : public QPtrList< Windowdef >
+ : public TQPtrList< Windowdef >
{
public:
- Windowdef_list( const QString& comment_P );
+ Windowdef_list( const TQString& comment_P );
Windowdef_list( KConfig& cfg_P/*, Action_data_base* data_P*/ );
void cfg_write( KConfig& cfg_P ) const;
bool match( const Window_data& window_P ) const;
Windowdef_list* copy( /*Action_data_base* data_P*/ ) const;
- typedef QPtrListIterator< Windowdef > Iterator;
- const QString& comment() const;
+ typedef TQPtrListIterator< Windowdef > Iterator;
+ const TQString& comment() const;
private:
- QString _comment;
+ TQString _comment;
KHOTKEYS_DISABLE_COPY( Windowdef_list );
};
@@ -133,32 +133,32 @@ class KDE_EXPORT Windowdef_simple
// WINDOW_TYPE_MENU = ( 1 << NET::Menu ),
WINDOW_TYPE_DIALOG = ( 1 << NET::Dialog )
};
- Windowdef_simple( const QString& comment_P, const QString& title_P,
- substr_type_t title_type_P, const QString& wclass_P, substr_type_t wclass_type_P,
- const QString& role_P, substr_type_t role_type_P, int window_types_P );
+ Windowdef_simple( const TQString& comment_P, const TQString& title_P,
+ substr_type_t title_type_P, const TQString& wclass_P, substr_type_t wclass_type_P,
+ const TQString& role_P, substr_type_t role_type_P, int window_types_P );
Windowdef_simple( KConfig& cfg_P );
virtual bool match( const Window_data& window_P );
virtual void cfg_write( KConfig& cfg_P ) const;
- const QString& title() const;
+ const TQString& title() const;
substr_type_t title_match_type() const;
- const QString& wclass() const;
+ const TQString& wclass() const;
substr_type_t wclass_match_type() const;
- const QString& role() const;
+ const TQString& role() const;
substr_type_t role_match_type() const;
int window_types() const;
bool type_match( window_type_t type_P ) const;
bool type_match( NET::WindowType type_P ) const;
virtual Windowdef* copy( /*Action_data_base* data_P*/ ) const;
- virtual const QString description() const;
+ virtual const TQString description() const;
protected:
- bool is_substr_match( const QString& str1_P, const QString& str2_P,
+ bool is_substr_match( const TQString& str1_P, const TQString& str2_P,
substr_type_t type_P );
private:
- QString _title;
+ TQString _title;
substr_type_t title_type;
- QString _wclass;
+ TQString _wclass;
substr_type_t wclass_type;
- QString _role;
+ TQString _role;
substr_type_t role_type;
int _window_types;
};
@@ -170,13 +170,13 @@ class KDE_EXPORT Windowdef_simple
// Windowdef
inline
-Windowdef::Windowdef( const QString& comment_P )
+Windowdef::Windowdef( const TQString& comment_P )
: _comment( comment_P )
{
}
inline
-const QString& Windowdef::comment() const
+const TQString& Windowdef::comment() const
{
return _comment;
}
@@ -189,14 +189,14 @@ Windowdef::~Windowdef()
// Windowdef_list
inline
-Windowdef_list::Windowdef_list( const QString& comment_P )
- : QPtrList< Windowdef >(), _comment( comment_P )
+Windowdef_list::Windowdef_list( const TQString& comment_P )
+ : TQPtrList< Windowdef >(), _comment( comment_P )
{
setAutoDelete( true );
}
inline
-const QString& Windowdef_list::comment() const
+const TQString& Windowdef_list::comment() const
{
return _comment;
}
@@ -204,7 +204,7 @@ const QString& Windowdef_list::comment() const
// Windowdef_simple
inline
-const QString& Windowdef_simple::title() const
+const TQString& Windowdef_simple::title() const
{
return _title;
}
@@ -216,7 +216,7 @@ Windowdef_simple::substr_type_t Windowdef_simple::title_match_type() const
}
inline
-const QString& Windowdef_simple::wclass() const
+const TQString& Windowdef_simple::wclass() const
{
return _wclass;
}
@@ -228,7 +228,7 @@ Windowdef_simple::substr_type_t Windowdef_simple::wclass_match_type() const
}
inline
-const QString& Windowdef_simple::role() const
+const TQString& Windowdef_simple::role() const
{
return _role;
}