summaryrefslogtreecommitdiffstats
path: root/tdecore
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-02-01 15:13:01 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2013-02-01 15:13:01 -0600
commitdeac2ca49faed824fe83066080714eb6d653615b (patch)
tree8b5bf97c5acaaf5285985b87fa76dbea0f35e4fa /tdecore
parent0c9d97065a3d6ceb12d687555a1a33d90db96238 (diff)
downloadtdelibs-deac2ca49faed824fe83066080714eb6d653615b.tar.gz
tdelibs-deac2ca49faed824fe83066080714eb6d653615b.zip
Rename a number of classes to enhance compatibility with KDE4
Diffstat (limited to 'tdecore')
-rw-r--r--tdecore/AUTHORS6
-rw-r--r--tdecore/DESIGN.iconloading2
-rw-r--r--tdecore/README.kiosk4
-rw-r--r--tdecore/kaccel.cpp246
-rw-r--r--tdecore/kaccel.h78
-rw-r--r--tdecore/kaccelaction.cpp226
-rw-r--r--tdecore/kaccelaction.h144
-rw-r--r--tdecore/kaccelbase.cpp140
-rw-r--r--tdecore/kaccelbase.h70
-rw-r--r--tdecore/kaccelmanager.cpp166
-rw-r--r--tdecore/kaccelmanager.h4
-rw-r--r--tdecore/kaccelmanager_private.h26
-rw-r--r--tdecore/kaccelprivate.h20
-rw-r--r--tdecore/kapplication.cpp24
-rw-r--r--tdecore/kapplication.h48
-rw-r--r--tdecore/kcheckaccelerators.cpp6
-rw-r--r--tdecore/kcompletion.h8
-rw-r--r--tdecore/kcompletionbase.cpp2
-rw-r--r--tdecore/kdebug.areas14
-rw-r--r--tdecore/kdebugrc6
-rw-r--r--tdecore/kglobalaccel.cpp28
-rw-r--r--tdecore/kglobalaccel.h30
-rw-r--r--tdecore/kglobalaccel_emb.h4
-rw-r--r--tdecore/kglobalaccel_mac.h8
-rw-r--r--tdecore/kglobalaccel_win.cpp18
-rw-r--r--tdecore/kglobalaccel_win.h10
-rw-r--r--tdecore/kglobalaccel_x11.cpp22
-rw-r--r--tdecore/kglobalaccel_x11.h12
-rw-r--r--tdecore/kglobalsettings.cpp2
-rw-r--r--tdecore/kglobalsettings.h12
-rw-r--r--tdecore/kmanagerselection.cpp84
-rw-r--r--tdecore/kmanagerselection.h24
-rw-r--r--tdecore/kshortcut.cpp74
-rw-r--r--tdecore/kshortcut.h60
-rw-r--r--tdecore/kshortcutlist.cpp84
-rw-r--r--tdecore/kshortcutlist.h76
-rw-r--r--tdecore/kshortcutmenu.cpp16
-rw-r--r--tdecore/kshortcutmenu.h8
-rw-r--r--tdecore/kstdaccel.cpp270
-rw-r--r--tdecore/kstdaccel.h116
-rw-r--r--tdecore/tdeconfigdialogmanager.cpp8
-rw-r--r--tdecore/tests/kstdacceltest.cpp12
42 files changed, 1109 insertions, 1109 deletions
diff --git a/tdecore/AUTHORS b/tdecore/AUTHORS
index 03def3f46..ce19e095b 100644
--- a/tdecore/AUTHORS
+++ b/tdecore/AUTHORS
@@ -16,16 +16,16 @@ DnD stuff, TDESocket and TDEServerSocket classes, KPixmap
Alexander Sanda <alex@darkstar.ping.at>
Read and write numerical config entries, KPanner, KTabControl,
-KPopupMenu, KMessageBox, KEdit widgets.
+TDEPopupMenu, KMessageBox, KEdit widgets.
Martin Jones <mjones@powerup.com.au>
-Bugfixes in KPixmap and KURL, KColorDialog, KSelector
+Bugfixes in KPixmap and KURL, KColorDialog, TDESelector
Keith Brown <kbrown@pdq.net>
KTreeList class
Bernd Johannes Wuebben <wuebben@math.cornell.edu>
-KFontDialog classes
+TDEFontDialog classes
Tim D. Gilman <tdgilman@best.com>
KDatePicker, KDateTable class
diff --git a/tdecore/DESIGN.iconloading b/tdecore/DESIGN.iconloading
index a9e57afbd..a675a8922 100644
--- a/tdecore/DESIGN.iconloading
+++ b/tdecore/DESIGN.iconloading
@@ -72,7 +72,7 @@ information and then waiting for a sufficient long period, e.. 5 minutes,
before actually removing the image data.
I can also imagine a scenario where the index information is only used very
-temporarily, e.g. during the creation of a KMainWindow (mmap the file in the
+temporarily, e.g. during the creation of a TDEMainWindow (mmap the file in the
constructor, unmap it from the next event loop) that way icons can be removed
from the index and after e.g. a timeout of 5 minutes one can be relatively
sure that the index will no longer be used.
diff --git a/tdecore/README.kiosk b/tdecore/README.kiosk
index e12e29d27..54ab60d2d 100644
--- a/tdecore/README.kiosk
+++ b/tdecore/README.kiosk
@@ -331,7 +331,7 @@ Applications may use additional actions that they defined themselves.
You can get a list of the actions used by a certain applications by using the
following dcop command:
-dcop <dcopid> qt objects | grep KActionCollection/ | cut -d '/' -f 3
+dcop <dcopid> qt objects | grep TDEActionCollection/ | cut -d '/' -f 3
or with
@@ -660,7 +660,7 @@ KDE3 Kiosk Application API
Three new methods have been added to TDEApplication:
- bool authorize(QString action); // Generic actions
-- bool authorizeKAction(QString action); // For KActions exclusively
+- bool authorizeTDEAction(QString action); // For TDEActions exclusively
- bool authorizeURLAction(QString, referringURL, destinationURL) // URL Handling
Automatic Logout
diff --git a/tdecore/kaccel.cpp b/tdecore/kaccel.cpp
index 7291f3f56..9dde93e7a 100644
--- a/tdecore/kaccel.cpp
+++ b/tdecore/kaccel.cpp
@@ -45,15 +45,15 @@
// TODO: Put in kaccelbase.cpp
//---------------------------------------------------------------------
-// KAccelEventHandler
+// TDEAccelEventHandler
//---------------------------------------------------------------------
//
-// In KAccelEventHandler::x11Event we do our own X11 keyboard event handling
+// In TDEAccelEventHandler::x11Event we do our own X11 keyboard event handling
// This allows us to map the Win key to Qt::MetaButton, Qt does not know about
// the Win key.
//
-// KAccelEventHandler::x11Event will generate an AccelOverride event. The
-// AccelOverride event is abused a bit to ensure that KAccelPrivate::eventFilter
+// TDEAccelEventHandler::x11Event will generate an AccelOverride event. The
+// AccelOverride event is abused a bit to ensure that TDEAccelPrivate::eventFilter
// (as an event filter on the toplevel widget) will get the key event first
// (in the form of AccelOverride) before any of the intermediate widgets are
// able to process it.
@@ -63,10 +63,10 @@
// skipped and the KeyPress is followed immediately.
// If the Accel event is accepted, no KeyPress event will follow.
//
-// KAccelEventHandler::x11Event converts a X11 keyboard event into an AccelOverride
+// TDEAccelEventHandler::x11Event converts a X11 keyboard event into an AccelOverride
// event, there are now two possibilities:
//
-// 1) If KAccel intercepts the AccelOverride we are done and can consider the X11
+// 1) If TDEAccel intercepts the AccelOverride we are done and can consider the X11
// keyboard event as handled.
// 2) If another widget accepts the AccelOverride, it will expect to get a normal
// Qt generated KeyPress event afterwards. So we let Qt handle the X11 keyboard event
@@ -80,34 +80,34 @@
bool kde_g_bKillAccelOverride = false;
-class KAccelEventHandler : public TQWidget
+class TDEAccelEventHandler : public TQWidget
{
public:
- static KAccelEventHandler* self()
+ static TDEAccelEventHandler* self()
{
if( !g_pSelf )
- g_pSelf = new KAccelEventHandler;
+ g_pSelf = new TDEAccelEventHandler;
return g_pSelf;
}
static void accelActivated( bool b ) { g_bAccelActivated = b; }
private:
- KAccelEventHandler();
+ TDEAccelEventHandler();
# ifdef Q_WS_X11
bool x11Event( XEvent* pEvent );
# endif
- static KAccelEventHandler* g_pSelf;
+ static TDEAccelEventHandler* g_pSelf;
static bool g_bAccelActivated;
};
-KAccelEventHandler* KAccelEventHandler::g_pSelf = 0;
-bool KAccelEventHandler::g_bAccelActivated = false;
+TDEAccelEventHandler* TDEAccelEventHandler::g_pSelf = 0;
+bool TDEAccelEventHandler::g_bAccelActivated = false;
-KAccelEventHandler::KAccelEventHandler()
- : TQWidget( 0, "KAccelEventHandler" )
+TDEAccelEventHandler::TDEAccelEventHandler()
+ : TQWidget( 0, "TDEAccelEventHandler" )
{
# ifdef Q_WS_X11
if ( kapp )
@@ -118,7 +118,7 @@ KAccelEventHandler::KAccelEventHandler()
#ifdef Q_WS_X11
bool tqt_try_modal( TQWidget *, XEvent * );
-bool KAccelEventHandler::x11Event( XEvent* pEvent )
+bool TDEAccelEventHandler::x11Event( XEvent* pEvent )
{
if( TQWidget::keyboardGrabber() || !kapp->focusWidget() )
return false;
@@ -146,7 +146,7 @@ bool KAccelEventHandler::x11Event( XEvent* pEvent )
g_bAccelActivated = false;
kapp->sendEvent( kapp->focusWidget(), &ke );
- // If the Override event was accepted from a non-KAccel widget,
+ // If the Override event was accepted from a non-TDEAccel widget,
// then kill the next AccelOverride in TDEApplication::notify.
if( ke.isAccepted() && !g_bAccelActivated )
kde_g_bKillAccelOverride = true;
@@ -160,35 +160,35 @@ bool KAccelEventHandler::x11Event( XEvent* pEvent )
#endif // Q_WS_X11
//---------------------------------------------------------------------
-// KAccelPrivate
+// TDEAccelPrivate
//---------------------------------------------------------------------
-KAccelPrivate::KAccelPrivate( KAccel* pParent, TQWidget* pWatch )
-: KAccelBase( KAccelBase::QT_KEYS )
+TDEAccelPrivate::TDEAccelPrivate( TDEAccel* pParent, TQWidget* pWatch )
+: TDEAccelBase( TDEAccelBase::QT_KEYS )
{
- //kdDebug(125) << "KAccelPrivate::KAccelPrivate( pParent = " << pParent << " ): this = " << this << endl;
+ //kdDebug(125) << "TDEAccelPrivate::TDEAccelPrivate( pParent = " << pParent << " ): this = " << this << endl;
m_pAccel = pParent;
m_pWatch = pWatch;
m_bAutoUpdate = true;
connect( (TQAccel*)m_pAccel, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotKeyPressed(int)) );
-#ifdef Q_WS_X11 //only makes sense if KAccelEventHandler is working
+#ifdef Q_WS_X11 //only makes sense if TDEAccelEventHandler is working
if( m_pWatch )
m_pWatch->installEventFilter( this );
#endif
- KAccelEventHandler::self();
+ TDEAccelEventHandler::self();
}
-void KAccelPrivate::setEnabled( bool bEnabled )
+void TDEAccelPrivate::setEnabled( bool bEnabled )
{
m_bEnabled = bEnabled;
((TQAccel*)m_pAccel)->setEnabled( bEnabled );
}
-bool KAccelPrivate::setEnabled( const TQString& sAction, bool bEnable )
+bool TDEAccelPrivate::setEnabled( const TQString& sAction, bool bEnable )
{
- kdDebug(125) << "KAccelPrivate::setEnabled( \"" << sAction << "\", " << bEnable << " ): this = " << this << endl;
- KAccelAction* pAction = actionPtr( sAction );
+ kdDebug(125) << "TDEAccelPrivate::setEnabled( \"" << sAction << "\", " << bEnable << " ): this = " << this << endl;
+ TDEAccelAction* pAction = actionPtr( sAction );
if( !pAction )
return false;
if( pAction->isEnabled() == bEnable )
@@ -196,7 +196,7 @@ bool KAccelPrivate::setEnabled( const TQString& sAction, bool bEnable )
pAction->setEnabled( bEnable );
- TQMap<int, KAccelAction*>::const_iterator it = m_mapIDToAction.begin();
+ TQMap<int, TDEAccelAction*>::const_iterator it = m_mapIDToAction.begin();
for( ; it != m_mapIDToAction.end(); ++it ) {
if( *it == pAction )
((TQAccel*)m_pAccel)->setItemEnabled( it.key(), bEnable );
@@ -204,32 +204,32 @@ bool KAccelPrivate::setEnabled( const TQString& sAction, bool bEnable )
return true;
}
-bool KAccelPrivate::removeAction( const TQString& sAction )
+bool TDEAccelPrivate::removeAction( const TQString& sAction )
{
// FIXME: getID() doesn't contains any useful
// information! Use mapIDToAction. --ellis, 2/May/2002
- // Or maybe KAccelBase::remove() takes care of TQAccel indirectly...
- KAccelAction* pAction = actions().actionPtr( sAction );
+ // Or maybe TDEAccelBase::remove() takes care of TQAccel indirectly...
+ TDEAccelAction* pAction = actions().actionPtr( sAction );
if( pAction ) {
int nID = pAction->getID();
//bool b = actions().removeAction( sAction );
- bool b = KAccelBase::remove( sAction );
+ bool b = TDEAccelBase::remove( sAction );
((TQAccel*)m_pAccel)->removeItem( nID );
return b;
} else
return false;
}
-bool KAccelPrivate::emitSignal( KAccelBase::Signal signal )
+bool TDEAccelPrivate::emitSignal( TDEAccelBase::Signal signal )
{
- if( signal == KAccelBase::KEYCODE_CHANGED ) {
+ if( signal == TDEAccelBase::KEYCODE_CHANGED ) {
m_pAccel->emitKeycodeChanged();
return true;
}
return false;
}
-bool KAccelPrivate::connectKey( KAccelAction& action, const KKeyServer::Key& key )
+bool TDEAccelPrivate::connectKey( TDEAccelAction& action, const KKeyServer::Key& key )
{
uint keyQt = key.keyCodeQt();
int nID = ((TQAccel*)m_pAccel)->insertItem( keyQt );
@@ -246,23 +246,23 @@ bool KAccelPrivate::connectKey( KAccelAction& action, const KKeyServer::Key& key
((TQAccel*)m_pAccel)->setItemEnabled( nID, false );
}
- kdDebug(125) << "KAccelPrivate::connectKey( \"" << action.name() << "\", " << key.key().toStringInternal() << " = 0x" << TQString::number(keyQt,16) << " ): id = " << nID << " m_pObjSlot = " << action.objSlotPtr() << endl;
+ kdDebug(125) << "TDEAccelPrivate::connectKey( \"" << action.name() << "\", " << key.key().toStringInternal() << " = 0x" << TQString::number(keyQt,16) << " ): id = " << nID << " m_pObjSlot = " << action.objSlotPtr() << endl;
//kdDebug(125) << "m_pAccel = " << m_pAccel << endl;
return nID != 0;
}
-bool KAccelPrivate::connectKey( const KKeyServer::Key& key )
+bool TDEAccelPrivate::connectKey( const KKeyServer::Key& key )
{
uint keyQt = key.keyCodeQt();
int nID = ((TQAccel*)m_pAccel)->insertItem( keyQt );
m_mapIDToKey[nID] = keyQt;
- kdDebug(125) << "KAccelPrivate::connectKey( " << key.key().toStringInternal() << " = 0x" << TQString::number(keyQt,16) << " ): id = " << nID << endl;
+ kdDebug(125) << "TDEAccelPrivate::connectKey( " << key.key().toStringInternal() << " = 0x" << TQString::number(keyQt,16) << " ): id = " << nID << endl;
return nID != 0;
}
-bool KAccelPrivate::disconnectKey( KAccelAction& action, const KKeyServer::Key& key )
+bool TDEAccelPrivate::disconnectKey( TDEAccelAction& action, const KKeyServer::Key& key )
{
int keyQt = key.keyCodeQt();
TQMap<int, int>::iterator it = m_mapIDToKey.begin();
@@ -270,7 +270,7 @@ bool KAccelPrivate::disconnectKey( KAccelAction& action, const KKeyServer::Key&
//kdDebug(125) << "m_mapIDToKey[" << it.key() << "] = " << TQString::number(*it,16) << " == " << TQString::number(keyQt,16) << endl;
if( *it == keyQt ) {
int nID = it.key();
- kdDebug(125) << "KAccelPrivate::disconnectKey( \"" << action.name() << "\", 0x" << TQString::number(keyQt,16) << " ) : id = " << nID << " m_pObjSlot = " << action.objSlotPtr() << endl;
+ kdDebug(125) << "TDEAccelPrivate::disconnectKey( \"" << action.name() << "\", 0x" << TQString::number(keyQt,16) << " ) : id = " << nID << " m_pObjSlot = " << action.objSlotPtr() << endl;
((TQAccel*)m_pAccel)->removeItem( nID );
m_mapIDToAction.remove( nID );
m_mapIDToKey.remove( it );
@@ -282,10 +282,10 @@ bool KAccelPrivate::disconnectKey( KAccelAction& action, const KKeyServer::Key&
return false;
}
-bool KAccelPrivate::disconnectKey( const KKeyServer::Key& key )
+bool TDEAccelPrivate::disconnectKey( const KKeyServer::Key& key )
{
int keyQt = key.keyCodeQt();
- kdDebug(125) << "KAccelPrivate::disconnectKey( 0x" << TQString::number(keyQt,16) << " )" << endl;
+ kdDebug(125) << "TDEAccelPrivate::disconnectKey( 0x" << TQString::number(keyQt,16) << " )" << endl;
TQMap<int, int>::iterator it = m_mapIDToKey.begin();
for( ; it != m_mapIDToKey.end(); ++it ) {
if( *it == keyQt ) {
@@ -299,9 +299,9 @@ bool KAccelPrivate::disconnectKey( const KKeyServer::Key& key )
return false;
}
-void KAccelPrivate::slotKeyPressed( int id )
+void TDEAccelPrivate::slotKeyPressed( int id )
{
- kdDebug(125) << "KAccelPrivate::slotKeyPressed( " << id << " )" << endl;
+ kdDebug(125) << "TDEAccelPrivate::slotKeyPressed( " << id << " )" << endl;
if( m_mapIDToKey.contains( id ) ) {
KKey key = m_mapIDToKey[id];
@@ -326,14 +326,14 @@ void KAccelPrivate::slotKeyPressed( int id )
}
}
-void KAccelPrivate::slotShowMenu()
+void TDEAccelPrivate::slotShowMenu()
{
}
-void KAccelPrivate::slotMenuActivated( int iAction )
+void TDEAccelPrivate::slotMenuActivated( int iAction )
{
- kdDebug(125) << "KAccelPrivate::slotMenuActivated( " << iAction << " )" << endl;
- KAccelAction* pAction = actions().actionPtr( iAction );
+ kdDebug(125) << "TDEAccelPrivate::slotMenuActivated( " << iAction << " )" << endl;
+ TDEAccelAction* pAction = actions().actionPtr( iAction );
#ifdef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
if( pAction ) {
connect( this, TQT_SIGNAL(menuItemActivated()), pAction->objSlotPtr(), pAction->methodSlotPtr() );
@@ -345,12 +345,12 @@ void KAccelPrivate::slotMenuActivated( int iAction )
#endif
}
-bool KAccelPrivate::eventFilter( TQObject* /*pWatched*/, TQEvent* pEvent )
+bool TDEAccelPrivate::eventFilter( TQObject* /*pWatched*/, TQEvent* pEvent )
{
if( pEvent->type() == TQEvent::AccelOverride && m_bEnabled ) {
TQKeyEvent* pKeyEvent = (TQKeyEvent*) pEvent;
KKey key( pKeyEvent );
- kdDebug(125) << "KAccelPrivate::eventFilter( AccelOverride ): this = " << this << ", key = " << key.toStringInternal() << endl;
+ kdDebug(125) << "TDEAccelPrivate::eventFilter( AccelOverride ): this = " << this << ", key = " << key.toStringInternal() << endl;
int keyCodeQt = key.keyCodeQt();
TQMap<int, int>::iterator it = m_mapIDToKey.begin();
for( ; it != m_mapIDToKey.end(); ++it ) {
@@ -359,11 +359,11 @@ bool KAccelPrivate::eventFilter( TQObject* /*pWatched*/, TQEvent* pEvent )
kdDebug(125) << "shortcut found!" << endl;
if( m_mapIDToAction.contains( nID ) ) {
// TODO: reduce duplication between here and slotMenuActivated
- KAccelAction* pAction = m_mapIDToAction[nID];
+ TDEAccelAction* pAction = m_mapIDToAction[nID];
if( !pAction->isEnabled() )
continue;
#ifdef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
- TQGuardedPtr<KAccelPrivate> me = this;
+ TQGuardedPtr<TDEAccelPrivate> me = this;
connect( this, TQT_SIGNAL(menuItemActivated()), pAction->objSlotPtr(), pAction->methodSlotPtr() );
emit menuItemActivated();
if (me) {
@@ -376,7 +376,7 @@ bool KAccelPrivate::eventFilter( TQObject* /*pWatched*/, TQEvent* pEvent )
slotKeyPressed( nID );
pKeyEvent->accept();
- KAccelEventHandler::accelActivated( true );
+ TDEAccelEventHandler::accelActivated( true );
return true;
}
}
@@ -385,17 +385,17 @@ bool KAccelPrivate::eventFilter( TQObject* /*pWatched*/, TQEvent* pEvent )
}
#ifndef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
-void KAccelPrivate::emitActivatedSignal( KAccelAction* pAction )
+void TDEAccelPrivate::emitActivatedSignal( TDEAccelAction* pAction )
{
if( pAction ) {
- TQGuardedPtr<KAccelPrivate> me = this;
- TQRegExp reg( "([ ]*KAccelAction.*)" );
+ TQGuardedPtr<TDEAccelPrivate> me = this;
+ TQRegExp reg( "([ ]*TDEAccelAction.*)" );
if( reg.search( pAction->methodSlotPtr()) >= 0 ) {
- connect( this, TQT_SIGNAL(menuItemActivated(KAccelAction*)),
+ connect( this, TQT_SIGNAL(menuItemActivated(TDEAccelAction*)),
pAction->objSlotPtr(), pAction->methodSlotPtr() );
emit menuItemActivated( pAction );
if (me)
- disconnect( me, TQT_SIGNAL(menuItemActivated(KAccelAction*)),
+ disconnect( me, TQT_SIGNAL(menuItemActivated(TDEAccelAction*)),
pAction->objSlotPtr(), pAction->methodSlotPtr() );
} else {
connect( this, TQT_SIGNAL(menuItemActivated()),
@@ -411,39 +411,39 @@ void KAccelPrivate::emitActivatedSignal( KAccelAction* pAction )
#endif
//---------------------------------------------------------------------
-// KAccel
+// TDEAccel
//---------------------------------------------------------------------
-KAccel::KAccel( TQWidget* pParent, const char* psName )
-: TQAccel( pParent, (psName) ? psName : "KAccel-TQAccel" )
+TDEAccel::TDEAccel( TQWidget* pParent, const char* psName )
+: TQAccel( pParent, (psName) ? psName : "TDEAccel-TQAccel" )
{
- kdDebug(125) << "KAccel( pParent = " << pParent << ", psName = " << psName << " ): this = " << this << endl;
- d = new KAccelPrivate( this, pParent );
+ kdDebug(125) << "TDEAccel( pParent = " << pParent << ", psName = " << psName << " ): this = " << this << endl;
+ d = new TDEAccelPrivate( this, pParent );
}
-KAccel::KAccel( TQWidget* watch, TQObject* pParent, const char* psName )
-: TQAccel( watch, pParent, (psName) ? psName : "KAccel-TQAccel" )
+TDEAccel::TDEAccel( TQWidget* watch, TQObject* pParent, const char* psName )
+: TQAccel( watch, pParent, (psName) ? psName : "TDEAccel-TQAccel" )
{
- kdDebug(125) << "KAccel( watch = " << watch << ", pParent = " << pParent << ", psName = " << psName << " ): this = " << this << endl;
+ kdDebug(125) << "TDEAccel( watch = " << watch << ", pParent = " << pParent << ", psName = " << psName << " ): this = " << this << endl;
if( !watch )
kdDebug(125) << kdBacktrace() << endl;
- d = new KAccelPrivate( this, watch );
+ d = new TDEAccelPrivate( this, watch );
}
-KAccel::~KAccel()
+TDEAccel::~TDEAccel()
{
- kdDebug(125) << "~KAccel(): this = " << this << endl;
+ kdDebug(125) << "~TDEAccel(): this = " << this << endl;
delete d;
}
-KAccelActions& KAccel::actions() { return d->actions(); }
-const KAccelActions& KAccel::actions() const { return d->actions(); }
-bool KAccel::isEnabled() { return d->isEnabled(); }
-void KAccel::setEnabled( bool bEnabled ) { d->setEnabled( bEnabled ); }
-bool KAccel::setAutoUpdate( bool bAuto ) { return d->setAutoUpdate( bAuto ); }
+TDEAccelActions& TDEAccel::actions() { return d->actions(); }
+const TDEAccelActions& TDEAccel::actions() const { return d->actions(); }
+bool TDEAccel::isEnabled() { return d->isEnabled(); }
+void TDEAccel::setEnabled( bool bEnabled ) { d->setEnabled( bEnabled ); }
+bool TDEAccel::setAutoUpdate( bool bAuto ) { return d->setAutoUpdate( bAuto ); }
-KAccelAction* KAccel::insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& cutDef,
+TDEAccelAction* TDEAccel::insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& cutDef,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
@@ -453,8 +453,8 @@ KAccelAction* KAccel::insert( const TQString& sAction, const TQString& sLabel, c
bConfigurable, bEnabled );
}
-KAccelAction* KAccel::insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& cutDef3, const KShortcut& cutDef4,
+TDEAccelAction* TDEAccel::insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& cutDef3, const TDEShortcut& cutDef4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
@@ -464,7 +464,7 @@ KAccelAction* KAccel::insert( const TQString& sAction, const TQString& sLabel, c
bConfigurable, bEnabled );
}
-KAccelAction* KAccel::insert( const char* psAction, const KShortcut& cutDef,
+TDEAccelAction* TDEAccel::insert( const char* psAction, const TDEShortcut& cutDef,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
@@ -474,45 +474,45 @@ KAccelAction* KAccel::insert( const char* psAction, const KShortcut& cutDef,
bConfigurable, bEnabled );
}
-KAccelAction* KAccel::insert( KStdAccel::StdAccel id,
+TDEAccelAction* TDEAccel::insert( TDEStdAccel::StdAccel id,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
- TQString sAction = KStdAccel::name( id );
+ TQString sAction = TDEStdAccel::name( id );
if( sAction.isEmpty() )
return 0;
- KAccelAction* pAction = d->insert( sAction, KStdAccel::label( id ), KStdAccel::whatsThis( id ),
- KStdAccel::shortcutDefault3( id ), KStdAccel::shortcutDefault4( id ),
+ TDEAccelAction* pAction = d->insert( sAction, TDEStdAccel::label( id ), TDEStdAccel::whatsThis( id ),
+ TDEStdAccel::shortcutDefault3( id ), TDEStdAccel::shortcutDefault4( id ),
pObjSlot, psMethodSlot,
bConfigurable, bEnabled );
if( pAction )
- pAction->setShortcut( KStdAccel::shortcut( id ) );
+ pAction->setShortcut( TDEStdAccel::shortcut( id ) );
return pAction;
}
-bool KAccel::remove( const TQString& sAction )
+bool TDEAccel::remove( const TQString& sAction )
{ return d->removeAction( sAction ); }
-bool KAccel::updateConnections()
+bool TDEAccel::updateConnections()
{ return d->updateConnections(); }
-const KShortcut& KAccel::shortcut( const TQString& sAction ) const
+const TDEShortcut& TDEAccel::shortcut( const TQString& sAction ) const
{
- const KAccelAction* pAction = actions().actionPtr( sAction );
- return (pAction) ? pAction->shortcut() : KShortcut::null();
+ const TDEAccelAction* pAction = actions().actionPtr( sAction );
+ return (pAction) ? pAction->shortcut() : TDEShortcut::null();
}
-bool KAccel::setSlot( const TQString& sAction, const TQObject* pObjSlot, const char* psMethodSlot )
+bool TDEAccel::setSlot( const TQString& sAction, const TQObject* pObjSlot, const char* psMethodSlot )
{ return d->setActionSlot( sAction, pObjSlot, psMethodSlot ); }
-bool KAccel::setEnabled( const TQString& sAction, bool bEnable )
+bool TDEAccel::setEnabled( const TQString& sAction, bool bEnable )
{ return d->setEnabled( sAction, bEnable ); }
-bool KAccel::setShortcut( const TQString& sAction, const KShortcut& cut )
+bool TDEAccel::setShortcut( const TQString& sAction, const TDEShortcut& cut )
{
- kdDebug(125) << "KAccel::setShortcut( \"" << sAction << "\", " << cut.toStringInternal() << " )" << endl;
- KAccelAction* pAction = actions().actionPtr( sAction );
+ kdDebug(125) << "TDEAccel::setShortcut( \"" << sAction << "\", " << cut.toStringInternal() << " )" << endl;
+ TDEAccelAction* pAction = actions().actionPtr( sAction );
if( pAction ) {
if( pAction->shortcut() != cut )
return d->setShortcut( sAction, cut );
@@ -521,24 +521,24 @@ bool KAccel::setShortcut( const TQString& sAction, const KShortcut& cut )
return false;
}
-const TQString& KAccel::configGroup() const
+const TQString& TDEAccel::configGroup() const
{ return d->configGroup(); }
// for tdegames/ksirtet
-void KAccel::setConfigGroup( const TQString& s )
+void TDEAccel::setConfigGroup( const TQString& s )
{ d->setConfigGroup( s ); }
-bool KAccel::readSettings( TDEConfigBase* pConfig )
+bool TDEAccel::readSettings( TDEConfigBase* pConfig )
{
d->readSettings( pConfig );
return true;
}
-bool KAccel::writeSettings( TDEConfigBase* pConfig ) const
+bool TDEAccel::writeSettings( TDEConfigBase* pConfig ) const
{ d->writeSettings( pConfig ); return true; }
-void KAccel::emitKeycodeChanged()
+void TDEAccel::emitKeycodeChanged()
{
- kdDebug(125) << "KAccel::emitKeycodeChanged()" << endl;
+ kdDebug(125) << "TDEAccel::emitKeycodeChanged()" << endl;
emit keycodeChanged();
}
@@ -547,11 +547,11 @@ void KAccel::emitKeycodeChanged()
// Obsolete methods -- for backward compatibility
//------------------------------------------------------------
-bool KAccel::insertItem( const TQString& sLabel, const TQString& sAction,
+bool TDEAccel::insertItem( const TQString& sLabel, const TQString& sAction,
const char* cutsDef,
int /*nIDMenu*/, TQPopupMenu *, bool bConfigurable )
{
- KShortcut cut( cutsDef );
+ TDEShortcut cut( cutsDef );
bool b = d->insert( sAction, sLabel, TQString::null,
cut, cut,
0, 0,
@@ -559,13 +559,13 @@ bool KAccel::insertItem( const TQString& sLabel, const TQString& sAction,
return b;
}
-bool KAccel::insertItem( const TQString& sLabel, const TQString& sAction,
+bool TDEAccel::insertItem( const TQString& sLabel, const TQString& sAction,
int key,
int /*nIDMenu*/, TQPopupMenu*, bool bConfigurable )
{
- KShortcut cut;
+ TDEShortcut cut;
cut.init( TQKeySequence(key) );
- KAccelAction* pAction = d->insert( sAction, sLabel, TQString::null,
+ TDEAccelAction* pAction = d->insert( sAction, sLabel, TQString::null,
cut, cut,
0, 0,
bConfigurable );
@@ -573,20 +573,20 @@ bool KAccel::insertItem( const TQString& sLabel, const TQString& sAction,
}
// Used in tdeutils/kjots
-bool KAccel::insertStdItem( KStdAccel::StdAccel id, const TQString& sLabel )
+bool TDEAccel::insertStdItem( TDEStdAccel::StdAccel id, const TQString& sLabel )
{
- KAccelAction* pAction = d->insert( KStdAccel::name( id ), sLabel, TQString::null,
- KStdAccel::shortcutDefault3( id ), KStdAccel::shortcutDefault4( id ),
+ TDEAccelAction* pAction = d->insert( TDEStdAccel::name( id ), sLabel, TQString::null,
+ TDEStdAccel::shortcutDefault3( id ), TDEStdAccel::shortcutDefault4( id ),
0, 0 );
if( pAction )
- pAction->setShortcut( KStdAccel::shortcut( id ) );
+ pAction->setShortcut( TDEStdAccel::shortcut( id ) );
return true;
}
-bool KAccel::connectItem( const TQString& sAction, const TQObject* pObjSlot, const char* psMethodSlot, bool bActivate )
+bool TDEAccel::connectItem( const TQString& sAction, const TQObject* pObjSlot, const char* psMethodSlot, bool bActivate )
{
- kdDebug(125) << "KAccel::connectItem( " << sAction << ", " << pObjSlot << ", " << psMethodSlot << " )" << endl;
+ kdDebug(125) << "TDEAccel::connectItem( " << sAction << ", " << pObjSlot << ", " << psMethodSlot << " )" << endl;
if( bActivate == false )
d->setActionEnabled( sAction, false );
bool b = setSlot( sAction, pObjSlot, psMethodSlot );
@@ -595,15 +595,15 @@ bool KAccel::connectItem( const TQString& sAction, const TQObject* pObjSlot, con
return b;
}
-bool KAccel::removeItem( const TQString& sAction )
+bool TDEAccel::removeItem( const TQString& sAction )
{ return d->removeAction( sAction ); }
-bool KAccel::setItemEnabled( const TQString& sAction, bool bEnable )
+bool TDEAccel::setItemEnabled( const TQString& sAction, bool bEnable )
{ return setEnabled( sAction, bEnable ); }
-void KAccel::changeMenuAccel( TQPopupMenu *menu, int id, const TQString& action )
+void TDEAccel::changeMenuAccel( TQPopupMenu *menu, int id, const TQString& action )
{
- KAccelAction* pAction = actions().actionPtr( action );
+ TDEAccelAction* pAction = actions().actionPtr( action );
TQString s = menu->text( id );
if( !pAction || s.isEmpty() )
return;
@@ -628,27 +628,27 @@ void KAccel::changeMenuAccel( TQPopupMenu *menu, int id, const TQString& action
menu->changeItem( s, id );
}
-void KAccel::changeMenuAccel( TQPopupMenu *menu, int id, KStdAccel::StdAccel accel )
+void TDEAccel::changeMenuAccel( TQPopupMenu *menu, int id, TDEStdAccel::StdAccel accel )
{
- changeMenuAccel( menu, id, KStdAccel::name( accel ) );
+ changeMenuAccel( menu, id, TDEStdAccel::name( accel ) );
}
-int KAccel::stringToKey( const TQString& sKey )
+int TDEAccel::stringToKey( const TQString& sKey )
{
return KKey( sKey ).keyCodeQt();
}
-int KAccel::currentKey( const TQString& sAction ) const
+int TDEAccel::currentKey( const TQString& sAction ) const
{
- KAccelAction* pAction = d->actionPtr( sAction );
+ TDEAccelAction* pAction = d->actionPtr( sAction );
if( pAction )
return pAction->shortcut().keyCodeQt();
return 0;
}
-TQString KAccel::findKey( int key ) const
+TQString TDEAccel::findKey( int key ) const
{
- KAccelAction* pAction = d->actionPtr( KKey(key) );
+ TDEAccelAction* pAction = d->actionPtr( KKey(key) );
if( pAction )
return pAction->name();
else
@@ -656,7 +656,7 @@ TQString KAccel::findKey( int key ) const
}
#endif // !KDE_NO_COMPAT
-void KAccel::virtual_hook( int, void* )
+void TDEAccel::virtual_hook( int, void* )
{ /*BASE::virtual_hook( id, data );*/ }
#include "kaccel.moc"
diff --git a/tdecore/kaccel.h b/tdecore/kaccel.h
index 491fa39ce..8a3f2d499 100644
--- a/tdecore/kaccel.h
+++ b/tdecore/kaccel.h
@@ -27,11 +27,11 @@
class TQPopupMenu; // for obsolete insertItem() methods below
class TQWidget;
-class KAccelAction;
-class KAccelActions;
+class TDEAccelAction;
+class TDEAccelActions;
class TDEConfigBase;
-class KAccelPrivate;
+class TDEAccelPrivate;
/**
* Handle shortcuts.
*
@@ -39,17 +39,17 @@ class KAccelPrivate;
* through application configuration files or through the
* KKeyChooser GUI.
*
- * A KAccel contains a list of accelerator actions.
+ * A TDEAccel contains a list of accelerator actions.
*
* For example, CTRL+Key_P could be a shortcut for printing a document. The key
* codes are listed in tqnamespace.h. "Print" could be the action name for printing.
* The action name identifies the shortcut in configuration files and the
* KKeyChooser GUI.
*
- * A KAccel object handles key events sent to its parent widget and to all
- * children of this parent widget. The most recently created KAccel object
- * has precedence over any KAccel objects created before it.
- * When a shortcut pressed, KAccel calls the slot to which it has been
+ * A TDEAccel object handles key events sent to its parent widget and to all
+ * children of this parent widget. The most recently created TDEAccel object
+ * has precedence over any TDEAccel objects created before it.
+ * When a shortcut pressed, TDEAccel calls the slot to which it has been
* connected. If you want to set global accelerators, independent of the window
* which has the focus, use TDEGlobalAccel.
*
@@ -69,14 +69,14 @@ class KAccelPrivate;
* The translated first argument for insertItem() is used only
* in the configuration dialog.
*\code
- * KAccel* pAccel = new KAccel( this );
+ * TDEAccel* pAccel = new TDEAccel( this );
*
* // Insert an action "Scroll Up" which is associated with the "Up" key:
* pAccel->insert( "Scroll Up", i18n("Scroll up"),
* i18n("Scroll up the current document by one line."),
* Qt::Key_Up, this, TQT_SLOT(slotScrollUp()) );
* // Insert an standard acclerator action.
- * pAccel->insert( KStdAccel::Print, this, TQT_SLOT(slotPrint()) );
+ * pAccel->insert( TDEStdAccel::Print, this, TQT_SLOT(slotPrint()) );
*
* // Update the shortcuts by read any user-defined settings from the
* // application's config file.
@@ -85,56 +85,56 @@ class KAccelPrivate;
*
* @short Configurable shortcut support for widgets.
* @see TDEGlobalAccel
- * @see KAccelShortcutList
+ * @see TDEAccelShortcutList
* @see KKeyChooser
* @see KKeyDialog
*/
-class TDECORE_EXPORT KAccel : public TQAccel
+class TDECORE_EXPORT TDEAccel : public TQAccel
{
Q_OBJECT
public:
/**
- * Creates a new KAccel that watches @p pParent, which is also
+ * Creates a new TDEAccel that watches @p pParent, which is also
* the QObject's parent.
*
* @param pParent the parent and widget to watch for key strokes
* @param psName the name of the QObject
*/
- KAccel( TQWidget* pParent, const char* psName = 0 );
+ TDEAccel( TQWidget* pParent, const char* psName = 0 );
/**
- * Creates a new KAccel that watches @p watch.
+ * Creates a new TDEAccel that watches @p watch.
*
* @param watch the widget to watch for key strokes
* @param parent the parent of the QObject
* @param psName the name of the QObject
*/
- KAccel( TQWidget* watch, TQObject* parent, const char* psName = 0 );
- virtual ~KAccel();
+ TDEAccel( TQWidget* watch, TQObject* parent, const char* psName = 0 );
+ virtual ~TDEAccel();
/**
* @internal
- * Returns the KAccel's @p KAccelActions, a list of @p KAccelAction.
- * @return the KAccelActions of the KAccel
+ * Returns the TDEAccel's @p TDEAccelActions, a list of @p TDEAccelAction.
+ * @return the TDEAccelActions of the TDEAccel
*/
- KAccelActions& actions();
+ TDEAccelActions& actions();
/**
* @internal
- * Returns the KAccel's @p KAccelActions, a list of @p KAccelAction.
- * @return the KAccelActions of the KAccel
+ * Returns the TDEAccel's @p TDEAccelActions, a list of @p TDEAccelAction.
+ * @return the TDEAccelActions of the TDEAccel
*/
- const KAccelActions& actions() const;
+ const TDEAccelActions& actions() const;
/**
- * Checks whether the KAccel is active.
+ * Checks whether the TDEAccel is active.
* @return true if the TQAccel is enabled
*/
bool isEnabled();
/**
- * Enables or disables the KAccel.
+ * Enables or disables the TDEAccel.
* @param bEnabled true to enable, false to disable
*/
void setEnabled( bool bEnabled );
@@ -172,16 +172,16 @@ class TDECORE_EXPORT KAccel : public TQAccel
* @param bConfigurable Allow the user to change this shortcut if set to 'true'.
* @param bEnabled The action will be activated by the shortcut if set to 'true'.
*/
- KAccelAction* insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& cutDef,
+ TDEAccelAction* insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& cutDef,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable = true, bool bEnabled = true );
/**
* Same as first insert(), but with separate shortcuts defined for
* 3- and 4- modifier defaults.
*/
- KAccelAction* insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& cutDef3, const KShortcut& cutDef4,
+ TDEAccelAction* insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& cutDef3, const TDEShortcut& cutDef4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable = true, bool bEnabled = true );
/**
@@ -201,16 +201,16 @@ class TDECORE_EXPORT KAccel : public TQAccel
* @param bConfigurable Allow the user to change this shortcut if set to 'true'.
* @param bEnabled The action will be activated by the shortcut if set to 'true'.
*/
- KAccelAction* insert( const char* psAction, const KShortcut& cutDef,
+ TDEAccelAction* insert( const char* psAction, const TDEShortcut& cutDef,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable = true, bool bEnabled = true );
/**
* Similar to the first insert() method, but with the action
* name, short description, help text, and default shortcuts all
* set according to one of the standard accelerators.
- * @see KStdAccel.
+ * @see TDEStdAccel.
*/
- KAccelAction* insert( KStdAccel::StdAccel id,
+ TDEAccelAction* insert( TDEStdAccel::StdAccel id,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable = true, bool bEnabled = true );
@@ -237,7 +237,7 @@ class TDECORE_EXPORT KAccel : public TQAccel
* @param sAction the name of the action
* @return the action's shortcut, or a null shortcut if not found
*/
- const KShortcut& shortcut( const TQString& sAction ) const;
+ const TDEShortcut& shortcut( const TQString& sAction ) const;
/**
* Set the shortcut to be associated with the action named by @p sAction.
@@ -245,7 +245,7 @@ class TDECORE_EXPORT KAccel : public TQAccel
* @param shortcut the shortcut to set
* @return true if successful, false otherwise
*/
- bool setShortcut( const TQString& sAction, const KShortcut &shortcut );
+ bool setShortcut( const TQString& sAction, const TDEShortcut &shortcut );
/**
* Set the slot to be called when the shortcut of the action named
@@ -329,7 +329,7 @@ class TDECORE_EXPORT KAccel : public TQAccel
/**
* @deprecated use insert
*/
- bool insertStdItem( KStdAccel::StdAccel id, const TQString& descr = TQString::null ) KDE_DEPRECATED;
+ bool insertStdItem( TDEStdAccel::StdAccel id, const TQString& descr = TQString::null ) KDE_DEPRECATED;
/**
* @deprecated use insert
*/
@@ -338,7 +338,7 @@ class TDECORE_EXPORT KAccel : public TQAccel
* @deprecated use insert( accel, pObjSlot, psMethodSlot );
*
*/
- KDE_DEPRECATED bool connectItem( KStdAccel::StdAccel accel, const TQObject* pObjSlot, const char* psMethodSlot )
+ KDE_DEPRECATED bool connectItem( TDEStdAccel::StdAccel accel, const TQObject* pObjSlot, const char* psMethodSlot )
{ return insert( accel, pObjSlot, psMethodSlot ); }
/**
* @deprecated use remove
@@ -355,7 +355,7 @@ class TDECORE_EXPORT KAccel : public TQAccel
/**
* @deprecated see KDE3PORTING.html
*/
- void changeMenuAccel( TQPopupMenu *menu, int id, KStdAccel::StdAccel accel ) KDE_DEPRECATED;
+ void changeMenuAccel( TQPopupMenu *menu, int id, TDEStdAccel::StdAccel accel ) KDE_DEPRECATED;
/**
* @deprecated
*/
@@ -383,8 +383,8 @@ class TDECORE_EXPORT KAccel : public TQAccel
/** \internal */
virtual void virtual_hook( int id, void* data );
private:
- class KAccelPrivate* d;
- friend class KAccelPrivate;
+ class TDEAccelPrivate* d;
+ friend class TDEAccelPrivate;
};
#endif // _KACCEL_H
diff --git a/tdecore/kaccelaction.cpp b/tdecore/kaccelaction.cpp
index 34448fe90..d3ec59be3 100644
--- a/tdecore/kaccelaction.cpp
+++ b/tdecore/kaccelaction.cpp
@@ -21,7 +21,7 @@
*/
#include "kaccelaction.h"
-#include "kaccelbase.h" // for KAccelBase::slotRemoveAction() & emitSignal()
+#include "kaccelbase.h" // for TDEAccelBase::slotRemoveAction() & emitSignal()
#include <tqkeycode.h>
@@ -34,19 +34,19 @@
#include <kshortcutlist.h>
//---------------------------------------------------------------------
-// KAccelAction
+// TDEAccelAction
//---------------------------------------------------------------------
-class KAccelActionPrivate
+class TDEAccelActionPrivate
{
public:
uint m_nConnections;
};
-KAccelAction::KAccelAction()
+TDEAccelAction::TDEAccelAction()
{
- //kdDebug(125) << "KAccelAction(): this = " << this << endl;
- d = new KAccelActionPrivate;
+ //kdDebug(125) << "TDEAccelAction(): this = " << this << endl;
+ d = new TDEAccelActionPrivate;
m_pObjSlot = 0;
m_psMethodSlot = 0;
m_bConfigurable = true;
@@ -55,33 +55,33 @@ KAccelAction::KAccelAction()
d->m_nConnections = 0;
}
-KAccelAction::KAccelAction( const KAccelAction& action )
+TDEAccelAction::TDEAccelAction( const TDEAccelAction& action )
{
- //kdDebug(125) << "KAccelAction( copy from \"" << action.m_sName << "\" ): this = " << this << endl;
- d = new KAccelActionPrivate;
+ //kdDebug(125) << "TDEAccelAction( copy from \"" << action.m_sName << "\" ): this = " << this << endl;
+ d = new TDEAccelActionPrivate;
*this = action;
}
-KAccelAction::KAccelAction( const TQString& sName, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& cutDef3, const KShortcut& cutDef4,
+TDEAccelAction::TDEAccelAction( const TQString& sName, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& cutDef3, const TDEShortcut& cutDef4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
- //kdDebug(125) << "KAccelAction( \"" << sName << "\" ): this = " << this << endl;
- d = new KAccelActionPrivate;
+ //kdDebug(125) << "TDEAccelAction( \"" << sName << "\" ): this = " << this << endl;
+ d = new TDEAccelActionPrivate;
init( sName, sLabel, sWhatsThis,
cutDef3, cutDef4,
pObjSlot, psMethodSlot,
bConfigurable, bEnabled );
}
-KAccelAction::~KAccelAction()
+TDEAccelAction::~TDEAccelAction()
{
- //kdDebug(125) << "\t\t\tKAccelAction::~KAccelAction( \"" << m_sName << "\" ): this = " << this << endl;
+ //kdDebug(125) << "\t\t\tTDEAccelAction::~TDEAccelAction( \"" << m_sName << "\" ): this = " << this << endl;
delete d;
}
-void KAccelAction::clear()
+void TDEAccelAction::clear()
{
m_cut.clear();
m_pObjSlot = 0;
@@ -92,8 +92,8 @@ void KAccelAction::clear()
d->m_nConnections = 0;
}
-bool KAccelAction::init( const TQString& sName, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& rgCutDefaults3, const KShortcut& rgCutDefaults4,
+bool TDEAccelAction::init( const TQString& sName, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& rgCutDefaults3, const TDEShortcut& rgCutDefaults4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
@@ -110,11 +110,11 @@ bool KAccelAction::init( const TQString& sName, const TQString& sLabel, const TQ
m_cut = shortcutDefault();
d->m_nConnections = 0;
if( !m_bEnabled )
- kdDebug(125) << "KAccelAction::init( \"" << sName << "\" ): created with enabled = false" << endl;
+ kdDebug(125) << "TDEAccelAction::init( \"" << sName << "\" ): created with enabled = false" << endl;
return true;
}
-KAccelAction& KAccelAction::operator =( const KAccelAction& action )
+TDEAccelAction& TDEAccelAction::operator =( const TDEAccelAction& action )
{
m_sName = action.m_sName;
m_sLabel = action.m_sLabel;
@@ -132,37 +132,37 @@ KAccelAction& KAccelAction::operator =( const KAccelAction& action )
return *this;
}
-void KAccelAction::setName( const TQString& s )
+void TDEAccelAction::setName( const TQString& s )
{ m_sName = s; }
-void KAccelAction::setLabel( const TQString& s )
+void TDEAccelAction::setLabel( const TQString& s )
{ m_sLabel = s; }
-void KAccelAction::setWhatsThis( const TQString& s )
+void TDEAccelAction::setWhatsThis( const TQString& s )
{ m_sWhatsThis = s; }
-bool KAccelAction::setShortcut( const KShortcut& cut )
+bool TDEAccelAction::setShortcut( const TDEShortcut& cut )
{
m_cut = cut;
return true;
}
-void KAccelAction::setSlot( const TQObject* pObjSlot, const char* psMethodSlot )
+void TDEAccelAction::setSlot( const TQObject* pObjSlot, const char* psMethodSlot )
{
m_pObjSlot = pObjSlot;
m_psMethodSlot = psMethodSlot;
}
-void KAccelAction::setConfigurable( bool b )
+void TDEAccelAction::setConfigurable( bool b )
{ m_bConfigurable = b; }
-void KAccelAction::setEnabled( bool b )
+void TDEAccelAction::setEnabled( bool b )
{ m_bEnabled = b; }
-TQString KAccelAction::toString() const
+TQString TDEAccelAction::toString() const
{ return m_cut.toString(); }
-TQString KAccelAction::toStringInternal() const
+TQString TDEAccelAction::toStringInternal() const
{ return m_cut.toStringInternal( &shortcutDefault() ); }
-bool KAccelAction::setKeySequence( uint i, const KKeySequence& seq )
+bool TDEAccelAction::setKeySequence( uint i, const KKeySequence& seq )
{
if( i < m_cut.count() ) {
m_cut.setSeq( i, seq );
@@ -172,12 +172,12 @@ bool KAccelAction::setKeySequence( uint i, const KKeySequence& seq )
return false;
}
-void KAccelAction::clearShortcut()
+void TDEAccelAction::clearShortcut()
{
m_cut.clear();
}
-bool KAccelAction::contains( const KKeySequence& seq )
+bool TDEAccelAction::contains( const KKeySequence& seq )
{
return m_cut.contains( seq );
for( uint i = 0; i < m_cut.count(); i++ ) {
@@ -187,90 +187,90 @@ bool KAccelAction::contains( const KKeySequence& seq )
return false;
}
-const KShortcut& KAccelAction::shortcutDefault() const
+const TDEShortcut& TDEAccelAction::shortcutDefault() const
{ return (useFourModifierKeys()) ? m_cutDefault4 : m_cutDefault3; }
-bool KAccelAction::isConnected() const
+bool TDEAccelAction::isConnected() const
{ return d->m_nConnections; }
-void KAccelAction::incConnections()
+void TDEAccelAction::incConnections()
{ d->m_nConnections++; }
-void KAccelAction::decConnections()
+void TDEAccelAction::decConnections()
{ if( d->m_nConnections > 0 ) d->m_nConnections--; }
// Indicate whether to default to the 3- or 4- modifier keyboard schemes
-int KAccelAction::g_bUseFourModifierKeys = -1;
+int TDEAccelAction::g_bUseFourModifierKeys = -1;
-bool KAccelAction::useFourModifierKeys()
+bool TDEAccelAction::useFourModifierKeys()
{
- if( KAccelAction::g_bUseFourModifierKeys == -1 ) {
+ if( TDEAccelAction::g_bUseFourModifierKeys == -1 ) {
// Read in whether to use 4 modifier keys
TDEConfigGroupSaver cgs( TDEGlobal::config(), "Keyboard" );
bool b = TDEGlobal::config()->readBoolEntry( "Use Four Modifier Keys", false );
- KAccelAction::g_bUseFourModifierKeys = b && KKeyNative::keyboardHasWinKey();
+ TDEAccelAction::g_bUseFourModifierKeys = b && KKeyNative::keyboardHasWinKey();
}
- return KAccelAction::g_bUseFourModifierKeys == 1;
+ return TDEAccelAction::g_bUseFourModifierKeys == 1;
}
-void KAccelAction::useFourModifierKeys( bool b )
+void TDEAccelAction::useFourModifierKeys( bool b )
{
- if( KAccelAction::g_bUseFourModifierKeys != (int)b ) {
- KAccelAction::g_bUseFourModifierKeys = b && KKeyNative::keyboardHasWinKey();
+ if( TDEAccelAction::g_bUseFourModifierKeys != (int)b ) {
+ TDEAccelAction::g_bUseFourModifierKeys = b && KKeyNative::keyboardHasWinKey();
// If we're 'turning off' the meta key or, if we're turning it on,
// the keyboard must actually have a meta key.
if( b && !KKeyNative::keyboardHasWinKey() )
kdDebug(125) << "Tried to use four modifier keys on a keyboard layout without a Meta key.\n";
}
TDEConfigGroupSaver cgs( TDEGlobal::config(), "Keyboard" );
- TDEGlobal::config()->writeEntry( "Use Four Modifier Keys", KAccelAction::g_bUseFourModifierKeys, true, true);
+ TDEGlobal::config()->writeEntry( "Use Four Modifier Keys", TDEAccelAction::g_bUseFourModifierKeys, true, true);
- kdDebug(125) << "bUseFourModifierKeys = " << KAccelAction::g_bUseFourModifierKeys << endl;
+ kdDebug(125) << "bUseFourModifierKeys = " << TDEAccelAction::g_bUseFourModifierKeys << endl;
}
//---------------------------------------------------------------------
-// KAccelActions
+// TDEAccelActions
//---------------------------------------------------------------------
-class KAccelActionsPrivate
+class TDEAccelActionsPrivate
{
public:
};
-KAccelActions::KAccelActions()
+TDEAccelActions::TDEAccelActions()
{
- kdDebug(125) << "KAccelActions(): this = " << this << endl;
+ kdDebug(125) << "TDEAccelActions(): this = " << this << endl;
initPrivate( 0 );
}
-KAccelActions::KAccelActions( const KAccelActions& actions )
+TDEAccelActions::TDEAccelActions( const TDEAccelActions& actions )
{
- kdDebug(125) << "KAccelActions( actions = " << &actions << " ): this = " << this << endl;
+ kdDebug(125) << "TDEAccelActions( actions = " << &actions << " ): this = " << this << endl;
initPrivate( 0 );
init( actions );
}
-KAccelActions::KAccelActions( KAccelBase* pKAccelBase )
+TDEAccelActions::TDEAccelActions( TDEAccelBase* pTDEAccelBase )
{
- kdDebug(125) << "KAccelActions( KAccelBase = " << pKAccelBase << " ): this = " << this << endl;
- initPrivate( pKAccelBase );
+ kdDebug(125) << "TDEAccelActions( TDEAccelBase = " << pTDEAccelBase << " ): this = " << this << endl;
+ initPrivate( pTDEAccelBase );
}
-KAccelActions::~KAccelActions()
+TDEAccelActions::~TDEAccelActions()
{
- //kdDebug(125) << "KAccelActions::~KAccelActions(): this = " << this << endl;
+ //kdDebug(125) << "TDEAccelActions::~TDEAccelActions(): this = " << this << endl;
clear();
//delete d;
}
-void KAccelActions::initPrivate( KAccelBase* pKAccelBase )
+void TDEAccelActions::initPrivate( TDEAccelBase* pTDEAccelBase )
{
- m_pKAccelBase = pKAccelBase;
+ m_pTDEAccelBase = pTDEAccelBase;
m_nSizeAllocated = m_nSize = 0;
m_prgActions = 0;
- //d = new KAccelActionsPrivate;
+ //d = new TDEAccelActionsPrivate;
}
-void KAccelActions::clear()
+void TDEAccelActions::clear()
{
- kdDebug(125) << "\tKAccelActions::clear()" << endl;
+ kdDebug(125) << "\tTDEAccelActions::clear()" << endl;
for( uint i = 0; i < m_nSize; i++ )
delete m_prgActions[i];
delete[] m_prgActions;
@@ -279,14 +279,14 @@ void KAccelActions::clear()
m_prgActions = 0;
}
-bool KAccelActions::init( const KAccelActions& actions )
+bool TDEAccelActions::init( const TDEAccelActions& actions )
{
clear();
resize( actions.count() );
for( uint i = 0; i < m_nSize; i++ ) {
- KAccelAction* pAction = actions.m_prgActions[i];
+ TDEAccelAction* pAction = actions.m_prgActions[i];
if( pAction )
- m_prgActions[i] = new KAccelAction( *pAction );
+ m_prgActions[i] = new TDEAccelAction( *pAction );
else
m_prgActions[i] = 0;
}
@@ -294,22 +294,22 @@ bool KAccelActions::init( const KAccelActions& actions )
return true;
}
-bool KAccelActions::init( TDEConfigBase& config, const TQString& sGroup )
+bool TDEAccelActions::init( TDEConfigBase& config, const TQString& sGroup )
{
- kdDebug(125) << "KAccelActions::init( " << sGroup << " )" << endl;
+ kdDebug(125) << "TDEAccelActions::init( " << sGroup << " )" << endl;
TQMap<TQString, TQString> mapEntry = config.entryMap( sGroup );
resize( mapEntry.count() );
TQMap<TQString, TQString>::Iterator it( mapEntry.begin() );
for( uint i = 0; it != mapEntry.end(); ++it, i++ ) {
TQString sShortcuts = *it;
- KShortcut cuts;
+ TDEShortcut cuts;
kdDebug(125) << it.key() << " = " << sShortcuts << endl;
if( !sShortcuts.isEmpty() && sShortcuts != "none" )
cuts.init( sShortcuts );
- m_prgActions[i] = new KAccelAction( it.key(), it.key(), it.key(),
+ m_prgActions[i] = new TDEAccelAction( it.key(), it.key(), it.key(),
cuts, cuts,
0, 0, // pObjSlot, psMethodSlot,
true, false ); // bConfigurable, bEnabled
@@ -318,11 +318,11 @@ bool KAccelActions::init( TDEConfigBase& config, const TQString& sGroup )
return true;
}
-void KAccelActions::resize( uint nSize )
+void TDEAccelActions::resize( uint nSize )
{
if( nSize > m_nSizeAllocated ) {
uint nSizeAllocated = ((nSize/10) + 1) * 10;
- KAccelAction** prgActions = new KAccelAction* [nSizeAllocated];
+ TDEAccelAction** prgActions = new TDEAccelAction* [nSizeAllocated];
// Copy pointers over to new array
for( uint i = 0; i < m_nSizeAllocated; i++ )
@@ -340,21 +340,21 @@ void KAccelActions::resize( uint nSize )
m_nSize = nSize;
}
-void KAccelActions::insertPtr( KAccelAction* pAction )
+void TDEAccelActions::insertPtr( TDEAccelAction* pAction )
{
resize( m_nSize + 1 );
m_prgActions[m_nSize-1] = pAction;
}
-void KAccelActions::updateShortcuts( KAccelActions& actions2 )
+void TDEAccelActions::updateShortcuts( TDEAccelActions& actions2 )
{
- kdDebug(125) << "KAccelActions::updateShortcuts()" << endl;
+ kdDebug(125) << "TDEAccelActions::updateShortcuts()" << endl;
bool bChanged = false;
for( uint i = 0; i < m_nSize; i++ ) {
- KAccelAction* pAction = m_prgActions[i];
+ TDEAccelAction* pAction = m_prgActions[i];
if( pAction && pAction->m_bConfigurable ) {
- KAccelAction* pAction2 = actions2.actionPtr( pAction->m_sName );
+ TDEAccelAction* pAction2 = actions2.actionPtr( pAction->m_sName );
if( pAction2 ) {
TQString sOld = pAction->m_cut.toStringInternal();
pAction->m_cut = pAction2->m_cut;
@@ -371,68 +371,68 @@ void KAccelActions::updateShortcuts( KAccelActions& actions2 )
emitKeycodeChanged();
}
-int KAccelActions::actionIndex( const TQString& sAction ) const
+int TDEAccelActions::actionIndex( const TQString& sAction ) const
{
for( uint i = 0; i < m_nSize; i++ ) {
if( m_prgActions[i] == 0 )
- kdWarning(125) << "KAccelActions::actionPtr( " << sAction << " ): encountered null pointer at m_prgActions[" << i << "]" << endl;
+ kdWarning(125) << "TDEAccelActions::actionPtr( " << sAction << " ): encountered null pointer at m_prgActions[" << i << "]" << endl;
else if( m_prgActions[i]->m_sName == sAction )
return (int) i;
}
return -1;
}
-KAccelAction* KAccelActions::actionPtr( uint i )
+TDEAccelAction* TDEAccelActions::actionPtr( uint i )
{
return m_prgActions[i];
}
-const KAccelAction* KAccelActions::actionPtr( uint i ) const
+const TDEAccelAction* TDEAccelActions::actionPtr( uint i ) const
{
return m_prgActions[i];
}
-KAccelAction* KAccelActions::actionPtr( const TQString& sAction )
+TDEAccelAction* TDEAccelActions::actionPtr( const TQString& sAction )
{
int i = actionIndex( sAction );
return (i >= 0) ? m_prgActions[i] : 0;
}
-const KAccelAction* KAccelActions::actionPtr( const TQString& sAction ) const
+const TDEAccelAction* TDEAccelActions::actionPtr( const TQString& sAction ) const
{
int i = actionIndex( sAction );
return (i >= 0) ? m_prgActions[i] : 0;
}
-KAccelAction* KAccelActions::actionPtr( KKeySequence cut )
+TDEAccelAction* TDEAccelActions::actionPtr( KKeySequence cut )
{
for( uint i = 0; i < m_nSize; i++ ) {
if( m_prgActions[i] == 0 )
- kdWarning(125) << "KAccelActions::actionPtr( " << cut.toStringInternal() << " ): encountered null pointer at m_prgActions[" << i << "]" << endl;
+ kdWarning(125) << "TDEAccelActions::actionPtr( " << cut.toStringInternal() << " ): encountered null pointer at m_prgActions[" << i << "]" << endl;
else if( m_prgActions[i]->contains( cut ) )
return m_prgActions[i];
}
return 0;
}
-KAccelAction& KAccelActions::operator []( uint i )
+TDEAccelAction& TDEAccelActions::operator []( uint i )
{
return *actionPtr( i );
}
-const KAccelAction& KAccelActions::operator []( uint i ) const
+const TDEAccelAction& TDEAccelActions::operator []( uint i ) const
{
return *actionPtr( i );
}
-KAccelAction* KAccelActions::insert( const TQString& sName, const TQString& sLabel )
+TDEAccelAction* TDEAccelActions::insert( const TQString& sName, const TQString& sLabel )
{
if( actionPtr( sName ) ) {
- kdWarning(125) << "KAccelActions::insertLabel( " << sName << ", " << sLabel << " ): action with same name already present." << endl;
+ kdWarning(125) << "TDEAccelActions::insertLabel( " << sName << ", " << sLabel << " ): action with same name already present." << endl;
return 0;
}
- KAccelAction* pAction = new KAccelAction;
+ TDEAccelAction* pAction = new TDEAccelAction;
pAction->m_sName = sName;
pAction->m_sLabel = sLabel;
pAction->m_bConfigurable = false;
@@ -442,38 +442,38 @@ KAccelAction* KAccelActions::insert( const TQString& sName, const TQString& sLab
return pAction;
}
-KAccelAction* KAccelActions::insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& rgCutDefaults3, const KShortcut& rgCutDefaults4,
+TDEAccelAction* TDEAccelActions::insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& rgCutDefaults3, const TDEShortcut& rgCutDefaults4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
- //kdDebug(125) << "KAccelActions::insert()2 begin" << endl;
+ //kdDebug(125) << "TDEAccelActions::insert()2 begin" << endl;
if( actionPtr( sAction ) ) {
- kdWarning(125) << "KAccelActions::insert( " << sAction << " ): action with same name already present." << endl;
+ kdWarning(125) << "TDEAccelActions::insert( " << sAction << " ): action with same name already present." << endl;
return 0;
}
- KAccelAction* pAction = new KAccelAction(
+ TDEAccelAction* pAction = new TDEAccelAction(
sAction, sLabel, sWhatsThis,
rgCutDefaults3, rgCutDefaults4,
pObjSlot, psMethodSlot,
bConfigurable, bEnabled );
insertPtr( pAction );
- //kdDebug(125) << "KAccelActions::insert()2 end" << endl;
+ //kdDebug(125) << "TDEAccelActions::insert()2 end" << endl;
return pAction;
}
-bool KAccelActions::remove( const TQString& sAction )
+bool TDEAccelActions::remove( const TQString& sAction )
{
- kdDebug(125) << "KAccelActions::remove( \"" << sAction << "\" ): this = " << this << " m_pKAccelBase = " << m_pKAccelBase << endl;
+ kdDebug(125) << "TDEAccelActions::remove( \"" << sAction << "\" ): this = " << this << " m_pTDEAccelBase = " << m_pTDEAccelBase << endl;
int iAction = actionIndex( sAction );
if( iAction < 0 )
return false;
- if( m_pKAccelBase )
- m_pKAccelBase->slotRemoveAction( m_prgActions[iAction] );
+ if( m_pTDEAccelBase )
+ m_pTDEAccelBase->slotRemoveAction( m_prgActions[iAction] );
delete m_prgActions[iAction];
for( uint i = iAction; i < m_nSize - 1; i++ )
@@ -483,39 +483,39 @@ bool KAccelActions::remove( const TQString& sAction )
return true;
}
-bool KAccelActions::readActions( const TQString& sConfigGroup, TDEConfigBase* pConfig )
+bool TDEAccelActions::readActions( const TQString& sConfigGroup, TDEConfigBase* pConfig )
{
- KAccelShortcutList accelList(*this, false);
+ TDEAccelShortcutList accelList(*this, false);
return accelList.readSettings( sConfigGroup, pConfig );
}
/*
- 1) KAccelAction = "Something"
+ 1) TDEAccelAction = "Something"
1) KKeySequence = "Meta+X,Asterisk"
- 1) KAccelSequence = "Meta+X"
+ 1) TDEAccelSequence = "Meta+X"
1) KKeySequence = Meta+X
- 2) KAccelSequence = "Asterisk"
+ 2) TDEAccelSequence = "Asterisk"
1) KKeySequence = Shift+8 (English layout)
2) KKeySequence = Keypad_Asterisk
2) KKeySequence = "Alt+F2"
- 1) KAccelSequence = "Alt+F2"
+ 1) TDEAccelSequence = "Alt+F2"
1) KKeySequence = Alt+F2
-> "Something=Meta+X,Asterisk;Alt+F2"
*/
-bool KAccelActions::writeActions( const TQString &sGroup, TDEConfigBase* pConfig,
+bool TDEAccelActions::writeActions( const TQString &sGroup, TDEConfigBase* pConfig,
bool bWriteAll, bool bGlobal ) const
{
- kdDebug(125) << "KAccelActions::writeActions( " << sGroup << ", " << pConfig << ", " << bWriteAll << ", " << bGlobal << " )" << endl;
+ kdDebug(125) << "TDEAccelActions::writeActions( " << sGroup << ", " << pConfig << ", " << bWriteAll << ", " << bGlobal << " )" << endl;
if( !pConfig )
pConfig = TDEGlobal::config();
TDEConfigGroupSaver cs( pConfig, sGroup );
for( uint i = 0; i < m_nSize; i++ ) {
if( m_prgActions[i] == 0 ) {
- kdWarning(125) << "KAccelActions::writeActions(): encountered null pointer at m_prgActions[" << i << "]" << endl;
+ kdWarning(125) << "TDEAccelActions::writeActions(): encountered null pointer at m_prgActions[" << i << "]" << endl;
continue;
}
- const KAccelAction& action = *m_prgActions[i];
+ const TDEAccelAction& action = *m_prgActions[i];
TQString s;
bool bConfigHasAction = !pConfig->readEntry( action.m_sName ).isEmpty();
@@ -555,11 +555,11 @@ bool KAccelActions::writeActions( const TQString &sGroup, TDEConfigBase* pConfig
return true;
}
-void KAccelActions::emitKeycodeChanged()
+void TDEAccelActions::emitKeycodeChanged()
{
- if( m_pKAccelBase )
- m_pKAccelBase->emitSignal( KAccelBase::KEYCODE_CHANGED );
+ if( m_pTDEAccelBase )
+ m_pTDEAccelBase->emitSignal( TDEAccelBase::KEYCODE_CHANGED );
}
-uint KAccelActions::count() const
+uint TDEAccelActions::count() const
{ return m_nSize; }
diff --git a/tdecore/kaccelaction.h b/tdecore/kaccelaction.h
index 9cca25d4a..809533ff8 100644
--- a/tdecore/kaccelaction.h
+++ b/tdecore/kaccelaction.h
@@ -27,7 +27,7 @@
#include <kshortcut.h>
-class KAccelBase;
+class TDEAccelBase;
class TQObject;
class TDEConfig;
@@ -35,27 +35,27 @@ class TDEConfigBase;
/**
* @internal
- * A KAccelAction prepresents an action that can be executed using
- * an accelerator key. Each KAccelAction has a name, a label, a
- * "What's this" string and a KShortcut. The user can configure and
+ * A TDEAccelAction prepresents an action that can be executed using
+ * an accelerator key. Each TDEAccelAction has a name, a label, a
+ * "What's this" string and a TDEShortcut. The user can configure and
* enable/disable them using KKeyDialog.
*
* \code
- * 1) KAccelAction = "Run Command"
+ * 1) TDEAccelAction = "Run Command"
* Default3 = "Alt+F2"
* Default4 = "Meta+Enter;Alt+F2"
- * 1) KShortcut = "Meta+Enter"
+ * 1) TDEShortcut = "Meta+Enter"
* 1) KKeySequence = "Meta+Enter"
* 1) KKey = "Meta+Enter"
* 1) Meta+Enter
* 2) Meta+Keypad_Enter
- * 2) KShortcut = "Alt+F2"
+ * 2) TDEShortcut = "Alt+F2"
* 1) KKeySequence = "Alt+F2"
* 1) Alt+F2
- * 2) KAccelAction = "Something"
+ * 2) TDEAccelAction = "Something"
* Default3 = ""
* Default4 = ""
- * 1) KShortcut = "Meta+X,Asterisk"
+ * 1) TDEShortcut = "Meta+X,Asterisk"
* 1) KKeySequence = "Meta+X,Asterisk"
* 1) KKey = "Meta+X"
* 1) Meta+X
@@ -64,27 +64,27 @@ class TDEConfigBase;
* 2) Keypad_Asterisk
* \endcode
* @short An accelerator action
- * @see KAccel
+ * @see TDEAccel
* @see TDEGlobalAccel
* @see KKeyChooser
* @see KKeyDialog
*/
-class TDECORE_EXPORT KAccelAction
+class TDECORE_EXPORT TDEAccelAction
{
public:
/**
- * Creates an empty KAccelAction.
+ * Creates an empty TDEAccelAction.
* @see clear()
*/
- KAccelAction();
+ TDEAccelAction();
/**
* Copy constructor.
*/
- KAccelAction( const KAccelAction& );
+ TDEAccelAction( const TDEAccelAction& );
/**
- * Creates a new KAccelAction.
+ * Creates a new TDEAccelAction.
* @param sName the name of the accelerator
* @param sLabel the label of the accelerator (i18n!)
* @param sWhatsThis the What's This text (18n!)
@@ -97,11 +97,11 @@ class TDECORE_EXPORT KAccelAction
* @param bConfigurable if true the user can configure the shortcut
* @param bEnabled true if the accelerator should be enabled
*/
- KAccelAction( const TQString& sName, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& cutDef3, const KShortcut& cutDef4,
+ TDEAccelAction( const TQString& sName, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& cutDef3, const TDEShortcut& cutDef4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled );
- ~KAccelAction();
+ ~TDEAccelAction();
/**
* Clears the accelerator.
@@ -109,7 +109,7 @@ class TDECORE_EXPORT KAccelAction
void clear();
/**
- * Re-initialized the KAccelAction.
+ * Re-initialized the TDEAccelAction.
* @param sName the name of the accelerator
* @param sLabel the label of the accelerator (i18n!)
* @param sWhatsThis the What's This text (18n!)
@@ -124,14 +124,14 @@ class TDECORE_EXPORT KAccelAction
* @return true if successful, false otherwise
*/
bool init( const TQString& sName, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& cutDef3, const KShortcut& cutDef4,
+ const TDEShortcut& cutDef3, const TDEShortcut& cutDef4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled );
/**
- * Copies this KAccelAction.
+ * Copies this TDEAccelAction.
*/
- KAccelAction& operator=( const KAccelAction& );
+ TDEAccelAction& operator=( const TDEAccelAction& );
/**
* Returns the name of the accelerator action.
@@ -156,10 +156,10 @@ class TDECORE_EXPORT KAccelAction
/**
* The shortcut that is actually used (may be used configured).
- * @return the shortcut of the KAccelAction, can be null if not set
+ * @return the shortcut of the TDEAccelAction, can be null if not set
* @see shortcutDefault()
*/
- const KShortcut& shortcut() const { return m_cut; }
+ const TDEShortcut& shortcut() const { return m_cut; }
/**
* The default shortcut for this system.
@@ -168,7 +168,7 @@ class TDECORE_EXPORT KAccelAction
* @see shortcutDefault3()
* @see shortcutDefault4()
*/
- const KShortcut& shortcutDefault() const;
+ const TDEShortcut& shortcutDefault() const;
/**
* The default shortcut for 3 modifier systems.
@@ -178,7 +178,7 @@ class TDECORE_EXPORT KAccelAction
* @see shortcutDefault4()
* @see useFourModifierKeys()
*/
- const KShortcut& shortcutDefault3() const { return m_cutDefault3; }
+ const TDEShortcut& shortcutDefault3() const { return m_cutDefault3; }
/**
* The default shortcut for 4 modifier systems.
@@ -188,7 +188,7 @@ class TDECORE_EXPORT KAccelAction
* @see shortcutDefault3()
* @see useFourModifierKeys()
*/
- const KShortcut& shortcutDefault4() const { return m_cutDefault4; }
+ const TDEShortcut& shortcutDefault4() const { return m_cutDefault4; }
/**
* Returns the receiver of signals.
@@ -237,7 +237,7 @@ class TDECORE_EXPORT KAccelAction
* @param rgCuts the shortcut to set
* @return true if successful, false otherwise
*/
- bool setShortcut( const KShortcut& rgCuts );
+ bool setShortcut( const TDEShortcut& rgCuts );
/**
* Sets the slot of the accelerator action.
@@ -284,14 +284,14 @@ class TDECORE_EXPORT KAccelAction
* @param i the position of the sequence
* @param keySeq the new new sequence
* @return true if successful, false otherwise
- * @see KShortcut::setSeq()
+ * @see TDEShortcut::setSeq()
*/
bool setKeySequence( uint i, const KKeySequence &keySeq );
/**
* Clears the action's shortcut. It will not contain any sequences after
* calling this method.
- * @see KShortcut::clear()
+ * @see TDEShortcut::clear()
*/
void clearShortcut();
@@ -299,14 +299,14 @@ class TDECORE_EXPORT KAccelAction
* Checks whether the action's shortcut contains the given key sequence.
* @param keySeq the key sequence to check
* @return true if the shortcut contains the given sequence
- * @see KShortcut::contains()
+ * @see TDEShortcut::contains()
*/
bool contains( const KKeySequence &keySeq );
/**
* Returns the string representation of the action's shortcut.
* @return the string representation of the action's shortcut.
- * @see KShortcut::toString()
+ * @see TDEShortcut::toString()
*/
TQString toString() const;
@@ -332,8 +332,8 @@ class TDECORE_EXPORT KAccelAction
TQString m_sName /**< Name of accel. @sa setName() */,
m_sLabel /**< Label of accel. User-visible. */,
m_sWhatsThis /**< WhatsThis help for accel. User-visible. */;
- KShortcut m_cut /**< Shortcut actually assigned. */;
- KShortcut m_cutDefault3 /**< Default shortcut in 3-modifier layout */,
+ TDEShortcut m_cut /**< Shortcut actually assigned. */;
+ TDEShortcut m_cutDefault3 /**< Default shortcut in 3-modifier layout */,
m_cutDefault4 /**< Default shortcur in 4-modifier layout */;
const TQObject* m_pObjSlot /**< Object we will send signals to. */;
const char* m_psMethodSlot /**< Slot we send signals to, in m_pObjSlot */;
@@ -349,36 +349,36 @@ class TDECORE_EXPORT KAccelAction
private:
static int g_bUseFourModifierKeys;
- class KAccelActionPrivate* d;
+ class TDEAccelActionPrivate* d;
- friend class KAccelActions;
- friend class KAccelBase;
+ friend class TDEAccelActions;
+ friend class TDEAccelBase;
};
//---------------------------------------------------------------------
-// KAccelActions
+// TDEAccelActions
//---------------------------------------------------------------------
/**
* @internal
- * This class represents a collection of KAccelAction objects.
+ * This class represents a collection of TDEAccelAction objects.
*
* @short A collection of accelerator actions
- * @see KAccelAction
+ * @see TDEAccelAction
*/
-class TDECORE_EXPORT KAccelActions
+class TDECORE_EXPORT TDEAccelActions
{
public:
/**
- * Creates a new, empty KAccelActions object.
+ * Creates a new, empty TDEAccelActions object.
*/
- KAccelActions();
+ TDEAccelActions();
/**
* Copy constructor (deep copy).
*/
- KAccelActions( const KAccelActions& );
- virtual ~KAccelActions();
+ TDEAccelActions( const TDEAccelActions& );
+ virtual ~TDEAccelActions();
/**
* Removes all items from this collection.
@@ -391,7 +391,7 @@ class TDECORE_EXPORT KAccelActions
* @param actions the actions to copy
* @return true if successful, false otherwise
*/
- bool init( const KAccelActions &actions );
+ bool init( const TDEAccelActions &actions );
/**
* Loads the actions from the given configuration file.
@@ -408,7 +408,7 @@ class TDECORE_EXPORT KAccelActions
* @param shortcuts the collection that contains the new
* shortcuts
*/
- void updateShortcuts( KAccelActions &shortcuts );
+ void updateShortcuts( TDEAccelActions &shortcuts );
/**
* Retrieves the index of the action with the given name.
@@ -421,63 +421,63 @@ class TDECORE_EXPORT KAccelActions
* Returns the action with the given @p index.
* @param index the index of an action. You must not
* use an index that is too high.
- * @return the KAccelAction with the given index
+ * @return the TDEAccelAction with the given index
* @see count()
*/
- KAccelAction* actionPtr( uint index );
+ TDEAccelAction* actionPtr( uint index );
/**
* Returns the action with the given @p index.
* @param index the index of an action. You must not
* use an index that is too high.
- * @return the KAccelAction with the given index
+ * @return the TDEAccelAction with the given index
* @see count()
*/
- const KAccelAction* actionPtr( uint index ) const;
+ const TDEAccelAction* actionPtr( uint index ) const;
/**
* Returns the action with the given name.
* @param sAction the name of the action to search
- * @return the KAccelAction with the given name, or 0
+ * @return the TDEAccelAction with the given name, or 0
* if not found
*/
- KAccelAction* actionPtr( const TQString& sAction );
+ TDEAccelAction* actionPtr( const TQString& sAction );
/**
* Returns the action with the given name.
* @param sAction the name of the action to search
- * @return the KAccelAction with the given name, or 0
+ * @return the TDEAccelAction with the given name, or 0
* if not found
*/
- const KAccelAction* actionPtr( const TQString& sAction ) const;
+ const TDEAccelAction* actionPtr( const TQString& sAction ) const;
/**
* Returns the action with the given key sequence.
* @param cut the sequence to search for
- * @return the KAccelAction with the given sequence, or 0
+ * @return the TDEAccelAction with the given sequence, or 0
* if not found
*/
- KAccelAction* actionPtr( KKeySequence cut );
+ TDEAccelAction* actionPtr( KKeySequence cut );
/**
* Returns the action with the given @p index.
* @param index the index of an action. You must not
* use an index that is too high.
- * @return the KAccelAction with the given index
+ * @return the TDEAccelAction with the given index
* @see actionPtr()
* @see count()
*/
- KAccelAction& operator []( uint index );
+ TDEAccelAction& operator []( uint index );
/**
* Returns the action with the given @p index.
* @param index the index of an action. You must not
* use an index that is too high.
- * @return the KAccelAction with the given index
+ * @return the TDEAccelAction with the given index
* @see actionPtr()
* @see count()
*/
- const KAccelAction& operator []( uint index ) const;
+ const TDEAccelAction& operator []( uint index ) const;
/**
* Inserts an action into the collection.
@@ -494,8 +494,8 @@ class TDECORE_EXPORT KAccelActions
* @param bEnabled if true the accelerator should be enabled
* @return the new action
*/
- KAccelAction* insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& rgCutDefaults3, const KShortcut& rgCutDefaults4,
+ TDEAccelAction* insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& rgCutDefaults3, const TDEShortcut& rgCutDefaults4,
const TQObject* pObjSlot = 0, const char* psMethodSlot = 0,
bool bConfigurable = true, bool bEnabled = true );
@@ -505,7 +505,7 @@ class TDECORE_EXPORT KAccelActions
* @param sLabel the label of the accelerator (i18n!)
* @return the new action
*/
- KAccelAction* insert( const TQString& sName, const TQString& sLabel );
+ TDEAccelAction* insert( const TQString& sName, const TQString& sLabel );
/**
* Removes the given action.
@@ -548,9 +548,9 @@ class TDECORE_EXPORT KAccelActions
protected:
/** Base object that proxies signals from us. */
- KAccelBase* m_pKAccelBase;
+ TDEAccelBase* m_pTDEAccelBase;
/** Array of actions we're hanging on to. */
- KAccelAction** m_prgActions;
+ TDEAccelAction** m_prgActions;
uint m_nSizeAllocated /**< Allocated size of the array. */,
m_nSize /**< Amount in use. */ ;
@@ -561,16 +561,16 @@ class TDECORE_EXPORT KAccelActions
*/
void resize( uint new_size );
/** Add a action to this collection. @todo Document ownership. */
- void insertPtr( KAccelAction* );
+ void insertPtr( TDEAccelAction* );
private:
- class KAccelActionsPrivate* d;
+ class TDEAccelActionsPrivate* d;
- KAccelActions( KAccelBase* );
- void initPrivate( KAccelBase* );
- KAccelActions& operator =( KAccelActions& );
+ TDEAccelActions( TDEAccelBase* );
+ void initPrivate( TDEAccelBase* );
+ TDEAccelActions& operator =( TDEAccelActions& );
- friend class KAccelBase;
+ friend class TDEAccelBase;
};
#endif // _KACCELACTION_H
diff --git a/tdecore/kaccelbase.cpp b/tdecore/kaccelbase.cpp
index 75810b2e3..235803134 100644
--- a/tdecore/kaccelbase.cpp
+++ b/tdecore/kaccelbase.cpp
@@ -36,17 +36,17 @@
#include "kshortcutmenu.h"
//---------------------------------------------------------------------
-// class KAccelBase::ActionInfo
+// class TDEAccelBase::ActionInfo
//---------------------------------------------------------------------
//---------------------------------------------------------------------
-// class KAccelBase
+// class TDEAccelBase
//---------------------------------------------------------------------
-KAccelBase::KAccelBase( int fInitCode )
+TDEAccelBase::TDEAccelBase( int fInitCode )
: m_rgActions( this )
{
- kdDebug(125) << "KAccelBase(): this = " << this << endl;
+ kdDebug(125) << "TDEAccelBase(): this = " << this << endl;
m_bNativeKeys = fInitCode & NATIVE_KEYS;
m_bEnabled = true;
m_sConfigGroup = "Shortcuts";
@@ -55,27 +55,27 @@ KAccelBase::KAccelBase( int fInitCode )
mtemp_pActionRemoving = 0;
}
-KAccelBase::~KAccelBase()
+TDEAccelBase::~TDEAccelBase()
{
- kdDebug(125) << "~KAccelBase(): this = " << this << endl;
+ kdDebug(125) << "~TDEAccelBase(): this = " << this << endl;
}
-uint KAccelBase::actionCount() const { return m_rgActions.count(); }
-KAccelActions& KAccelBase::actions() { return m_rgActions; }
-bool KAccelBase::isEnabled() const { return m_bEnabled; }
+uint TDEAccelBase::actionCount() const { return m_rgActions.count(); }
+TDEAccelActions& TDEAccelBase::actions() { return m_rgActions; }
+bool TDEAccelBase::isEnabled() const { return m_bEnabled; }
// see TDEGlobalAccel::blockShortcuts() stuff - it's to temporarily block
// all global shortcuts, so that the key grabs are released, but from the app's
// point of view the TDEGlobalAccel is still enabled, so TDEGlobalAccel needs
// to disable key grabbing even if enabled
-bool KAccelBase::isEnabledInternal() const { return isEnabled(); }
+bool TDEAccelBase::isEnabledInternal() const { return isEnabled(); }
-KAccelAction* KAccelBase::actionPtr( const TQString& sAction )
+TDEAccelAction* TDEAccelBase::actionPtr( const TQString& sAction )
{ return m_rgActions.actionPtr( sAction ); }
-const KAccelAction* KAccelBase::actionPtr( const TQString& sAction ) const
+const TDEAccelAction* TDEAccelBase::actionPtr( const TQString& sAction ) const
{ return m_rgActions.actionPtr( sAction ); }
-KAccelAction* KAccelBase::actionPtr( const KKeyServer::Key& key )
+TDEAccelAction* TDEAccelBase::actionPtr( const KKeyServer::Key& key )
{
if( !m_mapKeyToAction.contains( key ) )
return 0;
@@ -83,25 +83,25 @@ KAccelAction* KAccelBase::actionPtr( const KKeyServer::Key& key )
return m_mapKeyToAction[key].pAction;
}
-KAccelAction* KAccelBase::actionPtr( const KKey& key )
+TDEAccelAction* TDEAccelBase::actionPtr( const KKey& key )
{
KKeyServer::Key k2;
k2.init( key, !m_bNativeKeys );
return actionPtr( k2 );
}
-void KAccelBase::setConfigGroup( const TQString& sConfigGroup )
+void TDEAccelBase::setConfigGroup( const TQString& sConfigGroup )
{ m_sConfigGroup = sConfigGroup; }
-void KAccelBase::setConfigGlobal( bool global )
+void TDEAccelBase::setConfigGlobal( bool global )
{ m_bConfigIsGlobal = global; }
-bool KAccelBase::setActionEnabled( const TQString& sAction, bool bEnable )
+bool TDEAccelBase::setActionEnabled( const TQString& sAction, bool bEnable )
{
- KAccelAction* pAction = actionPtr( sAction );
+ TDEAccelAction* pAction = actionPtr( sAction );
if( pAction ) {
if( pAction->m_bEnabled != bEnable ) {
- kdDebug(125) << "KAccelBase::setActionEnabled( " << sAction << ", " << bEnable << " )" << endl;
+ kdDebug(125) << "TDEAccelBase::setActionEnabled( " << sAction << ", " << bEnable << " )" << endl;
pAction->m_bEnabled = bEnable;
if( m_bAutoUpdate ) {
// FIXME: the action may already have it's connections inserted!
@@ -116,9 +116,9 @@ bool KAccelBase::setActionEnabled( const TQString& sAction, bool bEnable )
return false;
}
-bool KAccelBase::setAutoUpdate( bool bAuto )
+bool TDEAccelBase::setAutoUpdate( bool bAuto )
{
- kdDebug(125) << "KAccelBase::setAutoUpdate( " << bAuto << " ): m_bAutoUpdate on entrance = " << m_bAutoUpdate << endl;
+ kdDebug(125) << "TDEAccelBase::setAutoUpdate( " << bAuto << " ): m_bAutoUpdate on entrance = " << m_bAutoUpdate << endl;
bool b = m_bAutoUpdate;
if( !m_bAutoUpdate && bAuto )
updateConnections();
@@ -126,13 +126,13 @@ bool KAccelBase::setAutoUpdate( bool bAuto )
return b;
}
-KAccelAction* KAccelBase::insert( const TQString& sAction, const TQString& sDesc, const TQString& sHelp,
- const KShortcut& rgCutDefaults3, const KShortcut& rgCutDefaults4,
+TDEAccelAction* TDEAccelBase::insert( const TQString& sAction, const TQString& sDesc, const TQString& sHelp,
+ const TDEShortcut& rgCutDefaults3, const TDEShortcut& rgCutDefaults4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
- //kdDebug(125) << "KAccelBase::insert() begin" << endl;
- KAccelAction* pAction = m_rgActions.insert(
+ //kdDebug(125) << "TDEAccelBase::insert() begin" << endl;
+ TDEAccelAction* pAction = m_rgActions.insert(
sAction, sDesc, sHelp,
rgCutDefaults3, rgCutDefaults4,
pObjSlot, psMethodSlot,
@@ -141,27 +141,27 @@ KAccelAction* KAccelBase::insert( const TQString& sAction, const TQString& sDesc
if( pAction && m_bAutoUpdate )
insertConnection( pAction );
- //kdDebug(125) << "KAccelBase::insert() end" << endl;
+ //kdDebug(125) << "TDEAccelBase::insert() end" << endl;
return pAction;
}
-KAccelAction* KAccelBase::insert( const TQString& sName, const TQString& sDesc )
+TDEAccelAction* TDEAccelBase::insert( const TQString& sName, const TQString& sDesc )
{ return m_rgActions.insert( sName, sDesc ); }
-bool KAccelBase::remove( const TQString& sAction )
+bool TDEAccelBase::remove( const TQString& sAction )
{
return m_rgActions.remove( sAction );
}
-void KAccelBase::slotRemoveAction( KAccelAction* pAction )
+void TDEAccelBase::slotRemoveAction( TDEAccelAction* pAction )
{
removeConnection( pAction );
}
-bool KAccelBase::setActionSlot( const TQString& sAction, const TQObject* pObjSlot, const char* psMethodSlot )
+bool TDEAccelBase::setActionSlot( const TQString& sAction, const TQObject* pObjSlot, const char* psMethodSlot )
{
- kdDebug(125) << "KAccelBase::setActionSlot( " << sAction << ", " << pObjSlot << ", " << psMethodSlot << " )\n";
- KAccelAction* pAction = m_rgActions.actionPtr( sAction );
+ kdDebug(125) << "TDEAccelBase::setActionSlot( " << sAction << ", " << pObjSlot << ", " << psMethodSlot << " )\n";
+ TDEAccelAction* pAction = m_rgActions.actionPtr( sAction );
if( pAction ) {
// If there was a previous connection, remove it.
if( m_bAutoUpdate && pAction->isConnected() ) {
@@ -182,24 +182,24 @@ bool KAccelBase::setActionSlot( const TQString& sAction, const TQObject* pObjSlo
}
/*
-KAccelBase
+TDEAccelBase
Run Command=Meta+Enter;Alt+F2
- KAccelAction = "Run Command"
- 1) KAccelKeySeries = "Meta+Enter"
+ TDEAccelAction = "Run Command"
+ 1) TDEAccelKeySeries = "Meta+Enter"
1a) Meta+Enter
1b) Meta+Keypad_Enter
- 2) KAccelKeySeries = "Alt+F2"
+ 2) TDEAccelKeySeries = "Alt+F2"
1a) Alt+F2
Konqueror=Meta+I,I
- KAccelAction = "Konqueror"
- 1) KAccelKeySeries = "Meta+I,I"
+ TDEAccelAction = "Konqueror"
+ 1) TDEAccelKeySeries = "Meta+I,I"
1a) Meta+I
2a) I
Something=Meta+Asterisk,X
- KAccelAction = "Something"
- 1) KAccelKeySeries = "Meta+Asterisk,X"
+ TDEAccelAction = "Something"
+ 1) TDEAccelKeySeries = "Meta+Asterisk,X"
1a) Meta+Shift+8
1b) Meta+Keypad_8
2a) X
@@ -215,25 +215,25 @@ connect new key sequences
/*
{
For {
- for( KAccelAction::iterator itAction = m_rgActions.begin(); itAction != m_rgActions.end(); ++itAction ) {
- KAccelAction& action = *itAction;
- for( KAccelSeries::iterator itSeries = action.m_rgSeries.begin(); itSeries != action.m_rgSeries.end(); ++itSeries ) {
- KAccelSeries& series = *itSeries;
+ for( TDEAccelAction::iterator itAction = m_rgActions.begin(); itAction != m_rgActions.end(); ++itAction ) {
+ TDEAccelAction& action = *itAction;
+ for( TDEAccelSeries::iterator itSeries = action.m_rgSeries.begin(); itSeries != action.m_rgSeries.end(); ++itSeries ) {
+ TDEAccelSeries& series = *itSeries;
if(
}
}
}
Sort by: iVariation, iSequence, iSeries, iAction
- 1) KAccelAction = "Run Command"
- 1) KAccelKeySeries = "Meta+Enter"
+ 1) TDEAccelAction = "Run Command"
+ 1) TDEAccelKeySeries = "Meta+Enter"
1a) Meta+Enter
1b) Meta+Keypad_Enter
- 2) KAccelKeySeries = "Alt+F2"
+ 2) TDEAccelKeySeries = "Alt+F2"
1a) Alt+F2
- 2) KAccelAction = "Enter Calculation"
- 1) KAccelKeySeries = "Meta+Keypad_Enter"
+ 2) TDEAccelAction = "Enter Calculation"
+ 1) TDEAccelKeySeries = "Meta+Keypad_Enter"
1a) Meta+Keypad_Enter
List =
@@ -246,7 +246,7 @@ connect new key sequences
*/
#ifdef Q_WS_X11
-struct KAccelBase::X
+struct TDEAccelBase::X
{
uint iAction, iSeq, iVari;
KKeyServer::Key key;
@@ -312,10 +312,10 @@ struct KAccelBase::X
Ctrl+KP_Add => #2
*/
-bool KAccelBase::updateConnections()
+bool TDEAccelBase::updateConnections()
{
#ifdef Q_WS_X11
- kdDebug(125) << "KAccelBase::updateConnections() this = " << this << endl;
+ kdDebug(125) << "TDEAccelBase::updateConnections() this = " << this << endl;
// Retrieve the list of keys to be connected, sorted by priority.
// (key, variation, seq)
TQValueVector<X> rgKeys;
@@ -356,7 +356,7 @@ bool KAccelBase::updateConnections()
if( bNonUnique ) {
// Remove connection to single action if there is one
if( m_mapKeyToAction.contains( key ) ) {
- KAccelAction* pAction = m_mapKeyToAction[key].pAction;
+ TDEAccelAction* pAction = m_mapKeyToAction[key].pAction;
if( pAction ) {
m_mapKeyToAction.remove( key );
disconnectKey( *pAction, key );
@@ -376,7 +376,7 @@ bool KAccelBase::updateConnections()
// Disconnect keys which no longer have bindings:
for( KKeyToActionMap::iterator it = m_mapKeyToAction.begin(); it != m_mapKeyToAction.end(); ++it ) {
const KKeyServer::Key& key = it.key();
- KAccelAction* pAction = (*it).pAction;
+ TDEAccelAction* pAction = (*it).pAction;
// If this key is longer used or it points to a different action now,
if( !mapKeyToAction.contains( key ) || mapKeyToAction[key].pAction != pAction ) {
if( pAction ) {
@@ -392,7 +392,7 @@ bool KAccelBase::updateConnections()
// new action map, but which are _not_ present in the old one.
for( KKeyToActionMap::iterator it = mapKeyToAction.begin(); it != mapKeyToAction.end(); ++it ) {
const KKeyServer::Key& key = it.key();
- KAccelAction* pAction = (*it).pAction;
+ TDEAccelAction* pAction = (*it).pAction;
if( !m_mapKeyToAction.contains( key ) || m_mapKeyToAction[key].pAction != pAction ) {
// TODO: Decide what to do if connect fails.
// Probably should remove this item from map.
@@ -419,16 +419,16 @@ bool KAccelBase::updateConnections()
#ifdef Q_WS_X11
// Construct a list of keys to be connected, sorted highest priority first.
-void KAccelBase::createKeyList( TQValueVector<struct X>& rgKeys )
+void TDEAccelBase::createKeyList( TQValueVector<struct X>& rgKeys )
{
- //kdDebug(125) << "KAccelBase::createKeyList()" << endl;
+ //kdDebug(125) << "TDEAccelBase::createKeyList()" << endl;
if( !isEnabledInternal())
return;
// create the list
// For each action
for( uint iAction = 0; iAction < m_rgActions.count(); iAction++ ) {
- KAccelAction* pAction = m_rgActions.actionPtr( iAction );
+ TDEAccelAction* pAction = m_rgActions.actionPtr( iAction );
if( pAction && pAction->m_pObjSlot && pAction->m_psMethodSlot && pAction != mtemp_pActionRemoving ) {
// For each key sequence associated with action
for( uint iSeq = 0; iSeq < pAction->shortcut().count(); iSeq++ ) {
@@ -453,12 +453,12 @@ void KAccelBase::createKeyList( TQValueVector<struct X>& rgKeys )
}
#endif //Q_WS_X11
-bool KAccelBase::insertConnection( KAccelAction* pAction )
+bool TDEAccelBase::insertConnection( TDEAccelAction* pAction )
{
if( !pAction->m_pObjSlot || !pAction->m_psMethodSlot )
return true;
- kdDebug(125) << "KAccelBase::insertConnection( " << pAction << "=\"" << pAction->m_sName << "\"; shortcut = " << pAction->shortcut().toStringInternal() << " ) this = " << this << endl;
+ kdDebug(125) << "TDEAccelBase::insertConnection( " << pAction << "=\"" << pAction->m_sName << "\"; shortcut = " << pAction->shortcut().toStringInternal() << " ) this = " << this << endl;
// For each sequence associated with the given action:
for( uint iSeq = 0; iSeq < pAction->shortcut().count(); iSeq++ ) {
@@ -502,7 +502,7 @@ bool KAccelBase::insertConnection( KAccelAction* pAction )
}
//kdDebug(125) << "\tActions = " << m_rgActions.size() << endl;
- //for( KAccelActions::const_iterator it = m_rgActions.begin(); it != m_rgActions.end(); ++it ) {
+ //for( TDEAccelActions::const_iterator it = m_rgActions.begin(); it != m_rgActions.end(); ++it ) {
// kdDebug(125) << "\t" << &(*it) << " '" << (*it).m_sName << "'" << endl;
//}
@@ -516,9 +516,9 @@ bool KAccelBase::insertConnection( KAccelAction* pAction )
return true;
}
-bool KAccelBase::removeConnection( KAccelAction* pAction )
+bool TDEAccelBase::removeConnection( TDEAccelAction* pAction )
{
- kdDebug(125) << "KAccelBase::removeConnection( " << pAction << " = \"" << pAction->m_sName << "\"; shortcut = " << pAction->m_cut.toStringInternal() << " ): this = " << this << endl;
+ kdDebug(125) << "TDEAccelBase::removeConnection( " << pAction << " = \"" << pAction->m_sName << "\"; shortcut = " << pAction->m_cut.toStringInternal() << " ): this = " << this << endl;
//for( KKeyToActionMap::iterator it = m_mapKeyToAction.begin(); it != m_mapKeyToAction.end(); ++it )
// kdDebug(125) << "\tKey: " << it.key().toString() << " => '" << (*it)->m_sName << "'" << " " << *it << endl;
@@ -548,9 +548,9 @@ bool KAccelBase::removeConnection( KAccelAction* pAction )
return true;
}
-bool KAccelBase::setShortcut( const TQString& sAction, const KShortcut& cut )
+bool TDEAccelBase::setShortcut( const TQString& sAction, const TDEShortcut& cut )
{
- KAccelAction* pAction = actionPtr( sAction );
+ TDEAccelAction* pAction = actionPtr( sAction );
if( pAction ) {
if( m_bAutoUpdate )
removeConnection( pAction );
@@ -564,26 +564,26 @@ bool KAccelBase::setShortcut( const TQString& sAction, const KShortcut& cut )
return false;
}
-void KAccelBase::readSettings( TDEConfigBase* pConfig )
+void TDEAccelBase::readSettings( TDEConfigBase* pConfig )
{
m_rgActions.readActions( m_sConfigGroup, pConfig );
if( m_bAutoUpdate )
updateConnections();
}
-void KAccelBase::writeSettings( TDEConfigBase* pConfig ) const
+void TDEAccelBase::writeSettings( TDEConfigBase* pConfig ) const
{
m_rgActions.writeActions( m_sConfigGroup, pConfig, m_bConfigIsGlobal, m_bConfigIsGlobal );
}
-TQPopupMenu* KAccelBase::createPopupMenu( TQWidget* pParent, const KKeySequence& seq )
+TQPopupMenu* TDEAccelBase::createPopupMenu( TQWidget* pParent, const KKeySequence& seq )
{
- KShortcutMenu* pMenu = new KShortcutMenu( pParent, &actions(), seq );
+ TDEShortcutMenu* pMenu = new TDEShortcutMenu( pParent, &actions(), seq );
bool bActionInserted = false;
bool bInsertSeparator = false;
for( uint i = 0; i < actionCount(); i++ ) {
- const KAccelAction* pAction = actions().actionPtr( i );
+ const TDEAccelAction* pAction = actions().actionPtr( i );
if( !pAction->isEnabled() )
continue;
diff --git a/tdecore/kaccelbase.h b/tdecore/kaccelbase.h
index 132a6aa5c..3d7180c4f 100644
--- a/tdecore/kaccelbase.h
+++ b/tdecore/kaccelbase.h
@@ -42,7 +42,7 @@ class TQWidget;
* key bindings through application configuration files or through the
* KKeyChooser GUI.
*
- * A KAccel contains a list of accelerator items. Each accelerator item
+ * A TDEAccel contains a list of accelerator items. Each accelerator item
* consists of an action name and a keyboard code combined with modifiers
* (Shift, Ctrl and Alt.)
*
@@ -55,7 +55,7 @@ class TQWidget;
* connected. Accelerator items can be connected so that a key will activate
* two different slots.
*
- * A KAccel object handles key events sent to its parent widget and to all
+ * A TDEAccel object handles key events sent to its parent widget and to all
* children of this parent widget.
*
* Key binding reconfiguration during run time can be prevented by specifying
@@ -74,33 +74,33 @@ class TQWidget;
* The translated first argument for insertItem() is used only
* in the configuration dialog.
*\code
- * KAccel *a = new KAccel( myWindow );
+ * TDEAccel *a = new TDEAccel( myWindow );
* // Insert an action "Scroll Up" which is associated with the "Up" key:
* a->insertItem( i18n("Scroll Up"), "Scroll Up", "Up" );
* // Insert an action "Scroll Down" which is not associated with any key:
* a->insertItem( i18n("Scroll Down"), "Scroll Down", 0);
* a->connectItem( "Scroll up", myWindow, TQT_SLOT( scrollUp() ) );
- * // a->insertStdItem( KStdAccel::Print ); //not necessary, since it
+ * // a->insertStdItem( TDEStdAccel::Print ); //not necessary, since it
* // is done automatially with the
* // connect below!
- * a->connectItem(KStdAccel::Print, myWindow, TQT_SLOT( printDoc() ) );
+ * a->connectItem(TDEStdAccel::Print, myWindow, TQT_SLOT( printDoc() ) );
*
* a->readSettings();
*\endcode
*
* If a shortcut has a menu entry as well, you could insert them like
- * this. The example is again the KStdAccel::Print from above.
+ * this. The example is again the TDEStdAccel::Print from above.
*
* \code
* int id;
* id = popup->insertItem("&Print",this, TQT_SLOT(printDoc()));
- * a->changeMenuAccel(popup, id, KStdAccel::Print );
+ * a->changeMenuAccel(popup, id, TDEStdAccel::Print );
* \endcode
*
* If you want a somewhat "exotic" name for your standard print action, like
* id = popup->insertItem(i18n("Print &Document"),this, TQT_SLOT(printDoc()));
* it might be a good idea to insert the standard action before as
- * a->insertStdItem( KStdAccel::Print, i18n("Print Document") )
+ * a->insertStdItem( TDEStdAccel::Print, i18n("Print Document") )
* as well, so that the user can easily find the corresponding function.
*
* This technique works for other actions as well. Your "scroll up" function
@@ -118,10 +118,10 @@ class TQWidget;
* @short Configurable key binding support.
*/
-class TDECORE_EXPORT KAccelBase
+class TDECORE_EXPORT TDEAccelBase
{
public:
- /** Initialization mode of the KAccelBase, used in constructor. */
+ /** Initialization mode of the TDEAccelBase, used in constructor. */
enum Init { QT_KEYS = 0x00, NATIVE_KEYS = 0x01 };
/** Enum for kinds of signals which may be emitted. */
@@ -130,32 +130,32 @@ class TDECORE_EXPORT KAccelBase
/** Constructor. @p fInitCode should be a bitwise OR of
* values from the Init enum.
*/
- KAccelBase( int fInitCode );
- virtual ~KAccelBase();
+ TDEAccelBase( int fInitCode );
+ virtual ~TDEAccelBase();
/** Returns number of actions in this handler. */
uint actionCount() const;
/** Returns a list of all the actions in this handler. */
- KAccelActions& actions();
+ TDEAccelActions& actions();
/** Returns whether this accelerator handler is enabled or not. */
bool isEnabled() const;
- /** Returns a pointer to the KAccelAction named @p sAction. */
- KAccelAction* actionPtr( const TQString& sAction );
+ /** Returns a pointer to the TDEAccelAction named @p sAction. */
+ TDEAccelAction* actionPtr( const TQString& sAction );
/** Const version of the above. */
- const KAccelAction* actionPtr( const TQString& sAction ) const;
- /** Returns a pointer to the KAccelAction associated with
+ const TDEAccelAction* actionPtr( const TQString& sAction ) const;
+ /** Returns a pointer to the TDEAccelAction associated with
* the key @p key. This function takes into account the
* key mapping defined in the constructor.
*
* May return 0 if no (or more than one)
* action is associated with the key.
*/
- KAccelAction* actionPtr( const KKey& key );
+ TDEAccelAction* actionPtr( const KKey& key );
/** Basically the same as above, except a KKeyServer::Key
* already has a key mapping defined (either NATIVE_KEYS or not).
*/
- KAccelAction* actionPtr( const KKeyServer::Key& key );
+ TDEAccelAction* actionPtr( const KKeyServer::Key& key );
/** Returns the name of the configuration group these
* accelerators are stored in. The default is "Shortcuts".
@@ -181,10 +181,10 @@ class TDECORE_EXPORT KAccelBase
// Procedures for manipulating Actions.
//void clearActions();
- KAccelAction* insert( const TQString& sName, const TQString& sDesc );
- KAccelAction* insert(
+ TDEAccelAction* insert( const TQString& sName, const TQString& sDesc );
+ TDEAccelAction* insert(
const TQString& sAction, const TQString& sDesc, const TQString& sHelp,
- const KShortcut& rgCutDefaults3, const KShortcut& rgCutDefaults4,
+ const TDEShortcut& rgCutDefaults3, const TDEShortcut& rgCutDefaults4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable = true, bool bEnabled = true );
bool remove( const TQString& sAction );
@@ -192,7 +192,7 @@ class TDECORE_EXPORT KAccelBase
bool updateConnections();
- bool setShortcut( const TQString& sAction, const KShortcut& cut );
+ bool setShortcut( const TQString& sAction, const TDEShortcut& cut );
// Modify individual Action sub-items
bool setActionEnabled( const TQString& sAction, bool bEnable );
@@ -218,7 +218,7 @@ class TDECORE_EXPORT KAccelBase
// Protected methods
protected:
- void slotRemoveAction( KAccelAction* );
+ void slotRemoveAction( TDEAccelAction* );
struct X;
@@ -226,8 +226,8 @@ class TDECORE_EXPORT KAccelBase
* @param rgKeys constructed list of keys
*/
void createKeyList( TQValueVector<struct X>& rgKeys );
- bool insertConnection( KAccelAction* );
- bool removeConnection( KAccelAction* );
+ bool insertConnection( TDEAccelAction* );
+ bool removeConnection( TDEAccelAction* );
/** Emits a signal.
* @param signal signal to be emitted
@@ -237,14 +237,14 @@ class TDECORE_EXPORT KAccelBase
* @param action action to be executed when key is pressed
* @param key key which causes the action to be executed
*/
- virtual bool connectKey( KAccelAction& action, const KKeyServer::Key& key ) = 0;
+ virtual bool connectKey( TDEAccelAction& action, const KKeyServer::Key& key ) = 0;
/** Defines a key which activates the accelerator
* @param key key which causes the action to be executed
*/
virtual bool connectKey( const KKeyServer::Key& key) = 0;
/** Removes the key from accelerator so it no longer executes the action
*/
- virtual bool disconnectKey( KAccelAction&, const KKeyServer::Key& ) = 0;
+ virtual bool disconnectKey( TDEAccelAction&, const KKeyServer::Key& ) = 0;
/** Removes the key from accelerator
*/
virtual bool disconnectKey( const KKeyServer::Key& ) = 0;
@@ -253,30 +253,30 @@ class TDECORE_EXPORT KAccelBase
virtual bool isEnabledInternal() const;
struct ActionInfo
{
- KAccelAction* pAction;
+ TDEAccelAction* pAction;
uint iSeq, iVariation;
//ActionInfo* pInfoNext; // nil if only one action uses this key.
ActionInfo() { pAction = 0; iSeq = 0xffff; iVariation = 0xffff; }
- ActionInfo( KAccelAction* _pAction, uint _iSeq, uint _iVariation )
+ ActionInfo( TDEAccelAction* _pAction, uint _iSeq, uint _iVariation )
{ pAction = _pAction; iSeq = _iSeq; iVariation = _iVariation; }
};
typedef TQMap<KKeyServer::Key, ActionInfo> KKeyToActionMap;
- KAccelActions m_rgActions;
+ TDEAccelActions m_rgActions;
KKeyToActionMap m_mapKeyToAction;
- TQValueList<KAccelAction*> m_rgActionsNonUnique;
+ TQValueList<TDEAccelAction*> m_rgActionsNonUnique;
bool m_bNativeKeys; // Use native key codes instead of Qt codes
bool m_bEnabled;
bool m_bConfigIsGlobal;
TQString m_sConfigGroup;
bool m_bAutoUpdate;
- KAccelAction* mtemp_pActionRemoving;
+ TDEAccelAction* mtemp_pActionRemoving;
private:
- KAccelBase& operator =( const KAccelBase& );
+ TDEAccelBase& operator =( const TDEAccelBase& );
- friend class KAccelActions;
+ friend class TDEAccelActions;
};
#endif // _KACCELBASE_H
diff --git a/tdecore/kaccelmanager.cpp b/tdecore/kaccelmanager.cpp
index 6c2233c81..9ac4dbdae 100644
--- a/tdecore/kaccelmanager.cpp
+++ b/tdecore/kaccelmanager.cpp
@@ -63,7 +63,7 @@
/*********************************************************************
- class KAcceleratorManagerPrivate - internal helper class
+ class TDEAcceleratorManagerPrivate - internal helper class
This class does all the work to find accelerators for a hierarchy of
widgets.
@@ -71,7 +71,7 @@
*********************************************************************/
-class KAcceleratorManagerPrivate
+class TDEAcceleratorManagerPrivate
{
public:
@@ -79,7 +79,7 @@ public:
static bool programmers_mode;
static bool standardName(const TQString &str);
- static bool checkChange(const KAccelString &as) {
+ static bool checkChange(const TDEAccelString &as) {
TQString t2 = as.accelerated();
TQString t1 = as.originalText();
if (t1 != t2)
@@ -125,7 +125,7 @@ private:
void addChild(Item *item);
TQWidget *m_widget;
- KAccelString m_content;
+ TDEAccelString m_content;
ItemList *m_children;
int m_index;
@@ -133,28 +133,28 @@ private:
};
-bool KAcceleratorManagerPrivate::programmers_mode = false;
-TQString KAcceleratorManagerPrivate::changed_string;
-TQString KAcceleratorManagerPrivate::added_string;
-TQString KAcceleratorManagerPrivate::removed_string;
+bool TDEAcceleratorManagerPrivate::programmers_mode = false;
+TQString TDEAcceleratorManagerPrivate::changed_string;
+TQString TDEAcceleratorManagerPrivate::added_string;
+TQString TDEAcceleratorManagerPrivate::removed_string;
static TQStringList *kaccmp_sns = 0;
static KStaticDeleter<TQStringList> kaccmp_sns_d;
-TQMap<TQWidget*, int> KAcceleratorManagerPrivate::ignored_widgets;
+TQMap<TQWidget*, int> TDEAcceleratorManagerPrivate::ignored_widgets;
-bool KAcceleratorManagerPrivate::standardName(const TQString &str)
+bool TDEAcceleratorManagerPrivate::standardName(const TQString &str)
{
if (!kaccmp_sns)
kaccmp_sns_d.setObject(kaccmp_sns, new TQStringList(KStdAction::internal_stdNames()));
return kaccmp_sns->contains(str);
}
-KAcceleratorManagerPrivate::Item::~Item()
+TDEAcceleratorManagerPrivate::Item::~Item()
{
delete m_children;
}
-void KAcceleratorManagerPrivate::Item::addChild(Item *item)
+void TDEAcceleratorManagerPrivate::Item::addChild(Item *item)
{
if (!m_children) {
m_children = new ItemList;
@@ -164,7 +164,7 @@ void KAcceleratorManagerPrivate::Item::addChild(Item *item)
m_children->append(item);
}
-void KAcceleratorManagerPrivate::manage(TQWidget *widget)
+void TDEAcceleratorManagerPrivate::manage(TQWidget *widget)
{
if (!widget)
{
@@ -175,7 +175,7 @@ void KAcceleratorManagerPrivate::manage(TQWidget *widget)
if (dynamic_cast<TQPopupMenu*>(widget))
{
// create a popup accel manager that can deal with dynamic menus
- KPopupAccelManager::manage(static_cast<TQPopupMenu*>(widget));
+ TDEPopupAccelManager::manage(static_cast<TQPopupMenu*>(widget));
return;
}
@@ -189,13 +189,13 @@ void KAcceleratorManagerPrivate::manage(TQWidget *widget)
}
-void KAcceleratorManagerPrivate::calculateAccelerators(Item *item, TQString &used)
+void TDEAcceleratorManagerPrivate::calculateAccelerators(Item *item, TQString &used)
{
if (!item->m_children)
return;
// collect the contents
- KAccelStringList contents;
+ TDEAccelStringList contents;
for (Item *it = item->m_children->first(); it != 0;
it = item->m_children->next())
{
@@ -203,7 +203,7 @@ void KAcceleratorManagerPrivate::calculateAccelerators(Item *item, TQString &use
}
// find the right accelerators
- KAccelManagerAlgorithm::findAccelerators(contents, used);
+ TDEAccelManagerAlgorithm::findAccelerators(contents, used);
// write them back into the widgets
int cnt = -1;
@@ -261,7 +261,7 @@ void KAcceleratorManagerPrivate::calculateAccelerators(Item *item, TQString &use
}
-void KAcceleratorManagerPrivate::traverseChildren(TQWidget *widget, Item *item)
+void TDEAcceleratorManagerPrivate::traverseChildren(TQWidget *widget, Item *item)
{
TQObjectList *childList = widget->queryList(TQWIDGET_OBJECT_NAME_STRING, 0, false, false);
for ( TQObject *it = childList->first(); it; it = childList->next() )
@@ -271,7 +271,7 @@ void KAcceleratorManagerPrivate::traverseChildren(TQWidget *widget, Item *item)
if ( !w->isVisibleTo( widget ) || ( w->isTopLevel() && dynamic_cast<TQPopupMenu*>(w) == NULL ) )
continue;
- if ( KAcceleratorManagerPrivate::ignored_widgets.find( w ) != KAcceleratorManagerPrivate::ignored_widgets.end() )
+ if ( TDEAcceleratorManagerPrivate::ignored_widgets.find( w ) != TDEAcceleratorManagerPrivate::ignored_widgets.end() )
continue;
manageWidget(w, item);
@@ -279,7 +279,7 @@ void KAcceleratorManagerPrivate::traverseChildren(TQWidget *widget, Item *item)
delete childList;
}
-void KAcceleratorManagerPrivate::manageWidget(TQWidget *w, Item *item)
+void TDEAcceleratorManagerPrivate::manageWidget(TQWidget *w, Item *item)
{
// first treat the special cases
@@ -301,7 +301,7 @@ void KAcceleratorManagerPrivate::manageWidget(TQWidget *w, Item *item)
if (popupMenu)
{
// create a popup accel manager that can deal with dynamic menus
- KPopupAccelManager::manage(popupMenu);
+ TDEPopupAccelManager::manage(popupMenu);
return;
}
@@ -368,26 +368,26 @@ void KAcceleratorManagerPrivate::manageWidget(TQWidget *w, Item *item)
i->m_widget = w;
// put some more weight on the usual action elements
- int weight = KAccelManagerAlgorithm::DEFAULT_WEIGHT;
+ int weight = TDEAccelManagerAlgorithm::DEFAULT_WEIGHT;
if (dynamic_cast<TQPushButton*>(w) || dynamic_cast<TQCheckBox*>(w) || dynamic_cast<TQRadioButton*>(w) || dynamic_cast<TQLabel*>(w))
- weight = KAccelManagerAlgorithm::ACTION_ELEMENT_WEIGHT;
+ weight = TDEAccelManagerAlgorithm::ACTION_ELEMENT_WEIGHT;
// don't put weight on group boxes, as usually the contents are more important
if (dynamic_cast<TQGroupBox*>(w))
- weight = KAccelManagerAlgorithm::GROUP_BOX_WEIGHT;
+ weight = TDEAccelManagerAlgorithm::GROUP_BOX_WEIGHT;
// put a lot of extra weight on the KDialogBaseButton's
if (w->inherits("KDialogBaseButton"))
- weight += KAccelManagerAlgorithm::DIALOG_BUTTON_EXTRA_WEIGHT;
+ weight += TDEAccelManagerAlgorithm::DIALOG_BUTTON_EXTRA_WEIGHT;
- i->m_content = KAccelString(content, weight);
+ i->m_content = TDEAccelString(content, weight);
item->addChild(i);
}
}
traverseChildren(w, item);
}
-void KAcceleratorManagerPrivate::manageTabBar(TQTabBar *bar, Item *item)
+void TDEAcceleratorManagerPrivate::manageTabBar(TQTabBar *bar, Item *item)
{
for (int i=0; i<bar->count(); i++)
{
@@ -399,11 +399,11 @@ void KAcceleratorManagerPrivate::manageTabBar(TQTabBar *bar, Item *item)
item->addChild(it);
it->m_widget = bar;
it->m_index = i;
- it->m_content = KAccelString(content);
+ it->m_content = TDEAccelString(content);
}
}
-void KAcceleratorManagerPrivate::manageMenuBar(TQMenuBar *mbar, Item *item)
+void TDEAcceleratorManagerPrivate::manageMenuBar(TQMenuBar *mbar, Item *item)
{
TQMenuItem *mitem;
TQString s;
@@ -424,9 +424,9 @@ void KAcceleratorManagerPrivate::manageMenuBar(TQMenuBar *mbar, Item *item)
Item *it = new Item;
item->addChild(it);
it->m_content =
- KAccelString(s,
+ TDEAccelString(s,
// menu titles are important, so raise the weight
- KAccelManagerAlgorithm::MENU_TITLE_WEIGHT);
+ TDEAccelManagerAlgorithm::MENU_TITLE_WEIGHT);
it->m_widget = mbar;
it->m_index = i;
@@ -434,49 +434,49 @@ void KAcceleratorManagerPrivate::manageMenuBar(TQMenuBar *mbar, Item *item)
// have a look at the popup as well, if present
if (mitem->popup())
- KPopupAccelManager::manage(mitem->popup());
+ TDEPopupAccelManager::manage(mitem->popup());
}
}
/*********************************************************************
- class KAcceleratorManager - main entry point
+ class TDEAcceleratorManager - main entry point
This class is just here to provide a clean public API...
*********************************************************************/
-void KAcceleratorManager::manage(TQWidget *widget)
+void TDEAcceleratorManager::manage(TQWidget *widget)
{
- KAcceleratorManager::manage(widget, false);
+ TDEAcceleratorManager::manage(widget, false);
}
-void KAcceleratorManager::manage(TQWidget *widget, bool programmers_mode)
+void TDEAcceleratorManager::manage(TQWidget *widget, bool programmers_mode)
{
- kdDebug(131) << "KAcceleratorManager::manage\n";
- KAcceleratorManagerPrivate::changed_string = TQString::null;
- KAcceleratorManagerPrivate::added_string = TQString::null;
- KAcceleratorManagerPrivate::removed_string = TQString::null;
- KAcceleratorManagerPrivate::programmers_mode = programmers_mode;
- KAcceleratorManagerPrivate::manage(widget);
+ kdDebug(131) << "TDEAcceleratorManager::manage\n";
+ TDEAcceleratorManagerPrivate::changed_string = TQString::null;
+ TDEAcceleratorManagerPrivate::added_string = TQString::null;
+ TDEAcceleratorManagerPrivate::removed_string = TQString::null;
+ TDEAcceleratorManagerPrivate::programmers_mode = programmers_mode;
+ TDEAcceleratorManagerPrivate::manage(widget);
}
-void KAcceleratorManager::last_manage(TQString &added, TQString &changed, TQString &removed)
+void TDEAcceleratorManager::last_manage(TQString &added, TQString &changed, TQString &removed)
{
- added = KAcceleratorManagerPrivate::added_string;
- changed = KAcceleratorManagerPrivate::changed_string;
- removed = KAcceleratorManagerPrivate::removed_string;
+ added = TDEAcceleratorManagerPrivate::added_string;
+ changed = TDEAcceleratorManagerPrivate::changed_string;
+ removed = TDEAcceleratorManagerPrivate::removed_string;
}
/*********************************************************************
- class KAccelString - a string with weighted characters
+ class TDEAccelString - a string with weighted characters
*********************************************************************/
-KAccelString::KAccelString(const TQString &input, int initialWeight)
+TDEAccelString::TDEAccelString(const TQString &input, int initialWeight)
: m_pureText(input), m_weight()
{
m_orig_accel = m_pureText.find("(!)&");
@@ -495,7 +495,7 @@ KAccelString::KAccelString(const TQString &input, int initialWeight)
m_orig_accel = m_accel = stripAccelerator(m_pureText);
if (initialWeight == -1)
- initialWeight = KAccelManagerAlgorithm::DEFAULT_WEIGHT;
+ initialWeight = TDEAccelManagerAlgorithm::DEFAULT_WEIGHT;
calculateWeights(initialWeight);
@@ -503,13 +503,13 @@ KAccelString::KAccelString(const TQString &input, int initialWeight)
}
-TQString KAccelString::accelerated() const
+TQString TDEAccelString::accelerated() const
{
TQString result = m_origText;
if (result.isEmpty())
return result;
- if (KAcceleratorManagerPrivate::programmers_mode)
+ if (TDEAcceleratorManagerPrivate::programmers_mode)
{
if (m_accel != m_orig_accel) {
int oa = m_orig_accel;
@@ -532,7 +532,7 @@ TQString KAccelString::accelerated() const
}
-TQChar KAccelString::accelerator() const
+TQChar TDEAccelString::accelerator() const
{
if ((m_accel < 0) || (m_accel > (int)m_pureText.length()))
return TQChar();
@@ -541,7 +541,7 @@ TQChar KAccelString::accelerator() const
}
-void KAccelString::calculateWeights(int initialWeight)
+void TDEAccelString::calculateWeights(int initialWeight)
{
m_weight.resize(m_pureText.length());
@@ -556,12 +556,12 @@ void KAccelString::calculateWeights(int initialWeight)
// add special weight to first character
if (pos == 0)
- weight += KAccelManagerAlgorithm::FIRST_CHARACTER_EXTRA_WEIGHT;
+ weight += TDEAccelManagerAlgorithm::FIRST_CHARACTER_EXTRA_WEIGHT;
// add weight to word beginnings
if (start_character)
{
- weight += KAccelManagerAlgorithm::WORD_BEGINNING_EXTRA_WEIGHT;
+ weight += TDEAccelManagerAlgorithm::WORD_BEGINNING_EXTRA_WEIGHT;
start_character = false;
}
@@ -571,10 +571,10 @@ void KAccelString::calculateWeights(int initialWeight)
// try to preserve the wanted accelarators
if ((int)pos == accel()) {
- weight += KAccelManagerAlgorithm::WANTED_ACCEL_EXTRA_WEIGHT;
- // kdDebug(131) << "wanted " << m_pureText << " " << KAcceleratorManagerPrivate::standardName(m_origText) << endl;
- if (KAcceleratorManagerPrivate::standardName(m_origText)) {
- weight += KAccelManagerAlgorithm::STANDARD_ACCEL;
+ weight += TDEAccelManagerAlgorithm::WANTED_ACCEL_EXTRA_WEIGHT;
+ // kdDebug(131) << "wanted " << m_pureText << " " << TDEAcceleratorManagerPrivate::standardName(m_origText) << endl;
+ if (TDEAcceleratorManagerPrivate::standardName(m_origText)) {
+ weight += TDEAccelManagerAlgorithm::STANDARD_ACCEL;
}
}
@@ -592,7 +592,7 @@ void KAccelString::calculateWeights(int initialWeight)
}
-int KAccelString::stripAccelerator(TQString &text)
+int TDEAccelString::stripAccelerator(TQString &text)
{
// Note: this code is derived from TQAccel::shortcutKey
int p = 0;
@@ -621,7 +621,7 @@ int KAccelString::stripAccelerator(TQString &text)
}
-int KAccelString::maxWeight(int &index, const TQString &used)
+int TDEAccelString::maxWeight(int &index, const TQString &used)
{
int max = 0;
index = -1;
@@ -638,7 +638,7 @@ int KAccelString::maxWeight(int &index, const TQString &used)
}
-void KAccelString::dump()
+void TDEAccelString::dump()
{
TQString s;
for (uint i=0; i<m_weight.count(); ++i)
@@ -680,13 +680,13 @@ void KAccelString::dump()
*********************************************************************/
-void KAccelManagerAlgorithm::findAccelerators(KAccelStringList &result, TQString &used)
+void TDEAccelManagerAlgorithm::findAccelerators(TDEAccelStringList &result, TQString &used)
{
kdDebug(131) << "findAccelerators\n";
- KAccelStringList accel_strings = result;
+ TDEAccelStringList accel_strings = result;
// initally remove all accelerators
- for (KAccelStringList::Iterator it = result.begin(); it != result.end(); ++it) {
+ for (TDEAccelStringList::Iterator it = result.begin(); it != result.end(); ++it) {
(*it).setAccel(-1);
}
@@ -720,18 +720,18 @@ void KAccelManagerAlgorithm::findAccelerators(KAccelStringList &result, TQString
}
// make sure we don't visit this one again
- accel_strings[index] = KAccelString();
+ accel_strings[index] = TDEAccelString();
}
}
/*********************************************************************
- class KPopupAccelManager - managing TQPopupMenu widgets dynamically
+ class TDEPopupAccelManager - managing TQPopupMenu widgets dynamically
*********************************************************************/
-KPopupAccelManager::KPopupAccelManager(TQPopupMenu *popup)
+TDEPopupAccelManager::TDEPopupAccelManager(TQPopupMenu *popup)
: TQObject(popup), m_popup(popup), m_count(-1)
{
aboutToShow(); // do one check and then connect to show
@@ -739,7 +739,7 @@ KPopupAccelManager::KPopupAccelManager(TQPopupMenu *popup)
}
-void KPopupAccelManager::aboutToShow()
+void TDEPopupAccelManager::aboutToShow()
{
// Note: we try to be smart and avoid recalculating the accelerators
// whenever possible. Unfortunately, there is no way to know if an
@@ -754,7 +754,7 @@ void KPopupAccelManager::aboutToShow()
}
else
{
- KAccelStringList entries;
+ TDEAccelStringList entries;
findMenuEntries(entries);
if (entries != m_entries)
{
@@ -765,18 +765,18 @@ void KPopupAccelManager::aboutToShow()
}
-void KPopupAccelManager::calculateAccelerators()
+void TDEPopupAccelManager::calculateAccelerators()
{
// find the new accelerators
TQString used;
- KAccelManagerAlgorithm::findAccelerators(m_entries, used);
+ TDEAccelManagerAlgorithm::findAccelerators(m_entries, used);
// change the menu entries
setMenuEntries(m_entries);
}
-void KPopupAccelManager::findMenuEntries(KAccelStringList &list)
+void TDEPopupAccelManager::findMenuEntries(TDEAccelStringList &list)
{
TQMenuItem *mitem;
TQString s;
@@ -797,16 +797,16 @@ void KPopupAccelManager::findMenuEntries(KAccelStringList &list)
if (s.contains('\t'))
weight = 0;
- list.append(KAccelString(s, weight));
+ list.append(TDEAccelString(s, weight));
// have a look at the popup as well, if present
if (mitem->popup())
- KPopupAccelManager::manage(mitem->popup());
+ TDEPopupAccelManager::manage(mitem->popup());
}
}
-void KPopupAccelManager::setMenuEntries(const KAccelStringList &list)
+void TDEPopupAccelManager::setMenuEntries(const TDEAccelStringList &list)
{
TQMenuItem *mitem;
@@ -817,18 +817,18 @@ void KPopupAccelManager::setMenuEntries(const KAccelStringList &list)
if (mitem->isSeparator())
continue;
- if (KAcceleratorManagerPrivate::checkChange(list[cnt]))
+ if (TDEAcceleratorManagerPrivate::checkChange(list[cnt]))
mitem->setText(list[cnt].accelerated());
cnt++;
}
}
-void KPopupAccelManager::manage(TQPopupMenu *popup)
+void TDEPopupAccelManager::manage(TQPopupMenu *popup)
{
// don't add more than one manager to a popup
- if (popup->child(0, "KPopupAccelManager", false) == 0 )
- new KPopupAccelManager(popup);
+ if (popup->child(0, "TDEPopupAccelManager", false) == 0 )
+ new TDEPopupAccelManager(popup);
}
void QWidgetStackAccelManager::manage( TQWidgetStack *stack )
@@ -847,7 +847,7 @@ QWidgetStackAccelManager::QWidgetStackAccelManager(TQWidgetStack *stack)
bool QWidgetStackAccelManager::eventFilter ( TQObject * watched, TQEvent * e )
{
if ( e->type() == TQEvent::Show && tqApp->activeWindow() ) {
- KAcceleratorManager::manage( TQT_TQWIDGET(tqApp->activeWindow()) );
+ TDEAcceleratorManager::manage( TQT_TQWIDGET(tqApp->activeWindow()) );
watched->removeEventFilter( this );
}
return false;
@@ -864,9 +864,9 @@ void QWidgetStackAccelManager::aboutToShow(TQWidget *child)
child->installEventFilter( this );
}
-void KAcceleratorManager::setNoAccel( TQWidget *widget )
+void TDEAcceleratorManager::setNoAccel( TQWidget *widget )
{
- KAcceleratorManagerPrivate::ignored_widgets[widget] = 1;
+ TDEAcceleratorManagerPrivate::ignored_widgets[widget] = 1;
}
#include "kaccelmanager_private.moc"
diff --git a/tdecore/kaccelmanager.h b/tdecore/kaccelmanager.h
index 29304803b..03ee627b3 100644
--- a/tdecore/kaccelmanager.h
+++ b/tdecore/kaccelmanager.h
@@ -37,7 +37,7 @@ class TQString;
* @since 3.1
*/
-class TDECORE_EXPORT KAcceleratorManager
+class TDECORE_EXPORT TDEAcceleratorManager
{
public:
@@ -69,7 +69,7 @@ public:
*
* TODO KDE4: merge with the above
* @param widget The toplevel widget you want to manage.
- * @param programmers_mode if true, KAcceleratorManager adds (&) for removed
+ * @param programmers_mode if true, TDEAcceleratorManager adds (&) for removed
* accels and & before added accels
*/
static void manage(TQWidget *widget, bool programmers_mode);
diff --git a/tdecore/kaccelmanager_private.h b/tdecore/kaccelmanager_private.h
index e931b7e3e..ed401801e 100644
--- a/tdecore/kaccelmanager_private.h
+++ b/tdecore/kaccelmanager_private.h
@@ -39,12 +39,12 @@ class TQWidgetStack;
* @author Matthias Hoelzer-Kluepfel <mhk@kde.org>
*/
-class KAccelString
+class TDEAccelString
{
public:
- KAccelString() : m_pureText(), m_accel(-1) {}
- KAccelString(const TQString &input, int initalWeight=-1);
+ TDEAccelString() : m_pureText(), m_accel(-1) {}
+ TDEAccelString(const TQString &input, int initalWeight=-1);
void calculateWeights(int initialWeight);
@@ -61,7 +61,7 @@ public:
int maxWeight(int &index, const TQString &used);
- bool operator == (const KAccelString &c) const { return m_pureText == c.m_pureText && m_accel == c.m_accel && m_orig_accel == c.m_orig_accel; }
+ bool operator == (const TDEAccelString &c) const { return m_pureText == c.m_pureText && m_accel == c.m_accel && m_orig_accel == c.m_orig_accel; }
private:
@@ -77,7 +77,7 @@ private:
};
-typedef TQValueList<KAccelString> KAccelStringList;
+typedef TQValueList<TDEAccelString> TDEAccelStringList;
/**
@@ -87,7 +87,7 @@ typedef TQValueList<KAccelString> KAccelStringList;
* @author Matthias Hoelzer-Kluepfel <mhk@kde.org>
*/
-class KAccelManagerAlgorithm
+class TDEAccelManagerAlgorithm
{
public:
@@ -114,7 +114,7 @@ public:
};
/// Method to call to find the best distribution of accelerators.
- static void findAccelerators(KAccelStringList &result, TQString &used);
+ static void findAccelerators(TDEAccelStringList &result, TQString &used);
};
@@ -131,7 +131,7 @@ class TQPopupMenu;
* @author Matthias Hoelzer-Kluepfel <mhk@kde.org>
*/
-class KPopupAccelManager : public TQObject
+class TDEPopupAccelManager : public TQObject
{
Q_OBJECT
@@ -142,7 +142,7 @@ public:
protected:
- KPopupAccelManager(TQPopupMenu *popup);
+ TDEPopupAccelManager(TQPopupMenu *popup);
private slots:
@@ -154,11 +154,11 @@ private:
void calculateAccelerators();
- void findMenuEntries(KAccelStringList &list);
- void setMenuEntries(const KAccelStringList &list);
+ void findMenuEntries(TDEAccelStringList &list);
+ void setMenuEntries(const TDEAccelStringList &list);
TQPopupMenu *m_popup;
- KAccelStringList m_entries;
+ TDEAccelStringList m_entries;
int m_count;
};
@@ -188,7 +188,7 @@ private:
void calculateAccelerators();
TQWidgetStack *m_stack;
- KAccelStringList m_entries;
+ TDEAccelStringList m_entries;
};
diff --git a/tdecore/kaccelprivate.h b/tdecore/kaccelprivate.h
index 8d009b950..0d967998d 100644
--- a/tdecore/kaccelprivate.h
+++ b/tdecore/kaccelprivate.h
@@ -4,22 +4,22 @@
#include "kkeyserver_x11.h"
#include <tqtimer.h>
-class KAccelAction;
+class TDEAccelAction;
/**
* @internal
*/
-class TDECORE_EXPORT KAccelPrivate : public TQObject, public KAccelBase
+class TDECORE_EXPORT TDEAccelPrivate : public TQObject, public TDEAccelBase
{
Q_OBJECT
public:
- KAccel* m_pAccel;
+ TDEAccel* m_pAccel;
TQWidget* m_pWatch;
TQMap<int, int> m_mapIDToKey;
- TQMap<int, KAccelAction*> m_mapIDToAction;
+ TQMap<int, TDEAccelAction*> m_mapIDToAction;
TQTimer m_timerShowMenu;
- KAccelPrivate( KAccel* pParent, TQWidget* pWatch );
+ TDEAccelPrivate( TDEAccel* pParent, TQWidget* pWatch );
virtual void setEnabled( bool bEnabled );
@@ -27,19 +27,19 @@ class TDECORE_EXPORT KAccelPrivate : public TQObject, public KAccelBase
virtual bool removeAction( const TQString& sAction );
- virtual bool emitSignal( KAccelBase::Signal signal );
- virtual bool connectKey( KAccelAction& action, const KKeyServer::Key& key );
+ virtual bool emitSignal( TDEAccelBase::Signal signal );
+ virtual bool connectKey( TDEAccelAction& action, const KKeyServer::Key& key );
virtual bool connectKey( const KKeyServer::Key& key );
- virtual bool disconnectKey( KAccelAction& action, const KKeyServer::Key& key );
+ virtual bool disconnectKey( TDEAccelAction& action, const KKeyServer::Key& key );
virtual bool disconnectKey( const KKeyServer::Key& key );
signals:
void menuItemActivated();
- void menuItemActivated(KAccelAction*);
+ void menuItemActivated(TDEAccelAction*);
private:
#ifndef Q_WS_WIN /** @todo TEMP: new implementation (commit #424926) didn't work */
- void emitActivatedSignal(KAccelAction*);
+ void emitActivatedSignal(TDEAccelAction*);
#endif
private slots:
diff --git a/tdecore/kapplication.cpp b/tdecore/kapplication.cpp
index b55f0743b..705713a7e 100644
--- a/tdecore/kapplication.cpp
+++ b/tdecore/kapplication.cpp
@@ -272,7 +272,7 @@ public:
bool guiEnabled : 1;
/**
* This counter indicates when to exit the application.
- * It starts at 1, is decremented in KMainWindow when the last window is closed, but
+ * It starts at 1, is decremented in TDEMainWindow when the last window is closed, but
* is incremented by operations that should outlive the last window closed
* (e.g. a file copy for a file manager, or 'compacting folders on exit' for a mail client).
*/
@@ -468,7 +468,7 @@ void TDEApplication::removeX11EventFilter( const TQWidget* filter )
// FIXME: remove this when we've get a better method of
// customizing accelerator handling -- hopefully in Qt.
// For now, this is set whenever an accelerator is overridden
-// in KAccelEventHandler so that the AccelOverride isn't sent twice. -- ellis, 19/10/02
+// in TDEAccelEventHandler so that the AccelOverride isn't sent twice. -- ellis, 19/10/02
extern bool kde_g_bKillAccelOverride;
bool TDEApplication::notify(TQObject *receiver, TQEvent *event)
@@ -489,7 +489,7 @@ bool TDEApplication::notify(TQObject *receiver, TQEvent *event)
if ((t == TQEvent::AccelOverride) || (t == TQEvent::KeyPress))
{
- static const KShortcut& _selectAll = KStdAccel::selectAll();
+ static const TDEShortcut& _selectAll = TDEStdAccel::selectAll();
TQLineEdit *edit = ::tqqt_cast<TQLineEdit *>(receiver);
if (edit)
{
@@ -1297,7 +1297,7 @@ void TDEApplication::commitData( TQSessionManager& sm )
bool canceled = false;
TQWidget* w = list->first();
while ( !canceled && w ) {
- if ( !w->testWState( WState_ForceHide ) && !w->inherits("KMainWindow") ) {
+ if ( !w->testWState( WState_ForceHide ) && !w->inherits("TDEMainWindow") ) {
TQCloseEvent e;
sendEvent( w, &e );
canceled = !e.isAccepted();
@@ -2458,7 +2458,7 @@ void TDEApplication::kdisplaySetFont()
TQApplication::setFont(TDEGlobalSettings::generalFont(), true);
TQApplication::setFont(TDEGlobalSettings::menuFont(), true, TQMENUBAR_OBJECT_NAME_STRING);
TQApplication::setFont(TDEGlobalSettings::menuFont(), true, TQPOPUPMENU_OBJECT_NAME_STRING);
- TQApplication::setFont(TDEGlobalSettings::menuFont(), true, "KPopupTitle");
+ TQApplication::setFont(TDEGlobalSettings::menuFont(), true, "TDEPopupTitle");
// "patch" standard TQStyleSheet to follow our fonts
TQStyleSheet* sheet = TQStyleSheet::defaultSheet();
@@ -2544,11 +2544,11 @@ void TDEApplication::installKDEPropertyMap()
kdeMap->insert( "KDateWidget", "date" );
kdeMap->insert( "KDateTimeWidget", "dateTime" );
kdeMap->insert( "KEditListBox", "items" );
- kdeMap->insert( "KFontCombo", "family" );
- kdeMap->insert( "KFontRequester", "font" );
- kdeMap->insert( "KFontChooser", "font" );
+ kdeMap->insert( "TDEFontCombo", "family" );
+ kdeMap->insert( "TDEFontRequester", "font" );
+ kdeMap->insert( "TDEFontChooser", "font" );
kdeMap->insert( "KHistoryCombo", "currentItem" );
- kdeMap->insert( "KListBox", "currentItem" );
+ kdeMap->insert( "TDEListBox", "currentItem" );
kdeMap->insert( "KLineEdit", "text" );
kdeMap->insert( "KRestrictedLine", "text" );
kdeMap->insert( "KSqueezedTextLabel", "text" );
@@ -3033,7 +3033,7 @@ startServiceInternal( const TQCString &function,
function, params, replyType, replyData))
{
if (error)
- *error = i18n("KLauncher could not be reached via DCOP.\n");
+ *error = i18n("TDELauncher could not be reached via DCOP.\n");
if (!kapp)
delete dcopClient;
return -1;
@@ -3255,7 +3255,7 @@ void TDEApplication::setTopWidget( TQWidget *topWidget )
return;
// set the specified caption
- if ( !topWidget->inherits("KMainWindow") ) { // KMainWindow does this already for us
+ if ( !topWidget->inherits("TDEMainWindow") ) { // TDEMainWindow does this already for us
topWidget->setCaption( caption() );
}
@@ -3356,7 +3356,7 @@ bool TDEApplication::authorize(const TQString &genericAction)
return config->readBoolEntry(genericAction, true);
}
-bool TDEApplication::authorizeKAction(const char *action)
+bool TDEApplication::authorizeTDEAction(const char *action)
{
if (!d->actionRestrictions || !action)
return true;
diff --git a/tdecore/kapplication.h b/tdecore/kapplication.h
index eae310c4e..f59c307eb 100644
--- a/tdecore/kapplication.h
+++ b/tdecore/kapplication.h
@@ -432,10 +432,10 @@ public:
/**
* Returns true if the application is currently saving its session
* data (most probably before KDE logout). This is intended for use
- * mainly in KMainWindow::queryClose() and KMainWindow::queryExit().
+ * mainly in TDEMainWindow::queryClose() and TDEMainWindow::queryExit().
*
- * @see KMainWindow::queryClose
- * @see KMainWindow::queryExit
+ * @see TDEMainWindow::queryClose
+ * @see TDEMainWindow::queryExit
* @since 3.1.1
*/
bool sessionSaving() const;
@@ -482,7 +482,7 @@ public:
* Sets the top widget of the application.
* This means basically applying the right window caption and
* icon. An application may have several top widgets. You don't
- * need to call this function manually when using KMainWindow.
+ * need to call this function manually when using TDEMainWindow.
*
* @param topWidget A top widget of the application.
*
@@ -627,21 +627,21 @@ public slots:
* If the widget with focus provides a clear() slot, call that slot. Thus for a
* simple application clear() can be implemented as:
* \code
- * new KAction( i18n( "Clear" ), "editclear", 0, kapp, TQT_SLOT( clear() ), actionCollection(), "clear" );
+ * new TDEAction( i18n( "Clear" ), "editclear", 0, kapp, TQT_SLOT( clear() ), actionCollection(), "clear" );
* \endcode
*
* Note that for some widgets, this may not provide the intended bahavior. For
- * example if you make use of the code above and a KListView has the focus, clear()
+ * example if you make use of the code above and a TDEListView has the focus, clear()
* will clear all of the items in the list. If this is not the intened behavior
- * and you want to make use of this slot, you can subclass KListView and reimplement
- * this slot. For example the following code would implement a KListView without this
+ * and you want to make use of this slot, you can subclass TDEListView and reimplement
+ * this slot. For example the following code would implement a TDEListView without this
* behavior:
*
* \code
- * class MyListView : public KListView {
+ * class MyListView : public TDEListView {
* Q_OBJECT
* public:
- * MyListView( TQWidget * parent = 0, const char * name = 0, WFlags f = 0 ) : KListView( parent, name, f ) {}
+ * MyListView( TQWidget * parent = 0, const char * name = 0, WFlags f = 0 ) : TDEListView( parent, name, f ) {}
* virtual ~MyListView() {}
* public slots:
* virtual void clear() {}
@@ -1121,13 +1121,13 @@ public:
bool authorize(const TQString &genericAction);
/**
- * Returns whether a certain KAction is authorized.
+ * Returns whether a certain TDEAction is authorized.
*
- * @param action The name of a KAction action. The name is prepended
+ * @param action The name of a TDEAction action. The name is prepended
* with "action/" before being passed to authorize()
- * @return true if the KAction is authorized
+ * @return true if the TDEAction is authorized
*/
- bool authorizeKAction(const char *action);
+ bool authorizeTDEAction(const char *action);
/**
* Returns whether a certain URL related action is authorized.
@@ -1272,7 +1272,7 @@ protected:
* \endcode
*
* Now in your application calls to MyApplication::deselect() will call this slot on the
- * focused widget if it provides this slot. You can combine this with KAction with:
+ * focused widget if it provides this slot. You can combine this with TDEAction with:
*
* \code
* KStdAction::deselect( static_cast<MyApplication *>( kapp ), TQT_SLOT( cut() ), actionCollection() );
@@ -1438,7 +1438,7 @@ signals:
void appearanceChanged();
/**
- * Emitted when the settings for toolbars have been changed. KToolBar will know what to do.
+ * Emitted when the settings for toolbars have been changed. TDEToolBar will know what to do.
*/
void toolbarAppearanceChanged(int);
@@ -1478,12 +1478,12 @@ signals:
Session management asks you to save the state of your application.
This signal is provided for compatibility only. For new
- applications, simply use KMainWindow. By reimplementing
- KMainWindow::queryClose(), KMainWindow::saveProperties() and
- KMainWindow::readProperties() you can simply handle session
+ applications, simply use TDEMainWindow. By reimplementing
+ TDEMainWindow::queryClose(), TDEMainWindow::saveProperties() and
+ TDEMainWindow::readProperties() you can simply handle session
management for applications with multiple toplevel windows.
- For purposes without KMainWindow, create an instance of
+ For purposes without TDEMainWindow, create an instance of
KSessionManaged and reimplement the functions
KSessionManaged::commitData() and/or
KSessionManaged::saveState()
@@ -1572,12 +1572,12 @@ class KSessionManagedPrivate;
KSessionManaged makes it possible to provide implementations for
TQApplication::commitData() and TQApplication::saveState(), without
- subclassing TDEApplication. KMainWindow internally makes use of this.
+ subclassing TDEApplication. TDEMainWindow internally makes use of this.
You don't need to do anything with this class when using
- KMainWindow. Instead, use KMainWindow::saveProperties(),
- KMainWindow::readProperties(), KMainWindow::queryClose(),
- KMainWindow::queryExit() and friends.
+ TDEMainWindow. Instead, use TDEMainWindow::saveProperties(),
+ TDEMainWindow::readProperties(), TDEMainWindow::queryClose(),
+ TDEMainWindow::queryExit() and friends.
@short Highlevel access to session management.
@author Matthias Ettrich <ettrich@kde.org>
diff --git a/tdecore/kcheckaccelerators.cpp b/tdecore/kcheckaccelerators.cpp
index 1051cd362..ec11f50a8 100644
--- a/tdecore/kcheckaccelerators.cpp
+++ b/tdecore/kcheckaccelerators.cpp
@@ -83,7 +83,7 @@ KCheckAccelerators::KCheckAccelerators( TQObject* parent )
TDEConfigGroupSaver saver( TDEGlobal::config(), "Development" );
TQString sKey = TDEGlobal::config()->readEntry( "CheckAccelerators" ).stripWhiteSpace();
if( !sKey.isEmpty() ) {
- KShortcut cuts( sKey );
+ TDEShortcut cuts( sKey );
if( cuts.count() > 0 )
key = int(cuts.seq(0).qt());
}
@@ -177,9 +177,9 @@ void KCheckAccelerators::checkAccelerators( bool automatic )
if ( !actWin )
return;
- KAcceleratorManager::manage(actWin);
+ TDEAcceleratorManager::manage(actWin);
TQString a, c, r;
- KAcceleratorManager::last_manage(a, c, r);
+ TDEAcceleratorManager::last_manage(a, c, r);
if (automatic) // for now we only show dialogs on F12 checks
return;
diff --git a/tdecore/kcompletion.h b/tdecore/kcompletion.h
index 45182bd9d..020512b43 100644
--- a/tdecore/kcompletion.h
+++ b/tdecore/kcompletion.h
@@ -666,7 +666,7 @@ public:
/**
* Constants that represent the items whose short-cut
* key-binding is programmable. The default key-bindings
- * for these items are defined in KStdAccel.
+ * for these items are defined in TDEStdAccel.
*/
enum KeyBindingType {
/**
@@ -689,7 +689,7 @@ public:
// Map for the key binding types mentioned above.
- typedef TQMap<KeyBindingType, KShortcut> KeyBindingMap;
+ typedef TQMap<KeyBindingType, TDEShortcut> KeyBindingMap;
/**
* Default constructor.
@@ -885,7 +885,7 @@ public:
* @return true if key-binding can successfully be set.
* @see getKeyBinding
*/
- bool setKeyBinding( KeyBindingType item , const KShortcut& key );
+ bool setKeyBinding( KeyBindingType item , const TDEShortcut& key );
/**
* Returns the key-binding used for the specified item.
@@ -899,7 +899,7 @@ public:
* @return the key-binding used for the feature given by @p item.
* @see setKeyBinding
*/
- const KShortcut& getKeyBinding( KeyBindingType item ) const {
+ const TDEShortcut& getKeyBinding( KeyBindingType item ) const {
return m_delegate ? m_delegate->getKeyBinding( item ) : m_keyMap[ item ];
}
diff --git a/tdecore/kcompletionbase.cpp b/tdecore/kcompletionbase.cpp
index 7589d842c..676448428 100644
--- a/tdecore/kcompletionbase.cpp
+++ b/tdecore/kcompletionbase.cpp
@@ -112,7 +112,7 @@ void KCompletionBase::setCompletionMode( TDEGlobalSettings::Completion mode )
m_pCompObj->setCompletionMode( m_iCompletionMode );
}
-bool KCompletionBase::setKeyBinding( KeyBindingType item, const KShortcut& cut )
+bool KCompletionBase::setKeyBinding( KeyBindingType item, const TDEShortcut& cut )
{
if ( m_delegate )
return m_delegate->setKeyBinding( item, cut );
diff --git a/tdecore/kdebug.areas b/tdecore/kdebug.areas
index 9998163e2..831b06fdf 100644
--- a/tdecore/kdebug.areas
+++ b/tdecore/kdebug.areas
@@ -5,13 +5,13 @@
#
#Format : number<tab>description
-125 tdecore (KAccel)
+125 tdecore (TDEAccel)
126 tdecore (KURL)
127 kio (KProtocolInfo)
128 tdecore (KRegExp)
-129 tdecore (KAction)
+129 tdecore (TDEAction)
130 kio (KPasswdServer)
-131 tdecore (KAcceleratorManager)
+131 tdecore (TDEAcceleratorManager)
150 tdecore (KLibLoader)
160 tdecore (KNotifyClient)
170 tdecore (KNetwork socket)
@@ -25,8 +25,8 @@
178 tdecore (TDEConfigDialogManager)
179 tdecore (KNetwork resolver)
180 tdecore (tdelibs)
-200 tdeui (KMainWindow)
-220 tdeui (KToolBar)
+200 tdeui (TDEMainWindow)
+220 tdeui (TDEToolBar)
230 tdeui (KCommand)
240 tdeui (tdelibs)
250 tdefile (tdelibs)
@@ -42,7 +42,7 @@
293 tdeui (KLineEdit)
294 tdeui (KEdit)
295 tdeui (KMenuBar)
-296 tdeui (KPopupMenu)
+296 tdeui (TDEPopupMenu)
298 tdeui (KDatePicker)
399 kimgio
400 artskde
@@ -236,7 +236,7 @@
7013 kio (KPing)
7014 kio (TDETrader)
7015 kio (KAutoMount)
-7016 kio (KLauncher)
+7016 kio (TDELauncher)
7017 kio (KIOConnection)
7018 kio (KMimeMagic)
7019 kio (tdeioslave)
diff --git a/tdecore/kdebugrc b/tdecore/kdebugrc
index c697da031..0335f4e5b 100644
--- a/tdecore/kdebugrc
+++ b/tdecore/kdebugrc
@@ -32,7 +32,7 @@
# AbortFatal=1
#
-# KAccel debug info off
+# TDEAccel debug info off
[125]
InfoOutput=4
@@ -40,7 +40,7 @@ InfoOutput=4
[131]
InfoOutput=4
-# KAction debug info off
+# TDEAction debug info off
[129]
InfoOutput=4
@@ -52,7 +52,7 @@ InfoOutput=4
[173]
InfoOutput=4
-# KMainWindow debug info off
+# TDEMainWindow debug info off
[200]
InfoOutput=4
diff --git a/tdecore/kglobalaccel.cpp b/tdecore/kglobalaccel.cpp
index 3d759466f..eb1b56323 100644
--- a/tdecore/kglobalaccel.cpp
+++ b/tdecore/kglobalaccel.cpp
@@ -53,14 +53,14 @@ TDEGlobalAccel::~TDEGlobalAccel()
void TDEGlobalAccel::clear()
{ d->clearActions(); }
*/
-KAccelActions& TDEGlobalAccel::actions()
- { return d->KAccelBase::actions(); }
+TDEAccelActions& TDEGlobalAccel::actions()
+ { return d->TDEAccelBase::actions(); }
-const KAccelActions& TDEGlobalAccel::actions() const
- { return d->KAccelBase::actions(); }
+const TDEAccelActions& TDEGlobalAccel::actions() const
+ { return d->TDEAccelBase::actions(); }
bool TDEGlobalAccel::isEnabled()
- { return ((KAccelBase*)d)->isEnabled(); }
+ { return ((TDEAccelBase*)d)->isEnabled(); }
void TDEGlobalAccel::setEnabled( bool bEnabled )
{ d->setEnabled( bEnabled ); }
@@ -74,8 +74,8 @@ void TDEGlobalAccel::blockShortcuts( bool block )
void TDEGlobalAccel::disableBlocking( bool disable )
{ d->disableBlocking( disable ); }
-KAccelAction* TDEGlobalAccel::insert( const TQString& sAction, const TQString& sDesc, const TQString& sHelp,
- const KShortcut& cutDef3, const KShortcut& cutDef4,
+TDEAccelAction* TDEGlobalAccel::insert( const TQString& sAction, const TQString& sDesc, const TQString& sHelp,
+ const TDEShortcut& cutDef3, const TDEShortcut& cutDef4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable, bool bEnabled )
{
@@ -85,7 +85,7 @@ KAccelAction* TDEGlobalAccel::insert( const TQString& sAction, const TQString& s
bConfigurable, bEnabled );
}
-KAccelAction* TDEGlobalAccel::insert( const TQString& sName, const TQString& sDesc )
+TDEAccelAction* TDEGlobalAccel::insert( const TQString& sName, const TQString& sDesc )
{ return d->insert( sName, sDesc ); }
bool TDEGlobalAccel::updateConnections()
{ return d->updateConnections(); }
@@ -93,19 +93,19 @@ bool TDEGlobalAccel::updateConnections()
bool TDEGlobalAccel::remove( const TQString& sAction )
{ return d->remove( sAction ); }
-const KShortcut& TDEGlobalAccel::shortcut( const TQString& sAction ) const
+const TDEShortcut& TDEGlobalAccel::shortcut( const TQString& sAction ) const
{
- const KAccelAction* pAction = d->KAccelBase::actions().actionPtr( sAction );
- return (pAction) ? pAction->shortcut() : KShortcut::null();
+ const TDEAccelAction* pAction = d->TDEAccelBase::actions().actionPtr( sAction );
+ return (pAction) ? pAction->shortcut() : TDEShortcut::null();
}
-bool TDEGlobalAccel::setShortcut( const TQString& sAction, const KShortcut& cut )
+bool TDEGlobalAccel::setShortcut( const TQString& sAction, const TDEShortcut& cut )
{ return d->setShortcut( sAction, cut ); }
bool TDEGlobalAccel::setSlot( const TQString& sAction, const TQObject* pObjSlot, const char* psMethodSlot )
{ return d->setActionSlot( sAction, pObjSlot, psMethodSlot ); }
TQString TDEGlobalAccel::label( const TQString& sAction ) const
{
- const KAccelAction* pAction = d->KAccelBase::actions().actionPtr( sAction );
+ const TDEAccelAction* pAction = d->TDEAccelBase::actions().actionPtr( sAction );
return (pAction) ? pAction->label() : TQString();
}
bool TDEGlobalAccel::setActionEnabled( const TQString& sAction, bool bEnable )
@@ -131,7 +131,7 @@ bool TDEGlobalAccel::writeSettings( TDEConfigBase* pConfig, bool bGlobal ) const
}
bool TDEGlobalAccel::useFourModifierKeys()
- { return KAccelAction::useFourModifierKeys(); }
+ { return TDEAccelAction::useFourModifierKeys(); }
void TDEGlobalAccel::virtual_hook( int, void* )
{ /*BASE::virtual_hook( id, data );*/ }
diff --git a/tdecore/kglobalaccel.h b/tdecore/kglobalaccel.h
index fdda08f5a..9606b8af1 100644
--- a/tdecore/kglobalaccel.h
+++ b/tdecore/kglobalaccel.h
@@ -25,19 +25,19 @@
class TQPopupMenu;
class TQWidget;
-class KAccelAction;
-class KAccelActions;
+class TDEAccelAction;
+class TDEAccelActions;
class TDEConfigBase;
class TDEGlobalAccelPrivate;
/**
* TDEGlobalAccel allows you to have global accelerators that are independent of
-* the focused window. Unlike KAccel it does not matter which window is
+* the focused window. Unlike TDEAccel it does not matter which window is
* currently active.
*
-* @see KAccel
-* @see KAccelShortcutList
+* @see TDEAccel
+* @see TDEAccelShortcutList
* @see KKeyChooser
* @see KKeyDialog
* @short Configurable global shortcut support
@@ -90,8 +90,8 @@ class TDECORE_EXPORT TDEGlobalAccel : public TQObject
* @param bConfigurable Allow the user to change this shortcut if set to 'true'.
* @param bEnabled The action will be activated by the shortcut if set to 'true'.
*/
- KAccelAction* insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
- const KShortcut& cutDef3, const KShortcut& cutDef4,
+ TDEAccelAction* insert( const TQString& sAction, const TQString& sLabel, const TQString& sWhatsThis,
+ const TDEShortcut& cutDef3, const TDEShortcut& cutDef4,
const TQObject* pObjSlot, const char* psMethodSlot,
bool bConfigurable = true, bool bEnabled = true );
@@ -108,9 +108,9 @@ class TDECORE_EXPORT TDEGlobalAccel : public TQObject
* displayed when the user configures shortcuts.
* @param sName of the of the action to insert
* @param sLabel a user-readable (i18n!) name for the action
- * @return the KAccelAction of the action
+ * @return the TDEAccelAction of the action
*/
- KAccelAction* insert( const TQString& sName, const TQString& sLabel );
+ TDEAccelAction* insert( const TQString& sName, const TQString& sLabel );
/**
* Updates the connections of the accelerations after changing them.
@@ -123,14 +123,14 @@ class TDECORE_EXPORT TDEGlobalAccel : public TQObject
* @param sAction the name of the action
* @return the shortcut. If the action does not exist a null shortcut will be returned.
*/
- const KShortcut& shortcut( const TQString& sAction ) const;
+ const TDEShortcut& shortcut( const TQString& sAction ) const;
/**
* Set the shortcut to be associated with the action named by @p sAction.
* @param sAction the name of the action
* @param shortcut the shortcut for the action
* @return true if successful, false otherwise
*/
- bool setShortcut( const TQString& sAction, const KShortcut &shortcut );
+ bool setShortcut( const TQString& sAction, const TDEShortcut &shortcut );
/**
* Set the slot to be called when the shortcut of the action named
* by @p sAction is pressed.
@@ -203,7 +203,7 @@ class TDECORE_EXPORT TDEGlobalAccel : public TQObject
/**
* @internal -- this a wrapper function to
- * KAccelActions::useFourModifierKeys().
+ * TDEAccelActions::useFourModifierKeys().
*/
static bool useFourModifierKeys();
@@ -224,11 +224,11 @@ class TDECORE_EXPORT TDEGlobalAccel : public TQObject
private:
- KAccelActions& actions();
- const KAccelActions& actions() const;
+ TDEAccelActions& actions();
+ const TDEAccelActions& actions() const;
friend class TDEGlobalAccelPrivate;
- friend class KAccelShortcutList;
+ friend class TDEAccelShortcutList;
protected:
/** \internal */
virtual void virtual_hook( int id, void* data );
diff --git a/tdecore/kglobalaccel_emb.h b/tdecore/kglobalaccel_emb.h
index 8a5352817..e4feb601e 100644
--- a/tdecore/kglobalaccel_emb.h
+++ b/tdecore/kglobalaccel_emb.h
@@ -11,8 +11,8 @@ public:
virtual void setEnabled( bool bEnabled );
- virtual bool connectKey( KAccelAction&, KKeySequence );
- virtual bool disconnectKey( KAccelAction&, KKeySequence );
+ virtual bool connectKey( TDEAccelAction&, KKeySequence );
+ virtual bool disconnectKey( TDEAccelAction&, KKeySequence );
};
#endif // _KGLOBALACCEL_EMB_H
diff --git a/tdecore/kglobalaccel_mac.h b/tdecore/kglobalaccel_mac.h
index c82bdc17a..82fe332b4 100644
--- a/tdecore/kglobalaccel_mac.h
+++ b/tdecore/kglobalaccel_mac.h
@@ -6,11 +6,11 @@
#include "kshortcut.h"
#include "kaccelbase.h"
-class TDEGlobalAccelPrivate: public KAccelBase
+class TDEGlobalAccelPrivate: public TDEAccelBase
{
public:
TDEGlobalAccelPrivate()
- : KAccelBase(KAccelBase::NATIVE_KEYS)
+ : TDEAccelBase(TDEAccelBase::NATIVE_KEYS)
{}
// reimplemented pure virtuals
@@ -18,11 +18,11 @@ public:
{ Q_UNUSED(bEnabled); }
bool emitSignal( Signal signal )
{ Q_UNUSED(signal); return false; }
- bool connectKey( KAccelAction& action, const KKeyServer::Key& key)
+ bool connectKey( TDEAccelAction& action, const KKeyServer::Key& key)
{ Q_UNUSED(action); Q_UNUSED(key); return false; }
bool connectKey( const KKeyServer::Key& key)
{ Q_UNUSED(key); return false; }
- bool disconnectKey( KAccelAction&, const KKeyServer::Key& key)
+ bool disconnectKey( TDEAccelAction&, const KKeyServer::Key& key)
{ Q_UNUSED(key); return false; }
bool disconnectKey( const KKeyServer::Key& )
{ return false; }
diff --git a/tdecore/kglobalaccel_win.cpp b/tdecore/kglobalaccel_win.cpp
index 1ea3f0250..0393bdd8d 100644
--- a/tdecore/kglobalaccel_win.cpp
+++ b/tdecore/kglobalaccel_win.cpp
@@ -40,7 +40,7 @@
static TQValueList< TDEGlobalAccelPrivate* >* all_accels = 0;
TDEGlobalAccelPrivate::TDEGlobalAccelPrivate()
-: KAccelBase( KAccelBase::NATIVE_KEYS )
+: TDEAccelBase( TDEAccelBase::NATIVE_KEYS )
, m_blocked( false )
, m_blockingDisabled( false )
{
@@ -91,7 +91,7 @@ void TDEGlobalAccelPrivate::disableBlocking( bool block )
bool TDEGlobalAccelPrivate::isEnabledInternal() const
{
- return KAccelBase::isEnabled() && !m_blocked;
+ return TDEAccelBase::isEnabled() && !m_blocked;
}
bool TDEGlobalAccelPrivate::emitSignal( Signal )
@@ -99,16 +99,16 @@ bool TDEGlobalAccelPrivate::emitSignal( Signal )
return false;
}
-bool TDEGlobalAccelPrivate::connectKey( KAccelAction& action, const KKeyServer::Key& key )
+bool TDEGlobalAccelPrivate::connectKey( TDEAccelAction& action, const KKeyServer::Key& key )
{ return grabKey( key, true, &action ); }
bool TDEGlobalAccelPrivate::connectKey( const KKeyServer::Key& key )
{ return grabKey( key, true, 0 ); }
-bool TDEGlobalAccelPrivate::disconnectKey( KAccelAction& action, const KKeyServer::Key& key )
+bool TDEGlobalAccelPrivate::disconnectKey( TDEAccelAction& action, const KKeyServer::Key& key )
{ return grabKey( key, false, &action ); }
bool TDEGlobalAccelPrivate::disconnectKey( const KKeyServer::Key& key )
{ return grabKey( key, false, 0 ); }
-bool TDEGlobalAccelPrivate::grabKey( const KKeyServer::Key& key, bool bGrab, KAccelAction* pAction )
+bool TDEGlobalAccelPrivate::grabKey( const KKeyServer::Key& key, bool bGrab, TDEAccelAction* pAction )
{
/*
if( !key.code() ) {
@@ -268,7 +268,7 @@ bool TDEGlobalAccelPrivate::x11KeyPress( const XEvent *pEvent )
if( !m_rgCodeModToAction.contains( codemod ) ) {
#ifndef NDEBUG
for( CodeModMap::ConstIterator it = m_rgCodeModToAction.begin(); it != m_rgCodeModToAction.end(); ++it ) {
- KAccelAction* pAction = *it;
+ TDEAccelAction* pAction = *it;
kdDebug(125) << "\tcode: " << TQString::number(it.key().code, 16) << " mod: " << TQString::number(it.key().mod, 16)
<< (pAction ? TQString(" name: \"%1\" shortcut: %2").arg(pAction->name()).arg(pAction->shortcut().toStringInternal()) : TQString::null)
<< endl;
@@ -276,7 +276,7 @@ bool TDEGlobalAccelPrivate::x11KeyPress( const XEvent *pEvent )
#endif
return false;
}
- KAccelAction* pAction = m_rgCodeModToAction[codemod];
+ TDEAccelAction* pAction = m_rgCodeModToAction[codemod];
if( !pAction ) {
static bool recursion_block = false;
@@ -297,7 +297,7 @@ bool TDEGlobalAccelPrivate::x11KeyPress( const XEvent *pEvent )
return true;
}*/
-void TDEGlobalAccelPrivate::activate( KAccelAction* pAction, const KKeySequence& seq )
+void TDEGlobalAccelPrivate::activate( TDEAccelAction* pAction, const KKeySequence& seq )
{
kdDebug(125) << "TDEGlobalAccelPrivate::activate( \"" << pAction->name() << "\" ) " << endl;
@@ -335,7 +335,7 @@ void TDEGlobalAccelPrivate::activate( KAccelAction* pAction, const KKeySequence&
void TDEGlobalAccelPrivate::slotActivated( int iAction )
{
- KAccelAction* pAction = actions().actionPtr( iAction );
+ TDEAccelAction* pAction = actions().actionPtr( iAction );
if( pAction )
activate( pAction, KKeySequence() );
}
diff --git a/tdecore/kglobalaccel_win.h b/tdecore/kglobalaccel_win.h
index cde46c472..0a938cbfc 100644
--- a/tdecore/kglobalaccel_win.h
+++ b/tdecore/kglobalaccel_win.h
@@ -30,7 +30,7 @@
/**
* @internal
*/
-class TDEGlobalAccelPrivate : public TQWidget, public KAccelBase
+class TDEGlobalAccelPrivate : public TQWidget, public TDEAccelBase
{
friend class TDEGlobalAccel;
Q_OBJECT
@@ -41,9 +41,9 @@ class TDEGlobalAccelPrivate : public TQWidget, public KAccelBase
virtual void setEnabled( bool bEnabled );
virtual bool emitSignal( Signal signal );
- virtual bool connectKey( KAccelAction& action, const KKeyServer::Key& key );
+ virtual bool connectKey( TDEAccelAction& action, const KKeyServer::Key& key );
virtual bool connectKey( const KKeyServer::Key& key );
- virtual bool disconnectKey( KAccelAction& action, const KKeyServer::Key& key );
+ virtual bool disconnectKey( TDEAccelAction& action, const KKeyServer::Key& key );
virtual bool disconnectKey( const KKeyServer::Key& key );
protected:
@@ -51,7 +51,7 @@ class TDEGlobalAccelPrivate : public TQWidget, public KAccelBase
/**
* @param bGrab Set to true to grab key, false to ungrab key.
*/
- bool grabKey( const KKeyServer::Key&, bool bGrab, KAccelAction* );
+ bool grabKey( const KKeyServer::Key&, bool bGrab, TDEAccelAction* );
/**
* Filters X11 events ev for key bindings in the accelerator dictionary.
@@ -63,7 +63,7 @@ class TDEGlobalAccelPrivate : public TQWidget, public KAccelBase
// virtual bool x11Event( XEvent* );
// void x11MappingNotify();
// bool x11KeyPress( const XEvent *pEvent );
- void activate( KAccelAction* pAction, const KKeySequence& seq );
+ void activate( TDEAccelAction* pAction, const KKeySequence& seq );
virtual bool isEnabledInternal() const;
static void blockShortcuts( bool block );
void disableBlocking( bool disable );
diff --git a/tdecore/kglobalaccel_x11.cpp b/tdecore/kglobalaccel_x11.cpp
index 701c954f3..64af90572 100644
--- a/tdecore/kglobalaccel_x11.cpp
+++ b/tdecore/kglobalaccel_x11.cpp
@@ -80,7 +80,7 @@ static void calculateGrabMasks()
static TQValueList< TDEGlobalAccelPrivate* >* all_accels = 0;
TDEGlobalAccelPrivate::TDEGlobalAccelPrivate()
-: KAccelBase( KAccelBase::NATIVE_KEYS )
+: TDEAccelBase( TDEAccelBase::NATIVE_KEYS )
, m_blocked( false )
, m_blockingDisabled( false )
, m_suspended( false )
@@ -133,7 +133,7 @@ void TDEGlobalAccelPrivate::disableBlocking( bool block )
bool TDEGlobalAccelPrivate::isEnabledInternal() const
{
- return KAccelBase::isEnabled() && !m_blocked;
+ return TDEAccelBase::isEnabled() && !m_blocked;
}
// see #117169 - the bug is hard to reproduce, probably somewhere in X, testcase would be probably
@@ -148,16 +148,16 @@ bool TDEGlobalAccelPrivate::emitSignal( Signal )
return false;
}
-bool TDEGlobalAccelPrivate::connectKey( KAccelAction& action, const KKeyServer::Key& key )
+bool TDEGlobalAccelPrivate::connectKey( TDEAccelAction& action, const KKeyServer::Key& key )
{ return grabKey( key, true, &action ); }
bool TDEGlobalAccelPrivate::connectKey( const KKeyServer::Key& key )
{ return grabKey( key, true, 0 ); }
-bool TDEGlobalAccelPrivate::disconnectKey( KAccelAction& action, const KKeyServer::Key& key )
+bool TDEGlobalAccelPrivate::disconnectKey( TDEAccelAction& action, const KKeyServer::Key& key )
{ return grabKey( key, false, &action ); }
bool TDEGlobalAccelPrivate::disconnectKey( const KKeyServer::Key& key )
{ return grabKey( key, false, 0 ); }
-bool TDEGlobalAccelPrivate::grabKey( const KKeyServer::Key& key, bool bGrab, KAccelAction* pAction )
+bool TDEGlobalAccelPrivate::grabKey( const KKeyServer::Key& key, bool bGrab, TDEAccelAction* pAction )
{
if( !key.code() ) {
kdWarning(125) << "TDEGlobalAccelPrivate::grabKey( " << key.key().toStringInternal() << ", " << bGrab << ", \"" << (pAction ? pAction->name().latin1() : "(null)") << "\" ): Tried to grab key with null code." << endl;
@@ -286,7 +286,7 @@ void TDEGlobalAccelPrivate::fakeKeyPressed(unsigned int keyCode) {
if( !m_rgCodeModToAction.contains( codemod ) ) {
#ifndef NDEBUG
for( CodeModMap::ConstIterator it = m_rgCodeModToAction.begin(); it != m_rgCodeModToAction.end(); ++it ) {
- KAccelAction* pAction = *it;
+ TDEAccelAction* pAction = *it;
kdDebug(125) << "\tcode: " << TQString::number(it.key().code, 16) << " mod: " << TQString::number(it.key().mod, 16)
<< (pAction ? TQString(" name: \"%1\" shortcut: %2").arg(pAction->name()).arg(pAction->shortcut().toStringInternal()) : TQString())
<< endl;
@@ -295,7 +295,7 @@ void TDEGlobalAccelPrivate::fakeKeyPressed(unsigned int keyCode) {
return;
}
- KAccelAction* pAction = m_rgCodeModToAction[codemod];
+ TDEAccelAction* pAction = m_rgCodeModToAction[codemod];
if( !pAction ) {
static bool recursion_block = false;
@@ -364,7 +364,7 @@ bool TDEGlobalAccelPrivate::x11KeyPress( const XEvent *pEvent )
if( !m_rgCodeModToAction.contains( codemod ) ) {
#ifndef NDEBUG
for( CodeModMap::ConstIterator it = m_rgCodeModToAction.begin(); it != m_rgCodeModToAction.end(); ++it ) {
- KAccelAction* pAction = *it;
+ TDEAccelAction* pAction = *it;
kdDebug(125) << "\tcode: " << TQString::number(it.key().code, 16) << " mod: " << TQString::number(it.key().mod, 16)
<< (pAction ? TQString(" name: \"%1\" shortcut: %2").arg(pAction->name()).arg(pAction->shortcut().toStringInternal()) : TQString())
<< endl;
@@ -373,7 +373,7 @@ bool TDEGlobalAccelPrivate::x11KeyPress( const XEvent *pEvent )
return false;
}
- KAccelAction* pAction = m_rgCodeModToAction[codemod];
+ TDEAccelAction* pAction = m_rgCodeModToAction[codemod];
if( !pAction ) {
static bool recursion_block = false;
@@ -394,7 +394,7 @@ bool TDEGlobalAccelPrivate::x11KeyPress( const XEvent *pEvent )
return true;
}
-void TDEGlobalAccelPrivate::activate( KAccelAction* pAction, const KKeySequence& seq )
+void TDEGlobalAccelPrivate::activate( TDEAccelAction* pAction, const KKeySequence& seq )
{
kdDebug(125) << "TDEGlobalAccelPrivate::activate( \"" << pAction->name() << "\" ) " << endl;
@@ -432,7 +432,7 @@ void TDEGlobalAccelPrivate::activate( KAccelAction* pAction, const KKeySequence&
void TDEGlobalAccelPrivate::slotActivated( int iAction )
{
- KAccelAction* pAction = KAccelBase::actions().actionPtr( iAction );
+ TDEAccelAction* pAction = TDEAccelBase::actions().actionPtr( iAction );
if( pAction )
activate( pAction, KKeySequence() );
}
diff --git a/tdecore/kglobalaccel_x11.h b/tdecore/kglobalaccel_x11.h
index e28df060d..df1f54425 100644
--- a/tdecore/kglobalaccel_x11.h
+++ b/tdecore/kglobalaccel_x11.h
@@ -30,7 +30,7 @@
/**
* @internal
*/
-class TDEGlobalAccelPrivate : public TQWidget, public KAccelBase
+class TDEGlobalAccelPrivate : public TQWidget, public TDEAccelBase
{
friend class TDEGlobalAccel;
Q_OBJECT
@@ -41,9 +41,9 @@ class TDEGlobalAccelPrivate : public TQWidget, public KAccelBase
virtual void setEnabled( bool bEnabled );
virtual bool emitSignal( Signal signal );
- virtual bool connectKey( KAccelAction& action, const KKeyServer::Key& key );
+ virtual bool connectKey( TDEAccelAction& action, const KKeyServer::Key& key );
virtual bool connectKey( const KKeyServer::Key& key );
- virtual bool disconnectKey( KAccelAction& action, const KKeyServer::Key& key );
+ virtual bool disconnectKey( TDEAccelAction& action, const KKeyServer::Key& key );
virtual bool disconnectKey( const KKeyServer::Key& key );
protected:
@@ -73,14 +73,14 @@ class TDEGlobalAccelPrivate : public TQWidget, public KAccelBase
return false;
}
};
- typedef TQMap<CodeMod, KAccelAction*> CodeModMap;
+ typedef TQMap<CodeMod, TDEAccelAction*> CodeModMap;
CodeModMap m_rgCodeModToAction;
/**
* @param bGrab Set to true to grab key, false to ungrab key.
*/
- bool grabKey( const KKeyServer::Key&, bool bGrab, KAccelAction* );
+ bool grabKey( const KKeyServer::Key&, bool bGrab, TDEAccelAction* );
/**
* Filters X11 events ev for key bindings in the accelerator dictionary.
@@ -92,7 +92,7 @@ class TDEGlobalAccelPrivate : public TQWidget, public KAccelBase
virtual bool x11Event( XEvent* );
void x11MappingNotify();
bool x11KeyPress( const XEvent *pEvent );
- void activate( KAccelAction* pAction, const KKeySequence& seq );
+ void activate( TDEAccelAction* pAction, const KKeySequence& seq );
virtual bool isEnabledInternal() const;
static void blockShortcuts( bool block );
void disableBlocking( bool disable );
diff --git a/tdecore/kglobalsettings.cpp b/tdecore/kglobalsettings.cpp
index 58eeff416..f9774a886 100644
--- a/tdecore/kglobalsettings.cpp
+++ b/tdecore/kglobalsettings.cpp
@@ -186,7 +186,7 @@ bool TDEGlobalSettings::showContextMenusOnPress ()
int TDEGlobalSettings::contextMenuKey ()
{
TDEConfigGroup g(TDEGlobal::config(), "Shortcuts");
- KShortcut cut (g.readEntry ("PopupMenuContext", "Menu"));
+ TDEShortcut cut (g.readEntry ("PopupMenuContext", "Menu"));
return cut.keyCodeQt();
}
diff --git a/tdecore/kglobalsettings.h b/tdecore/kglobalsettings.h
index 7a9c42900..ee893f97e 100644
--- a/tdecore/kglobalsettings.h
+++ b/tdecore/kglobalsettings.h
@@ -111,7 +111,7 @@ class TDECORE_EXPORT TDEGlobalSettings
/**
* This enum describes the return type for insertTearOffHandle() whether to insert
* a handle or not. Applications who independently want to use handles in their popup menus
- * should test for Application level before calling the appropriate function in KPopupMenu.
+ * should test for Application level before calling the appropriate function in TDEPopupMenu.
* @since 3.1
**/
enum TearOffHandle {
@@ -121,8 +121,8 @@ class TDECORE_EXPORT TDEGlobalSettings
};
/**
- * Returns whether tear-off handles are inserted in KPopupMenus.
- * @return whether tear-off handles are inserted in KPopupMenus.
+ * Returns whether tear-off handles are inserted in TDEPopupMenus.
+ * @return whether tear-off handles are inserted in TDEPopupMenus.
* @since 3.1
**/
static TearOffHandle insertTearOffHandle();
@@ -346,8 +346,8 @@ class TDECORE_EXPORT TDEGlobalSettings
static TQColor highlightColor();
/**
- * Returns the alternate background color used by KListView with
- * KListViewItem. Any other list that uses alternating background
+ * Returns the alternate background color used by TDEListView with
+ * TDEListViewItem. Any other list that uses alternating background
* colors should use this too, to obey to the user's preferences. Returns
* an invalid color if the user doesn't want alternating backgrounds.
* @return the alternate background color
@@ -365,7 +365,7 @@ class TDECORE_EXPORT TDEGlobalSettings
static TQColor calculateAlternateBackgroundColor(const TQColor& base);
/**
- * Returns if the sorted column in a KListView shall be drawn with a
+ * Returns if the sorted column in a TDEListView shall be drawn with a
* shaded background color.
* @return true if the sorted column shall be shaded
* @since 3.4
diff --git a/tdecore/kmanagerselection.cpp b/tdecore/kmanagerselection.cpp
index 75dde5c9c..15e273d6d 100644
--- a/tdecore/kmanagerselection.cpp
+++ b/tdecore/kmanagerselection.cpp
@@ -51,57 +51,57 @@ DEALINGS IN THE SOFTWARE.
#include <kxerrorhandler.h>
#include <X11/Xatom.h>
-class KSelectionOwnerPrivate
+class TDESelectionOwnerPrivate
: public QWidget
{
public:
- KSelectionOwnerPrivate( KSelectionOwner* owner );
+ TDESelectionOwnerPrivate( TDESelectionOwner* owner );
protected:
virtual bool x11Event( XEvent* ev );
private:
- KSelectionOwner* owner;
+ TDESelectionOwner* owner;
};
-KSelectionOwnerPrivate::KSelectionOwnerPrivate( KSelectionOwner* owner_P )
+TDESelectionOwnerPrivate::TDESelectionOwnerPrivate( TDESelectionOwner* owner_P )
: owner( owner_P )
{
kapp->installX11EventFilter( TQT_TQWIDGET(this) );
}
-bool KSelectionOwnerPrivate::x11Event( XEvent* ev_P )
+bool TDESelectionOwnerPrivate::x11Event( XEvent* ev_P )
{
return owner->filterEvent( ev_P );
}
-KSelectionOwner::KSelectionOwner( Atom selection_P, int screen_P, TQObject* parent_P )
+TDESelectionOwner::TDESelectionOwner( Atom selection_P, int screen_P, TQObject* parent_P )
: TQObject( parent_P ),
selection( selection_P ),
screen( screen_P >= 0 ? screen_P : DefaultScreen( tqt_xdisplay())),
window( None ),
timestamp( CurrentTime ),
extra1( 0 ), extra2( 0 ),
- d( new KSelectionOwnerPrivate( this ))
+ d( new TDESelectionOwnerPrivate( this ))
{
}
-KSelectionOwner::KSelectionOwner( const char* selection_P, int screen_P, TQObject* parent_P )
+TDESelectionOwner::TDESelectionOwner( const char* selection_P, int screen_P, TQObject* parent_P )
: TQObject( parent_P ),
selection( XInternAtom( tqt_xdisplay(), selection_P, False )),
screen( screen_P >= 0 ? screen_P : DefaultScreen( tqt_xdisplay())),
window( None ),
timestamp( CurrentTime ),
extra1( 0 ), extra2( 0 ),
- d( new KSelectionOwnerPrivate( this ))
+ d( new TDESelectionOwnerPrivate( this ))
{
}
-KSelectionOwner::~KSelectionOwner()
+TDESelectionOwner::~TDESelectionOwner()
{
release();
delete d;
}
-bool KSelectionOwner::claim( bool force_P, bool force_kill_P )
+bool TDESelectionOwner::claim( bool force_P, bool force_kill_P )
{
if( manager_atom == None )
getAtoms();
@@ -179,7 +179,7 @@ bool KSelectionOwner::claim( bool force_P, bool force_kill_P )
}
// destroy resource first
-void KSelectionOwner::release()
+void TDESelectionOwner::release()
{
if( timestamp == CurrentTime )
return;
@@ -188,20 +188,20 @@ void KSelectionOwner::release()
timestamp = CurrentTime;
}
-Window KSelectionOwner::ownerWindow() const
+Window TDESelectionOwner::ownerWindow() const
{
if( timestamp == CurrentTime )
return None;
return window;
}
-void KSelectionOwner::setData( long extra1_P, long extra2_P )
+void TDESelectionOwner::setData( long extra1_P, long extra2_P )
{
extra1 = extra1_P;
extra2 = extra2_P;
}
-bool KSelectionOwner::filterEvent( XEvent* ev_P )
+bool TDESelectionOwner::filterEvent( XEvent* ev_P )
{
if( timestamp != CurrentTime && ev_P->xany.window == window )
{
@@ -244,12 +244,12 @@ bool KSelectionOwner::filterEvent( XEvent* ev_P )
return false;
}
-bool KSelectionOwner::handleMessage( XEvent* )
+bool TDESelectionOwner::handleMessage( XEvent* )
{
return false;
}
-void KSelectionOwner::filter_selection_request( XSelectionRequestEvent& ev_P )
+void TDESelectionOwner::filter_selection_request( XSelectionRequestEvent& ev_P )
{
if( timestamp == CurrentTime || ev_P.selection != selection )
return;
@@ -311,7 +311,7 @@ void KSelectionOwner::filter_selection_request( XSelectionRequestEvent& ev_P )
XSendEvent( tqt_xdisplay(), ev_P.requestor, False, 0, &ev );
}
-bool KSelectionOwner::handle_selection( Atom target_P, Atom property_P, Window requestor_P )
+bool TDESelectionOwner::handle_selection( Atom target_P, Atom property_P, Window requestor_P )
{
if( target_P == xa_timestamp )
{
@@ -328,7 +328,7 @@ bool KSelectionOwner::handle_selection( Atom target_P, Atom property_P, Window r
return true;
}
-void KSelectionOwner::replyTargets( Atom property_P, Window requestor_P )
+void TDESelectionOwner::replyTargets( Atom property_P, Window requestor_P )
{
Atom atoms[ 3 ] = { xa_multiple, xa_timestamp, xa_targets };
// kdDebug() << "Handling targets request" << endl;
@@ -336,12 +336,12 @@ void KSelectionOwner::replyTargets( Atom property_P, Window requestor_P )
reinterpret_cast< unsigned char* >( atoms ), 3 );
}
-bool KSelectionOwner::genericReply( Atom, Atom, Window )
+bool TDESelectionOwner::genericReply( Atom, Atom, Window )
{
return false;
}
-void KSelectionOwner::getAtoms()
+void TDESelectionOwner::getAtoms()
{
if( manager_atom == None )
{
@@ -356,66 +356,66 @@ void KSelectionOwner::getAtoms()
}
}
-Atom KSelectionOwner::manager_atom = None;
-Atom KSelectionOwner::xa_multiple = None;
-Atom KSelectionOwner::xa_targets = None;
-Atom KSelectionOwner::xa_timestamp = None;
+Atom TDESelectionOwner::manager_atom = None;
+Atom TDESelectionOwner::xa_multiple = None;
+Atom TDESelectionOwner::xa_targets = None;
+Atom TDESelectionOwner::xa_timestamp = None;
//*******************************************
-// KSelectionWatcher
+// TDESelectionWatcher
//*******************************************
-class KSelectionWatcherPrivate
+class TDESelectionWatcherPrivate
: public QWidget
{
public:
- KSelectionWatcherPrivate( KSelectionWatcher* watcher );
+ TDESelectionWatcherPrivate( TDESelectionWatcher* watcher );
protected:
virtual bool x11Event( XEvent* ev );
private:
- KSelectionWatcher* watcher;
+ TDESelectionWatcher* watcher;
};
-KSelectionWatcherPrivate::KSelectionWatcherPrivate( KSelectionWatcher* watcher_P )
+TDESelectionWatcherPrivate::TDESelectionWatcherPrivate( TDESelectionWatcher* watcher_P )
: watcher( watcher_P )
{
kapp->installX11EventFilter( TQT_TQWIDGET(this) );
}
-bool KSelectionWatcherPrivate::x11Event( XEvent* ev_P )
+bool TDESelectionWatcherPrivate::x11Event( XEvent* ev_P )
{
watcher->filterEvent( ev_P );
return false;
}
-KSelectionWatcher::KSelectionWatcher( Atom selection_P, int screen_P, TQObject* parent_P )
+TDESelectionWatcher::TDESelectionWatcher( Atom selection_P, int screen_P, TQObject* parent_P )
: TQObject( parent_P ),
selection( selection_P ),
screen( screen_P >= 0 ? screen_P : DefaultScreen( tqt_xdisplay())),
selection_owner( None ),
- d( new KSelectionWatcherPrivate( this ))
+ d( new TDESelectionWatcherPrivate( this ))
{
init();
}
-KSelectionWatcher::KSelectionWatcher( const char* selection_P, int screen_P, TQObject* parent_P )
+TDESelectionWatcher::TDESelectionWatcher( const char* selection_P, int screen_P, TQObject* parent_P )
: TQObject( parent_P ),
selection( XInternAtom( tqt_xdisplay(), selection_P, False )),
screen( screen_P >= 0 ? screen_P : DefaultScreen( tqt_xdisplay())),
selection_owner( None ),
- d( new KSelectionWatcherPrivate( this ))
+ d( new TDESelectionWatcherPrivate( this ))
{
init();
}
-KSelectionWatcher::~KSelectionWatcher()
+TDESelectionWatcher::~TDESelectionWatcher()
{
delete d;
}
-void KSelectionWatcher::init()
+void TDESelectionWatcher::init()
{
if( manager_atom == None )
{
@@ -429,7 +429,7 @@ void KSelectionWatcher::init()
}
}
-Window KSelectionWatcher::owner()
+Window TDESelectionWatcher::owner()
{
Display* const dpy = tqt_xdisplay();
KXErrorHandler handler;
@@ -451,7 +451,7 @@ Window KSelectionWatcher::owner()
}
// void return value in order to allow more watchers in one process
-void KSelectionWatcher::filterEvent( XEvent* ev_P )
+void TDESelectionWatcher::filterEvent( XEvent* ev_P )
{
if( ev_P->type == ClientMessage )
{
@@ -478,12 +478,12 @@ void KSelectionWatcher::filterEvent( XEvent* ev_P )
return;
}
-Atom KSelectionWatcher::manager_atom = None;
+Atom TDESelectionWatcher::manager_atom = None;
-void KSelectionOwner::virtual_hook( int, void* )
+void TDESelectionOwner::virtual_hook( int, void* )
{ /*BASE::virtual_hook( id, data );*/ }
-void KSelectionWatcher::virtual_hook( int, void* )
+void TDESelectionWatcher::virtual_hook( int, void* )
{ /*BASE::virtual_hook( id, data );*/ }
#include "kmanagerselection.moc"
diff --git a/tdecore/kmanagerselection.h b/tdecore/kmanagerselection.h
index 5b46488ab..de294187d 100644
--- a/tdecore/kmanagerselection.h
+++ b/tdecore/kmanagerselection.h
@@ -36,7 +36,7 @@ DEALINGS IN THE SOFTWARE.
#include <X11/Xlib.h>
-class KSelectionOwnerPrivate;
+class TDESelectionOwnerPrivate;
/**
This class implements claiming and owning manager selections, as described
@@ -47,7 +47,7 @@ class KSelectionOwnerPrivate;
@since 3.2
@short ICCCM manager selection owner
*/
-class TDECORE_EXPORT KSelectionOwner
+class TDECORE_EXPORT TDESelectionOwner
: public TQObject
{
Q_OBJECT
@@ -60,7 +60,7 @@ class TDECORE_EXPORT KSelectionOwner
* @param screen X screen, or -1 for default
* @param parent parent object, or NULL if there is none
*/
- KSelectionOwner( Atom selection, int screen = -1, TQObject* parent = NULL );
+ TDESelectionOwner( Atom selection, int screen = -1, TQObject* parent = NULL );
/**
* @overload
* This constructor accepts the selection name and creates the appropriate atom
@@ -70,11 +70,11 @@ class TDECORE_EXPORT KSelectionOwner
* @param screen X screen, or -1 for default
* @param parent parent object, or NULL if there is none
*/
- KSelectionOwner( const char* selection, int screen = -1, TQObject* parent = NULL );
+ TDESelectionOwner( const char* selection, int screen = -1, TQObject* parent = NULL );
/**
* Destructor. Calls release().
*/
- virtual ~KSelectionOwner();
+ virtual ~TDESelectionOwner();
/**
* This function attemps to claim ownership of the manager selection, using
* the current X timestamp. If @p force is false, and the selection is already
@@ -157,10 +157,10 @@ class TDECORE_EXPORT KSelectionOwner
protected:
virtual void virtual_hook( int id, void* data );
private:
- KSelectionOwnerPrivate* d;
+ TDESelectionOwnerPrivate* d;
};
-class KSelectionWatcherPrivate;
+class TDESelectionWatcherPrivate;
/**
This class implements watching manager selections, as described in the ICCCM
@@ -170,7 +170,7 @@ class KSelectionWatcherPrivate;
@since 3.2
@short ICCCM manager selection watching
*/
-class TDECORE_EXPORT KSelectionWatcher
+class TDECORE_EXPORT TDESelectionWatcher
: public TQObject
{
Q_OBJECT
@@ -183,7 +183,7 @@ class TDECORE_EXPORT KSelectionWatcher
* @param screen X screen, or -1 for default
* @param parent parent object, or NULL if there is none
*/
- KSelectionWatcher( Atom selection, int screen = -1, TQObject* parent = NULL );
+ TDESelectionWatcher( Atom selection, int screen = -1, TQObject* parent = NULL );
/**
* @overload
* This constructor accepts the selection name and creates the appropriate atom
@@ -193,8 +193,8 @@ class TDECORE_EXPORT KSelectionWatcher
* @param screen X screen, or -1 for default
* @param parent parent object, or NULL if there is none
*/
- KSelectionWatcher( const char* selection, int screen = -1, TQObject* parent = NULL );
- virtual ~KSelectionWatcher();
+ TDESelectionWatcher( const char* selection, int screen = -1, TQObject* parent = NULL );
+ virtual ~TDESelectionWatcher();
/**
* Return the current owner of the manager selection, if any.
*/
@@ -226,7 +226,7 @@ class TDECORE_EXPORT KSelectionWatcher
protected:
virtual void virtual_hook( int id, void* data );
private:
- KSelectionWatcherPrivate* d;
+ TDESelectionWatcherPrivate* d;
};
#endif
diff --git a/tdecore/kshortcut.cpp b/tdecore/kshortcut.cpp
index 10c6c31fa..ae568d5b7 100644
--- a/tdecore/kshortcut.cpp
+++ b/tdecore/kshortcut.cpp
@@ -33,7 +33,7 @@
static KKey* g_pspec = 0;
static KKeySequence* g_pseq = 0;
-static KShortcut* g_pcut = 0;
+static TDEShortcut* g_pcut = 0;
//----------------------------------------------------
// KKey
@@ -396,28 +396,28 @@ KKeySequence& KKeySequence::null()
}
//---------------------------------------------------------------------
-// KShortcut
+// TDEShortcut
//---------------------------------------------------------------------
-KShortcut::KShortcut() { clear(); }
-KShortcut::KShortcut( int keyQt ) { init( keyQt ); }
-KShortcut::KShortcut( const TQKeySequence& key ) { init( key ); }
-KShortcut::KShortcut( const KKey& key ) { init( key ); }
-KShortcut::KShortcut( const KKeySequence& seq ) { init( seq ); }
-KShortcut::KShortcut( const KShortcut& cut ) { init( cut ); }
-KShortcut::KShortcut( const char* ps ) { init( TQString(ps) ); }
-KShortcut::KShortcut( const TQString& s ) { init( s ); }
+TDEShortcut::TDEShortcut() { clear(); }
+TDEShortcut::TDEShortcut( int keyQt ) { init( keyQt ); }
+TDEShortcut::TDEShortcut( const TQKeySequence& key ) { init( key ); }
+TDEShortcut::TDEShortcut( const KKey& key ) { init( key ); }
+TDEShortcut::TDEShortcut( const KKeySequence& seq ) { init( seq ); }
+TDEShortcut::TDEShortcut( const TDEShortcut& cut ) { init( cut ); }
+TDEShortcut::TDEShortcut( const char* ps ) { init( TQString(ps) ); }
+TDEShortcut::TDEShortcut( const TQString& s ) { init( s ); }
-KShortcut::~KShortcut()
+TDEShortcut::~TDEShortcut()
{
}
-void KShortcut::clear()
+void TDEShortcut::clear()
{
m_nSeqs = 0;
}
-bool KShortcut::init( int keyQt )
+bool TDEShortcut::init( int keyQt )
{
if( keyQt ) {
m_nSeqs = 1;
@@ -427,28 +427,28 @@ bool KShortcut::init( int keyQt )
return true;
}
-bool KShortcut::init( const TQKeySequence& key )
+bool TDEShortcut::init( const TQKeySequence& key )
{
m_nSeqs = 1;
m_rgseq[0].init( key );
return true;
}
-bool KShortcut::init( const KKey& spec )
+bool TDEShortcut::init( const KKey& spec )
{
m_nSeqs = 1;
m_rgseq[0].init( spec );
return true;
}
-bool KShortcut::init( const KKeySequence& seq )
+bool TDEShortcut::init( const KKeySequence& seq )
{
m_nSeqs = 1;
m_rgseq[0] = seq;
return true;
}
-bool KShortcut::init( const KShortcut& cut )
+bool TDEShortcut::init( const TDEShortcut& cut )
{
m_nSeqs = cut.m_nSeqs;
for( uint i = 0; i < m_nSeqs; i++ )
@@ -456,7 +456,7 @@ bool KShortcut::init( const KShortcut& cut )
return true;
}
-bool KShortcut::init( const TQString& s )
+bool TDEShortcut::init( const TQString& s )
{
bool bRet = true;
TQStringList rgs = TQStringList::split( ';', s );
@@ -480,7 +480,7 @@ bool KShortcut::init( const TQString& s )
if( !s.isEmpty() ) {
TQString sDebug;
TQTextStream os( &sDebug, IO_WriteOnly );
- os << "KShortcut::init( \"" << s << "\" ): ";
+ os << "TDEShortcut::init( \"" << s << "\" ): ";
for( uint i = 0; i < m_nSeqs; i++ ) {
os << " m_rgseq[" << i << "]: ";
KKeyServer::Variations vars;
@@ -494,29 +494,29 @@ bool KShortcut::init( const TQString& s )
return bRet;
}
-uint KShortcut::count() const
+uint TDEShortcut::count() const
{
return m_nSeqs;
}
-const KKeySequence& KShortcut::seq( uint i ) const
+const KKeySequence& TDEShortcut::seq( uint i ) const
{
return (i < m_nSeqs) ? m_rgseq[i] : KKeySequence::null();
}
-int KShortcut::keyCodeQt() const
+int TDEShortcut::keyCodeQt() const
{
if( m_nSeqs >= 1 )
return m_rgseq[0].keyCodeQt();
return TQKeySequence();
}
-bool KShortcut::isNull() const
+bool TDEShortcut::isNull() const
{
return m_nSeqs == 0;
}
-int KShortcut::compare( const KShortcut& cut ) const
+int TDEShortcut::compare( const TDEShortcut& cut ) const
{
for( uint i = 0; i < m_nSeqs && i < cut.m_nSeqs; i++ ) {
int ret = m_rgseq[i].compare( cut.m_rgseq[i] );
@@ -526,12 +526,12 @@ int KShortcut::compare( const KShortcut& cut ) const
return m_nSeqs - cut.m_nSeqs;
}
-bool KShortcut::contains( const KKey& key ) const
+bool TDEShortcut::contains( const KKey& key ) const
{
return contains( KKeySequence(key) );
}
-bool KShortcut::contains( const KKeyNative& keyNative ) const
+bool TDEShortcut::contains( const KKeyNative& keyNative ) const
{
KKey key = keyNative.key();
key.simplify();
@@ -545,7 +545,7 @@ bool KShortcut::contains( const KKeyNative& keyNative ) const
return false;
}
-bool KShortcut::contains( const KKeySequence& seq ) const
+bool TDEShortcut::contains( const KKeySequence& seq ) const
{
for( uint i = 0; i < count(); i++ ) {
if( !m_rgseq[i].isNull() && m_rgseq[i] == seq )
@@ -554,7 +554,7 @@ bool KShortcut::contains( const KKeySequence& seq ) const
return false;
}
-bool KShortcut::setSeq( uint iSeq, const KKeySequence& seq )
+bool TDEShortcut::setSeq( uint iSeq, const KKeySequence& seq )
{
// TODO: check if seq is null, and act accordingly.
if( iSeq <= m_nSeqs && iSeq < MAX_SEQUENCES ) {
@@ -566,7 +566,7 @@ bool KShortcut::setSeq( uint iSeq, const KKeySequence& seq )
return false;
}
-void KShortcut::remove( const KKeySequence& seq )
+void TDEShortcut::remove( const KKeySequence& seq )
{
if (seq.isNull()) return;
@@ -581,7 +581,7 @@ void KShortcut::remove( const KKeySequence& seq )
}
}
-bool KShortcut::append( const KKeySequence& seq )
+bool TDEShortcut::append( const KKeySequence& seq )
{
if( m_nSeqs < MAX_SEQUENCES ) {
if( !seq.isNull() ) {
@@ -593,7 +593,7 @@ bool KShortcut::append( const KKeySequence& seq )
return false;
}
-bool KShortcut::append( const KKey& spec )
+bool TDEShortcut::append( const KKey& spec )
{
if( m_nSeqs < MAX_SEQUENCES ) {
m_rgseq[m_nSeqs].init( spec );
@@ -603,7 +603,7 @@ bool KShortcut::append( const KKey& spec )
return false;
}
-bool KShortcut::append( const KShortcut& cut )
+bool TDEShortcut::append( const TDEShortcut& cut )
{
uint seqs = m_nSeqs, co = cut.count();
for( uint i=0; i<co; i++ ) {
@@ -621,7 +621,7 @@ bool KShortcut::append( const KShortcut& cut )
return true;
}
-KShortcut::operator TQKeySequence () const
+TDEShortcut::operator TQKeySequence () const
{
if( count() >= 1 )
return m_rgseq[0].qt();
@@ -629,7 +629,7 @@ KShortcut::operator TQKeySequence () const
return TQKeySequence();
}
-TQString KShortcut::toString() const
+TQString TDEShortcut::toString() const
{
TQString s;
@@ -642,7 +642,7 @@ TQString KShortcut::toString() const
return s;
}
-TQString KShortcut::toStringInternal( const KShortcut* pcutDefault ) const
+TQString TDEShortcut::toStringInternal( const TDEShortcut* pcutDefault ) const
{
TQString s;
@@ -661,10 +661,10 @@ TQString KShortcut::toStringInternal( const KShortcut* pcutDefault ) const
return s;
}
-KShortcut& KShortcut::null()
+TDEShortcut& TDEShortcut::null()
{
if( !g_pcut )
- g_pcut = new KShortcut;
+ g_pcut = new TDEShortcut;
if( !g_pcut->isNull() )
g_pcut->clear();
return *g_pcut;
diff --git a/tdecore/kshortcut.h b/tdecore/kshortcut.h
index 9baf31b0d..e98a007b5 100644
--- a/tdecore/kshortcut.h
+++ b/tdecore/kshortcut.h
@@ -34,7 +34,7 @@ class KKeyNative;
* by the underlying system (e.g. X11).
* @see KKeyNative
* @see KKeySequence
-* @see KShortcut
+* @see TDEShortcut
*/
class TDECORE_EXPORT KKey
@@ -282,7 +282,7 @@ class TDECORE_EXPORT KKey
* A KKeySequence object holds a sequence of up to 4 keys.
* Ex: Ctrl+X,I
* @see KKey
-* @see KShortcut
+* @see TDEShortcut
*/
class TDECORE_EXPORT KKeySequence
@@ -518,18 +518,18 @@ class TDECORE_EXPORT KKeySequence
};
/**
-* The KShortcut class is used to represent a keyboard shortcut to an action.
+* The TDEShortcut class is used to represent a keyboard shortcut to an action.
* A shortcut is normally a single key with modifiers, such as Ctrl+V.
-* A KShortcut object may also contain an alternate key which will also
+* A TDEShortcut object may also contain an alternate key which will also
* activate the action it's associated to, as long as no other actions have
* defined that key as their primary key. Ex: Ctrl+V;Shift+Insert.
*
-* This can be used to add additional accelerators to a KAction. For example,
+* This can be used to add additional accelerators to a TDEAction. For example,
* the below code binds the escape key to the close action.
*
* \code
-* KAction *closeAction = KStdAction::close( this, TQT_SLOT( close() ), actionCollection() );
-* KShortcut closeShortcut = closeAction->shortcut();
+* TDEAction *closeAction = KStdAction::close( this, TQT_SLOT( close() ), actionCollection() );
+* TDEShortcut closeShortcut = closeAction->shortcut();
* closeShortcut.append( KKey(Key_Escape));
* closeAction->setShortcut(closeShortcut);
* \endcode
@@ -540,12 +540,12 @@ class TDECORE_EXPORT KKeySequence
*
*/
-class TDECORE_EXPORT KShortcut
+class TDECORE_EXPORT TDEShortcut
{
public:
/**
* The maximum number of key sequences that can be contained in
- * a KShortcut.
+ * a TDEShortcut.
*/
enum { MAX_SEQUENCES = 2 };
@@ -555,7 +555,7 @@ class TDECORE_EXPORT KShortcut
* @see isNull()
* @see clear()
*/
- KShortcut();
+ TDEShortcut();
/**
* Creates a new shortcut with the given Qt key code
@@ -563,34 +563,34 @@ class TDECORE_EXPORT KShortcut
* @param keyQt the qt keycode
* @see Qt::Key
*/
- KShortcut( int keyQt );
+ TDEShortcut( int keyQt );
/**
* Creates a new shortcut that contains only the given qt key
* sequence.
* @param keySeq the qt key sequence to add
*/
- KShortcut( const TQKeySequence& keySeq );
+ TDEShortcut( const TQKeySequence& keySeq );
/**
* Creates a new shortcut that contains only the given key
* in its only sequence.
* @param key the key to add
*/
- KShortcut( const KKey& key );
+ TDEShortcut( const KKey& key );
/**
* Creates a new shortcut that contains only the given key
* sequence.
* @param keySeq the key sequence to add
*/
- KShortcut( const KKeySequence& keySeq );
+ TDEShortcut( const KKeySequence& keySeq );
/**
* Copies the given shortcut.
* @param shortcut the shortcut to add
*/
- KShortcut( const KShortcut& shortcut );
+ TDEShortcut( const TDEShortcut& shortcut );
/**
* Creates a new key sequence that contains the given key sequence.
@@ -599,7 +599,7 @@ class TDECORE_EXPORT KShortcut
* @param shortcut the description of the key
* @see KKeySequence::KKeySequence(const TQString&)
*/
- KShortcut( const char* shortcut );
+ TDEShortcut( const char* shortcut );
/**
* Creates a new key sequence that contains the given key sequence.
@@ -608,8 +608,8 @@ class TDECORE_EXPORT KShortcut
* @param shortcut the description of the key
* @see KKeySequence::KKeySequence(const TQString&)
*/
- KShortcut( const TQString& shortcut );
- ~KShortcut();
+ TDEShortcut( const TQString& shortcut );
+ ~TDEShortcut();
/**
* Clears the shortcut. The shortcut is null after calling this
@@ -648,7 +648,7 @@ class TDECORE_EXPORT KShortcut
* Copies the given shortcut.
* @param shortcut the shortcut to add
*/
- bool init( const KShortcut& shortcut );
+ bool init( const TDEShortcut& shortcut );
/**
* Initializes the key sequence with the given key sequence.
@@ -662,7 +662,7 @@ class TDECORE_EXPORT KShortcut
/**
* Copies the given shortcut over this shortcut.
*/
- KShortcut& operator =( const KShortcut& cut )
+ TDEShortcut& operator =( const TDEShortcut& cut )
{ init( cut ); return *this; }
/**
@@ -708,32 +708,32 @@ class TDECORE_EXPORT KShortcut
* beginning until an unequal key sequences has been found. If a shortcut
* contains more key sequences, it is considered larger.
* @param shortcut the shortcut to compare to
- * @return a negative number if the given KShortcut is larger, 0 if
- * they are equal and a positive number this KShortcut is larger
+ * @return a negative number if the given TDEShortcut is larger, 0 if
+ * they are equal and a positive number this TDEShortcut is larger
* @see KKey::compare()
* @see KKeyShortcut::compare()
*/
- int compare( const KShortcut& shortcut ) const;
+ int compare( const TDEShortcut& shortcut ) const;
/**
* Compares the sequences of both shortcuts.
* @see compare()
*/
- bool operator == ( const KShortcut& cut ) const
+ bool operator == ( const TDEShortcut& cut ) const
{ return compare( cut ) == 0; }
/**
* Compares the sequences of both shortcuts.
* @see compare()
*/
- bool operator != ( const KShortcut& cut ) const
+ bool operator != ( const TDEShortcut& cut ) const
{ return compare( cut ) != 0; }
/**
* Compares the sequences of both shortcuts.
* @see compare()
*/
- bool operator < ( const KShortcut& cut ) const
+ bool operator < ( const TDEShortcut& cut ) const
{ return compare( cut ) < 0; }
/**
@@ -804,7 +804,7 @@ class TDECORE_EXPORT KShortcut
* @see MAX_SEQUENCES
* @since 3.2
*/
- bool append( const KShortcut& cut );
+ bool append( const TDEShortcut& cut );
/**
* Converts this shortcut to a key sequence. The first key sequence
@@ -824,7 +824,7 @@ class TDECORE_EXPORT KShortcut
/**
* @internal
*/
- TQString toStringInternal( const KShortcut* pcutDefault = 0 ) const;
+ TQString toStringInternal( const TDEShortcut* pcutDefault = 0 ) const;
/**
* Returns a null shortcut.
@@ -832,14 +832,14 @@ class TDECORE_EXPORT KShortcut
* @see isNull()
* @see clear()
*/
- static KShortcut& null();
+ static TDEShortcut& null();
protected:
uint m_nSeqs;
KKeySequence m_rgseq[MAX_SEQUENCES];
private:
- class KShortcutPrivate* d;
+ class TDEShortcutPrivate* d;
friend class KKeyNative;
#ifndef KDE_NO_COMPAT
diff --git a/tdecore/kshortcutlist.cpp b/tdecore/kshortcutlist.cpp
index dd171062e..d32df889d 100644
--- a/tdecore/kshortcutlist.cpp
+++ b/tdecore/kshortcutlist.cpp
@@ -12,23 +12,23 @@
#include "kshortcutlist.h"
//---------------------------------------------------------------------
-// KShortcutList
+// TDEShortcutList
//---------------------------------------------------------------------
-KShortcutList::KShortcutList()
+TDEShortcutList::TDEShortcutList()
{
}
-KShortcutList::~KShortcutList()
+TDEShortcutList::~TDEShortcutList()
{
}
-bool KShortcutList::isGlobal( uint ) const
+bool TDEShortcutList::isGlobal( uint ) const
{
return false;
}
-int KShortcutList::index( const TQString& sName ) const
+int TDEShortcutList::index( const TQString& sName ) const
{
uint nSize = count();
for( uint i = 0;
@@ -39,7 +39,7 @@ int KShortcutList::index( const TQString& sName ) const
return -1;
}
-int KShortcutList::index( const KKeySequence& seq ) const
+int TDEShortcutList::index( const KKeySequence& seq ) const
{
if( seq.isNull() )
return -1;
@@ -53,24 +53,24 @@ int KShortcutList::index( const KKeySequence& seq ) const
return -1;
}
-const TDEInstance* KShortcutList::instance() const
+const TDEInstance* TDEShortcutList::instance() const
{
return 0;
}
-TQVariant KShortcutList::getOther( Other, uint ) const
+TQVariant TDEShortcutList::getOther( Other, uint ) const
{
return TQVariant();
}
-bool KShortcutList::setOther( Other, uint, TQVariant )
+bool TDEShortcutList::setOther( Other, uint, TQVariant )
{
return false;
}
-bool KShortcutList::readSettings( const TQString& sConfigGroup, TDEConfigBase* pConfig )
+bool TDEShortcutList::readSettings( const TQString& sConfigGroup, TDEConfigBase* pConfig )
{
- kdDebug(125) << "KShortcutList::readSettings( \"" << sConfigGroup << "\", " << pConfig << " ) start" << endl;
+ kdDebug(125) << "TDEShortcutList::readSettings( \"" << sConfigGroup << "\", " << pConfig << " ) start" << endl;
if( !pConfig )
pConfig = TDEGlobal::config();
TQString sGroup = (!sConfigGroup.isEmpty()) ? sConfigGroup : TQString("Shortcuts");
@@ -92,9 +92,9 @@ bool KShortcutList::readSettings( const TQString& sConfigGroup, TDEConfigBase* p
TQString sEntry = pConfig->readEntry( name(i) );
if( !sEntry.isEmpty() ) {
if( sEntry == "none" )
- setShortcut( i, KShortcut() );
+ setShortcut( i, TDEShortcut() );
else
- setShortcut( i, KShortcut(sEntry) );
+ setShortcut( i, TDEShortcut(sEntry) );
}
else // default shortcut
setShortcut( i, shortcutDefault(i) );
@@ -102,13 +102,13 @@ bool KShortcutList::readSettings( const TQString& sConfigGroup, TDEConfigBase* p
}
}
- kdDebug(125) << "KShortcutList::readSettings done" << endl;
+ kdDebug(125) << "TDEShortcutList::readSettings done" << endl;
return true;
}
-bool KShortcutList::writeSettings( const TQString &sConfigGroup, TDEConfigBase* pConfig, bool bWriteAll, bool bGlobal ) const
+bool TDEShortcutList::writeSettings( const TQString &sConfigGroup, TDEConfigBase* pConfig, bool bWriteAll, bool bGlobal ) const
{
- kdDebug(125) << "KShortcutList::writeSettings( " << sConfigGroup << ", " << pConfig << ", " << bWriteAll << ", " << bGlobal << " )" << endl;
+ kdDebug(125) << "TDEShortcutList::writeSettings( " << sConfigGroup << ", " << pConfig << ", " << bWriteAll << ", " << bGlobal << " )" << endl;
if( !pConfig )
pConfig = TDEGlobal::config();
@@ -149,72 +149,72 @@ bool KShortcutList::writeSettings( const TQString &sConfigGroup, TDEConfigBase*
}
//---------------------------------------------------------------------
-// KAccelShortcutList
+// TDEAccelShortcutList
//---------------------------------------------------------------------
-class KAccelShortcutListPrivate
+class TDEAccelShortcutListPrivate
{
public:
TQString m_configGroup;
};
-KAccelShortcutList::KAccelShortcutList( KAccel* pAccel )
+TDEAccelShortcutList::TDEAccelShortcutList( TDEAccel* pAccel )
: m_actions( pAccel->actions() )
{
- d=new KAccelShortcutListPrivate;
+ d=new TDEAccelShortcutListPrivate;
m_bGlobal = false;
d->m_configGroup=pAccel->configGroup();
}
-KAccelShortcutList::KAccelShortcutList( TDEGlobalAccel* pAccel )
+TDEAccelShortcutList::TDEAccelShortcutList( TDEGlobalAccel* pAccel )
: m_actions( pAccel->actions() )
{
- d=new KAccelShortcutListPrivate;
+ d=new TDEAccelShortcutListPrivate;
m_bGlobal = true;
d->m_configGroup=pAccel->configGroup();
}
-KAccelShortcutList::KAccelShortcutList( KAccelActions& actions, bool bGlobal )
+TDEAccelShortcutList::TDEAccelShortcutList( TDEAccelActions& actions, bool bGlobal )
: m_actions( actions )
{
- d=new KAccelShortcutListPrivate;
+ d=new TDEAccelShortcutListPrivate;
m_bGlobal = bGlobal;
}
-KAccelShortcutList::~KAccelShortcutList()
+TDEAccelShortcutList::~TDEAccelShortcutList()
{ delete d;}
-uint KAccelShortcutList::count() const
+uint TDEAccelShortcutList::count() const
{ return m_actions.count(); }
-TQString KAccelShortcutList::name( uint i ) const
+TQString TDEAccelShortcutList::name( uint i ) const
{ return m_actions.actionPtr(i)->name(); }
-TQString KAccelShortcutList::label( uint i ) const
+TQString TDEAccelShortcutList::label( uint i ) const
{ return m_actions.actionPtr(i)->label(); }
-TQString KAccelShortcutList::whatsThis( uint i ) const
+TQString TDEAccelShortcutList::whatsThis( uint i ) const
{ return m_actions.actionPtr(i)->whatsThis(); }
-const KShortcut& KAccelShortcutList::shortcut( uint i ) const
+const TDEShortcut& TDEAccelShortcutList::shortcut( uint i ) const
{ return m_actions.actionPtr(i)->shortcut(); }
-const KShortcut& KAccelShortcutList::shortcutDefault( uint i ) const
+const TDEShortcut& TDEAccelShortcutList::shortcutDefault( uint i ) const
{ return m_actions.actionPtr(i)->shortcutDefault(); }
-bool KAccelShortcutList::isConfigurable( uint i ) const
+bool TDEAccelShortcutList::isConfigurable( uint i ) const
{ return m_actions.actionPtr(i)->isConfigurable(); }
-bool KAccelShortcutList::setShortcut( uint i, const KShortcut& cut )
+bool TDEAccelShortcutList::setShortcut( uint i, const TDEShortcut& cut )
{ return m_actions.actionPtr(i)->setShortcut( cut ); }
-TQVariant KAccelShortcutList::getOther( Other, uint ) const
+TQVariant TDEAccelShortcutList::getOther( Other, uint ) const
{ return TQVariant(); }
-bool KAccelShortcutList::isGlobal( uint ) const
+bool TDEAccelShortcutList::isGlobal( uint ) const
{ return m_bGlobal; }
-bool KAccelShortcutList::setOther( Other, uint, TQVariant )
+bool TDEAccelShortcutList::setOther( Other, uint, TQVariant )
{ return false; }
-bool KAccelShortcutList::save() const
+bool TDEAccelShortcutList::save() const
{ return writeSettings( d->m_configGroup ); }
-void KShortcutList::virtual_hook( int, void* )
+void TDEShortcutList::virtual_hook( int, void* )
{ /*BASE::virtual_hook( id, data );*/ }
-void KAccelShortcutList::virtual_hook( int id, void* data )
-{ KShortcutList::virtual_hook( id, data ); }
+void TDEAccelShortcutList::virtual_hook( int id, void* data )
+{ TDEShortcutList::virtual_hook( id, data ); }
-void KStdAccel::ShortcutList::virtual_hook( int id, void* data )
-{ KShortcutList::virtual_hook( id, data ); }
+void TDEStdAccel::ShortcutList::virtual_hook( int id, void* data )
+{ TDEShortcutList::virtual_hook( id, data ); }
diff --git a/tdecore/kshortcutlist.h b/tdecore/kshortcutlist.h
index 7f4caa079..99e83766b 100644
--- a/tdecore/kshortcutlist.h
+++ b/tdecore/kshortcutlist.h
@@ -28,31 +28,31 @@ class TQVariant;
class TDEConfigBase;
class TDEInstance;
class KKeySequence;
-class KShortcut;
+class TDEShortcut;
/**********************************************************************
* This is a wrapper class which allows a function to use one interface
-* to KActionCollection, KAccelActions, and KActionPtrList.
+* to TDEActionCollection, TDEAccelActions, and TDEActionPtrList.
**********************************************************************/
/**
- * KShortcutList is an abstract base class for
- * KAccelShortcutList and KStdAccel::ShortcutList. It gives
+ * TDEShortcutList is an abstract base class for
+ * TDEAccelShortcutList and TDEStdAccel::ShortcutList. It gives
* you an unified interface for accessing the accelerator lists
- * of KAccel (using KAccelShortcutList),
- * TDEGlobalAccel (using KAccelShortcutList), and
- * KStdAccel (using KStdAccel::ShortcutList).
+ * of TDEAccel (using TDEAccelShortcutList),
+ * TDEGlobalAccel (using TDEAccelShortcutList), and
+ * TDEStdAccel (using TDEStdAccel::ShortcutList).
*
* @short Base class for accessing accelerator lists
*/
-class TDECORE_EXPORT KShortcutList
+class TDECORE_EXPORT TDEShortcutList
{
public:
/**
* Default constructor.
*/
- KShortcutList();
- virtual ~KShortcutList();
+ TDEShortcutList();
+ virtual ~TDEShortcutList();
/**
* Returns the number of entries.
@@ -90,7 +90,7 @@ class TDECORE_EXPORT KShortcutList
* @return the shortcut
* @see shortcutDefault()
*/
- virtual const KShortcut& shortcut( uint index ) const = 0;
+ virtual const TDEShortcut& shortcut( uint index ) const = 0;
/**
* Returns default shortcut with the given @p index.
@@ -98,7 +98,7 @@ class TDECORE_EXPORT KShortcutList
* @return the default shortcut
* @see shortcut()
*/
- virtual const KShortcut& shortcutDefault( uint index ) const = 0;
+ virtual const TDEShortcut& shortcutDefault( uint index ) const = 0;
/**
* Checks whether the shortcut with the given @p index is configurable.
@@ -112,7 +112,7 @@ class TDECORE_EXPORT KShortcutList
* @param index the index of the shortcut (must be < count())
* @param shortcut the shortcut
*/
- virtual bool setShortcut( uint index, const KShortcut &shortcut ) = 0;
+ virtual bool setShortcut( uint index, const TDEShortcut &shortcut ) = 0;
/**
* Checks whether the shortcut with the given @p index is saved in the
@@ -180,56 +180,56 @@ class TDECORE_EXPORT KShortcutList
/// used to extend the interface with virtuals without breaking binary compatibility
virtual void virtual_hook( int id, void* data );
private:
- class KShortcutListPrivate* d;
+ class TDEShortcutListPrivate* d;
};
//---------------------------------------------------------------------
-// KAccelShortcutList
+// TDEAccelShortcutList
//---------------------------------------------------------------------
-class KAccel;
-class KAccelActions;
+class TDEAccel;
+class TDEAccelActions;
class TDEGlobalAccel;
/**
- * KShortcutList implementation to access KAccel and
+ * TDEShortcutList implementation to access TDEAccel and
* TDEGlobalAccel lists.
*/
-class TDECORE_EXPORT KAccelShortcutList : public KShortcutList
+class TDECORE_EXPORT TDEAccelShortcutList : public TDEShortcutList
{
public:
/**
- * Creates a new KShortcutList that accesses the given KAccel.
+ * Creates a new TDEShortcutList that accesses the given TDEAccel.
* @param accel the accelerators to access
*/
- KAccelShortcutList( KAccel* accel );
+ TDEAccelShortcutList( TDEAccel* accel );
/**
- * Creates a new KShortcutList that accesses the given
+ * Creates a new TDEShortcutList that accesses the given
* TDEGlobalAccel.
* @param accel the accelerators to access
*/
- KAccelShortcutList( TDEGlobalAccel* accel );
+ TDEAccelShortcutList( TDEGlobalAccel* accel );
/**
* @internal
- * Creates a new KShortcutList that accesses the given
- * KAccelActions collection.
+ * Creates a new TDEShortcutList that accesses the given
+ * TDEAccelActions collection.
* @param actions the actions to access
* @param bGlobal true to save the actions in the global
* configuration file
*/
- KAccelShortcutList( KAccelActions &actions, bool bGlobal );
- virtual ~KAccelShortcutList();
+ TDEAccelShortcutList( TDEAccelActions &actions, bool bGlobal );
+ virtual ~TDEAccelShortcutList();
virtual uint count() const;
virtual TQString name( uint index ) const;
virtual TQString label( uint index ) const;
virtual TQString whatsThis( uint index ) const;
- virtual const KShortcut& shortcut( uint index ) const;
- virtual const KShortcut& shortcutDefault( uint index ) const;
+ virtual const TDEShortcut& shortcut( uint index ) const;
+ virtual const TDEShortcut& shortcutDefault( uint index ) const;
virtual bool isConfigurable( uint index ) const;
- virtual bool setShortcut( uint index , const KShortcut& shortcut );
+ virtual bool setShortcut( uint index , const TDEShortcut& shortcut );
virtual bool isGlobal( uint index ) const;
/** \internal */
@@ -241,26 +241,26 @@ class TDECORE_EXPORT KAccelShortcutList : public KShortcutList
protected:
/** Actions (collection) for this shortcut list. Set by constructor. */
- KAccelActions& m_actions;
+ TDEAccelActions& m_actions;
/** Is this shortcut list global? Access through isGlobal() */
bool m_bGlobal;
protected:
virtual void virtual_hook( int id, void* data );
private:
- class KAccelShortcutListPrivate* d;
+ class TDEAccelShortcutListPrivate* d;
};
-namespace KStdAccel {
+namespace TDEStdAccel {
//---------------------------------------------------------------------
// ShortcutList
//---------------------------------------------------------------------
/**
- * KShortcutList implementation that accesses KStdAccel
+ * TDEShortcutList implementation that accesses TDEStdAccel
* actions.
*/
-class TDECORE_EXPORT ShortcutList : public KShortcutList
+class TDECORE_EXPORT ShortcutList : public TDEShortcutList
{
public:
/**
@@ -273,10 +273,10 @@ class TDECORE_EXPORT ShortcutList : public KShortcutList
virtual TQString name( uint index ) const;
virtual TQString label( uint index ) const;
virtual TQString whatsThis( uint index ) const;
- virtual const KShortcut& shortcut( uint index ) const;
- virtual const KShortcut& shortcutDefault( uint index ) const;
+ virtual const TDEShortcut& shortcut( uint index ) const;
+ virtual const TDEShortcut& shortcutDefault( uint index ) const;
virtual bool isConfigurable( uint index ) const;
- virtual bool setShortcut( uint index , const KShortcut& shortcut );
+ virtual bool setShortcut( uint index , const TDEShortcut& shortcut );
/** \internal */
virtual TQVariant getOther( Other, uint index ) const;
diff --git a/tdecore/kshortcutmenu.cpp b/tdecore/kshortcutmenu.cpp
index 4bf18d965..be485fb7e 100644
--- a/tdecore/kshortcutmenu.cpp
+++ b/tdecore/kshortcutmenu.cpp
@@ -27,7 +27,7 @@
#include "kshortcutmenu.h"
//#include <kkeynative.h>
-KShortcutMenu::KShortcutMenu( TQWidget* pParent, KAccelActions* pActions, KKeySequence seq )
+TDEShortcutMenu::TDEShortcutMenu( TQWidget* pParent, TDEAccelActions* pActions, KKeySequence seq )
: TQPopupMenu( pParent ),
m_pActions( pActions ),
m_seq( seq )
@@ -44,9 +44,9 @@ KShortcutMenu::KShortcutMenu( TQWidget* pParent, KAccelActions* pActions, KKeySe
insertItem( pTitle );
}
-bool KShortcutMenu::insertAction( uint iAction, KKeySequence seq )
+bool TDEShortcutMenu::insertAction( uint iAction, KKeySequence seq )
{
- KAccelAction* pAction = m_pActions->actionPtr( iAction );
+ TDEAccelAction* pAction = m_pActions->actionPtr( iAction );
if( pAction ) {
insertItem( "", iAction );
@@ -57,14 +57,14 @@ bool KShortcutMenu::insertAction( uint iAction, KKeySequence seq )
}
-void KShortcutMenu::updateShortcuts()
+void TDEShortcutMenu::updateShortcuts()
{
pTitle->setText( m_seq.toString() + ",..." );
for( uint iItem = 1; iItem < count(); iItem++ ) {
int iAction = idAt( iItem );
if( iAction >= 0 ) {
- KAccelAction* pAction = m_pActions->actionPtr( iAction );
+ TDEAccelAction* pAction = m_pActions->actionPtr( iAction );
if( pAction ) {
KKeySequence seq = m_seqs[iItem];
TQString sSeq = seq.key(m_seq.count()).toString();
@@ -78,7 +78,7 @@ void KShortcutMenu::updateShortcuts()
}
}
-void KShortcutMenu::keyPressEvent( TQKeyEvent* pEvent )
+void TDEShortcutMenu::keyPressEvent( TQKeyEvent* pEvent )
{
kdDebug() << "keypress; " << pEvent->key() << endl;
KKey key( pEvent );
@@ -117,7 +117,7 @@ void KShortcutMenu::keyPressEvent( TQKeyEvent* pEvent )
}
}
-int KShortcutMenu::searchForKey( KKey key )
+int TDEShortcutMenu::searchForKey( KKey key )
{
int iItemFound = -1; // -1 indicates no match
uint iKey = m_seq.count();
@@ -138,7 +138,7 @@ int KShortcutMenu::searchForKey( KKey key )
return iItemFound;
}
-void KShortcutMenu::keepItemsMatching( KKey key )
+void TDEShortcutMenu::keepItemsMatching( KKey key )
{
kdDebug(125) << "MyAccel::keepItemsMatching( " << key.toStringInternal() << " )" << endl;
diff --git a/tdecore/kshortcutmenu.h b/tdecore/kshortcutmenu.h
index 2c682342d..6e01cdd95 100644
--- a/tdecore/kshortcutmenu.h
+++ b/tdecore/kshortcutmenu.h
@@ -27,16 +27,16 @@
class TQLabel;
-class KAccelActions;
+class TDEAccelActions;
/**
* @internal
*/
-class TDECORE_EXPORT KShortcutMenu : public TQPopupMenu
+class TDECORE_EXPORT TDEShortcutMenu : public TQPopupMenu
{
Q_OBJECT
public:
- KShortcutMenu( TQWidget* pParent, KAccelActions* pActions, KKeySequence seq );
+ TDEShortcutMenu( TQWidget* pParent, TDEAccelActions* pActions, KKeySequence seq );
bool insertAction( uint iAction, KKeySequence seq );
@@ -52,7 +52,7 @@ class TDECORE_EXPORT KShortcutMenu : public TQPopupMenu
private:
typedef TQMap<uint, KKeySequence> IndexToKKeySequence;
- KAccelActions* m_pActions;
+ TDEAccelActions* m_pActions;
KKeySequence m_seq;
TQLabel* pTitle;
IndexToKKeySequence m_seqs;
diff --git a/tdecore/kstdaccel.cpp b/tdecore/kstdaccel.cpp
index afc49aac4..ac1381c88 100644
--- a/tdecore/kstdaccel.cpp
+++ b/tdecore/kstdaccel.cpp
@@ -30,84 +30,84 @@
#include <kshortcut.h>
#include <kshortcutlist.h>
-namespace KStdAccel
+namespace TDEStdAccel
{
-struct KStdAccelInfo
+struct TDEStdAccelInfo
{
StdAccel id;
const char* psName;
const char* psDesc;
int cutDefault, cutDefault4, cutDefault3B, cutDefault4B;
- KShortcut cut;
+ TDEShortcut cut;
bool bInitialized;
};
-/** Array of predefined KStdAccelInfo objects, which cover all
+/** Array of predefined TDEStdAccelInfo objects, which cover all
the "standard" accelerators. Each enum value from StdAccel
should appear in this table.
*/
-static KStdAccelInfo g_infoStdAccel[] =
+static TDEStdAccelInfo g_infoStdAccel[] =
{
- {AccelNone, "Group:File", I18N_NOOP("File"), 0, 0, 0, 0, KShortcut(), false },
- { Open, I18N_NOOP("Open"), 0, Qt::CTRL+Qt::Key_O, 0, 0, 0, KShortcut(), false },
- { New, I18N_NOOP("New"), 0, Qt::CTRL+Qt::Key_N, 0, 0, 0, KShortcut(), false },
- { Close, I18N_NOOP("Close"), 0, Qt::CTRL+Qt::Key_W, Qt::CTRL+Qt::Key_Escape, 0, Qt::CTRL+Qt::Key_W, KShortcut(), false },
- { Save, I18N_NOOP("Save"), 0, Qt::CTRL+Qt::Key_S, 0, 0, 0, KShortcut(), false },
- { Print, I18N_NOOP("Print"), 0, Qt::CTRL+Qt::Key_P, 0, 0, 0, KShortcut(), false },
- { Quit, I18N_NOOP("Quit"), 0, Qt::CTRL+Qt::Key_Q, 0, 0, 0, KShortcut(), false },
- {AccelNone, "Group:Edit", I18N_NOOP("Edit"), 0, 0, 0, 0, KShortcut(), false },
- { Undo, I18N_NOOP("Undo"), 0, Qt::CTRL+Qt::Key_Z, 0, 0, 0, KShortcut(), false },
- { Redo, I18N_NOOP("Redo"), 0, Qt::CTRL+Qt::SHIFT+Qt::Key_Z, 0, 0, 0, KShortcut(), false },
- { Cut, I18N_NOOP("Cut"), 0, Qt::CTRL+Qt::Key_X, 0, Qt::SHIFT+Qt::Key_Delete, 0, KShortcut(), false },
- { Copy, I18N_NOOP("Copy"), 0, Qt::CTRL+Qt::Key_C, 0, Qt::CTRL+Qt::Key_Insert, 0, KShortcut(), false },
- { Paste, I18N_NOOP("Paste"), 0, Qt::CTRL+Qt::Key_V, 0, Qt::SHIFT+Qt::Key_Insert, 0, KShortcut(), false },
- { PasteSelection, I18N_NOOP("Paste Selection"), 0, 0, 0, Qt::CTRL+Qt::SHIFT+Qt::Key_Insert, 0, KShortcut(), false },
- { SelectAll, "SelectAll", I18N_NOOP("Select All"), Qt::CTRL+Qt::Key_A, 0, 0, 0, KShortcut(), false },
- { Deselect, I18N_NOOP("Deselect"), 0, Qt::CTRL+Qt::SHIFT+Qt::Key_A, 0, 0, 0, KShortcut(), false },
- { DeleteWordBack, "DeleteWordBack", I18N_NOOP("Delete Word Backwards"), Qt::CTRL+Qt::Key_Backspace, 0, 0, 0, KShortcut(), false },
- { DeleteWordForward, "DeleteWordForward", I18N_NOOP("Delete Word Forward"), Qt::CTRL+Qt::Key_Delete, 0, 0, 0, KShortcut(), false },
- { Find, I18N_NOOP("Find"), 0, Qt::CTRL+Qt::Key_F, 0, 0, 0, KShortcut(), false },
- { FindNext, "FindNext", I18N_NOOP("Find Next"), Qt::Key_F3, 0, 0, 0, KShortcut(), false },
- { FindPrev, "FindPrev", I18N_NOOP("Find Prev"), Qt::SHIFT+Qt::Key_F3, 0, 0, 0, KShortcut(), false },
- { Replace, I18N_NOOP("Replace"), 0, Qt::CTRL+Qt::Key_R, 0, 0, 0, KShortcut(), false },
- {AccelNone, "Group:Navigation", I18N_NOOP("Navigation"), 0, 0, 0, 0, KShortcut(), false },
- { Home, I18N_NOOP2("Opposite to End","Home"), 0, Qt::CTRL+Qt::Key_Home, 0, Qt::Key_HomePage, 0, KShortcut(), false },
- { End, I18N_NOOP("End"), 0, Qt::CTRL+Qt::Key_End, 0, 0, 0, KShortcut(), false },
- { BeginningOfLine, "BeginningOfLine", I18N_NOOP("Beginning of Line"), Qt::Key_Home, 0, 0, 0, KShortcut(), false},
- { EndOfLine, "EndOfLine", I18N_NOOP("End of Line"), Qt::Key_End, 0, 0, 0, KShortcut(), false},
- { Prior, I18N_NOOP("Prior"), 0, TQt::Key_Prior, 0, 0, 0, KShortcut(), false },
- { Next, I18N_NOOP2("Opposite to Prior","Next"), 0, TQt::Key_Next, 0, 0, 0, KShortcut(), false },
- { GotoLine, "GotoLine", I18N_NOOP("Go to Line"), Qt::CTRL+Qt::Key_G, 0, 0, 0, KShortcut(), false },
- { AddBookmark, "AddBookmark", I18N_NOOP("Add Bookmark"), Qt::CTRL+Qt::Key_B, 0, 0, 0, KShortcut(), false },
- { ZoomIn, "ZoomIn", I18N_NOOP("Zoom In"), Qt::CTRL+Qt::Key_Plus, 0, 0, 0, KShortcut(), false },
- { ZoomOut, "ZoomOut", I18N_NOOP("Zoom Out"), Qt::CTRL+Qt::Key_Minus, 0, 0, 0, KShortcut(), false },
- { Up, I18N_NOOP("Up"), 0, Qt::ALT+Qt::Key_Up, 0, 0, 0, KShortcut(), false },
- { Back, I18N_NOOP("Back"), 0, Qt::ALT+Qt::Key_Left, 0, Qt::Key_Back, 0, KShortcut(), false },
- { Forward, I18N_NOOP("Forward"), 0, Qt::ALT+Qt::Key_Right, 0, Qt::Key_Forward, 0, KShortcut(), false },
- { Reload, I18N_NOOP("Reload"), 0, Qt::Key_F5, 0, Qt::Key_Refresh, 0, KShortcut(), false },
- { PopupMenuContext, "PopupMenuContext", I18N_NOOP("Popup Menu Context"), Qt::Key_Menu, 0, 0, 0, KShortcut(), false },
- { ShowMenubar, "ShowMenubar", I18N_NOOP("Show Menu Bar"), Qt::CTRL+Qt::Key_M, 0, 0, 0, KShortcut(), false },
- { BackwardWord, "BackwardWord", I18N_NOOP("Backward Word"), Qt::CTRL+Qt::Key_Left, 0, 0, 0, KShortcut(), false },
- { ForwardWord, "ForwardWord", I18N_NOOP("Forward Word"), Qt::CTRL+Qt::Key_Right, 0, 0, 0, KShortcut(), false },
- { TabNext, I18N_NOOP("Activate Next Tab"), 0, Qt::CTRL+Qt::Key_Period, 0, Qt::CTRL+Qt::Key_BracketRight, 0, KShortcut(), false },
- { TabPrev, I18N_NOOP("Activate Previous Tab"), 0, Qt::CTRL+Qt::Key_Comma, 0, Qt::CTRL+Qt::Key_BracketLeft, 0, KShortcut(), false },
- { FullScreen, "FullScreen", I18N_NOOP("Full Screen Mode"), Qt::CTRL+Qt::SHIFT+Qt::Key_F, 0, 0, 0, KShortcut(), false },
- {AccelNone, "Group:Help", I18N_NOOP("Help"), 0, 0, 0, 0, KShortcut(), false },
- { Help, I18N_NOOP("Help"), 0, Qt::Key_F1, 0, 0, 0, KShortcut(), false },
- { WhatsThis, "WhatsThis", I18N_NOOP("What's This"), Qt::SHIFT+Qt::Key_F1, 0, 0, 0, KShortcut(), false },
- {AccelNone, "Group:TextCompletion", I18N_NOOP("Text Completion"), 0, 0, 0, 0, KShortcut(), false },
- { TextCompletion, "TextCompletion", I18N_NOOP("Text Completion"), Qt::CTRL+Qt::Key_E, 0, 0, 0, KShortcut(), false },
- { PrevCompletion, "PrevCompletion", I18N_NOOP("Previous Completion Match"), Qt::CTRL+Qt::Key_Up, 0, 0, 0, KShortcut(), false },
- { NextCompletion, "NextCompletion", I18N_NOOP("Next Completion Match"), Qt::CTRL+Qt::Key_Down, 0, 0, 0, KShortcut(), false },
- { SubstringCompletion, "SubstringCompletion", I18N_NOOP("Substring Completion"), Qt::CTRL+Qt::Key_T, 0, 0, 0, KShortcut(), false },
- { RotateUp, "RotateUp", I18N_NOOP("Previous Item in List"), Qt::Key_Up, 0, 0, 0, KShortcut(), false },
- { RotateDown, "RotateDown", I18N_NOOP("Next Item in List"), Qt::Key_Down, 0, 0, 0, KShortcut(), false },
- { AccelNone, 0, 0, 0, 0, 0, 0, KShortcut(), false }
+ {AccelNone, "Group:File", I18N_NOOP("File"), 0, 0, 0, 0, TDEShortcut(), false },
+ { Open, I18N_NOOP("Open"), 0, Qt::CTRL+Qt::Key_O, 0, 0, 0, TDEShortcut(), false },
+ { New, I18N_NOOP("New"), 0, Qt::CTRL+Qt::Key_N, 0, 0, 0, TDEShortcut(), false },
+ { Close, I18N_NOOP("Close"), 0, Qt::CTRL+Qt::Key_W, Qt::CTRL+Qt::Key_Escape, 0, Qt::CTRL+Qt::Key_W, TDEShortcut(), false },
+ { Save, I18N_NOOP("Save"), 0, Qt::CTRL+Qt::Key_S, 0, 0, 0, TDEShortcut(), false },
+ { Print, I18N_NOOP("Print"), 0, Qt::CTRL+Qt::Key_P, 0, 0, 0, TDEShortcut(), false },
+ { Quit, I18N_NOOP("Quit"), 0, Qt::CTRL+Qt::Key_Q, 0, 0, 0, TDEShortcut(), false },
+ {AccelNone, "Group:Edit", I18N_NOOP("Edit"), 0, 0, 0, 0, TDEShortcut(), false },
+ { Undo, I18N_NOOP("Undo"), 0, Qt::CTRL+Qt::Key_Z, 0, 0, 0, TDEShortcut(), false },
+ { Redo, I18N_NOOP("Redo"), 0, Qt::CTRL+Qt::SHIFT+Qt::Key_Z, 0, 0, 0, TDEShortcut(), false },
+ { Cut, I18N_NOOP("Cut"), 0, Qt::CTRL+Qt::Key_X, 0, Qt::SHIFT+Qt::Key_Delete, 0, TDEShortcut(), false },
+ { Copy, I18N_NOOP("Copy"), 0, Qt::CTRL+Qt::Key_C, 0, Qt::CTRL+Qt::Key_Insert, 0, TDEShortcut(), false },
+ { Paste, I18N_NOOP("Paste"), 0, Qt::CTRL+Qt::Key_V, 0, Qt::SHIFT+Qt::Key_Insert, 0, TDEShortcut(), false },
+ { PasteSelection, I18N_NOOP("Paste Selection"), 0, 0, 0, Qt::CTRL+Qt::SHIFT+Qt::Key_Insert, 0, TDEShortcut(), false },
+ { SelectAll, "SelectAll", I18N_NOOP("Select All"), Qt::CTRL+Qt::Key_A, 0, 0, 0, TDEShortcut(), false },
+ { Deselect, I18N_NOOP("Deselect"), 0, Qt::CTRL+Qt::SHIFT+Qt::Key_A, 0, 0, 0, TDEShortcut(), false },
+ { DeleteWordBack, "DeleteWordBack", I18N_NOOP("Delete Word Backwards"), Qt::CTRL+Qt::Key_Backspace, 0, 0, 0, TDEShortcut(), false },
+ { DeleteWordForward, "DeleteWordForward", I18N_NOOP("Delete Word Forward"), Qt::CTRL+Qt::Key_Delete, 0, 0, 0, TDEShortcut(), false },
+ { Find, I18N_NOOP("Find"), 0, Qt::CTRL+Qt::Key_F, 0, 0, 0, TDEShortcut(), false },
+ { FindNext, "FindNext", I18N_NOOP("Find Next"), Qt::Key_F3, 0, 0, 0, TDEShortcut(), false },
+ { FindPrev, "FindPrev", I18N_NOOP("Find Prev"), Qt::SHIFT+Qt::Key_F3, 0, 0, 0, TDEShortcut(), false },
+ { Replace, I18N_NOOP("Replace"), 0, Qt::CTRL+Qt::Key_R, 0, 0, 0, TDEShortcut(), false },
+ {AccelNone, "Group:Navigation", I18N_NOOP("Navigation"), 0, 0, 0, 0, TDEShortcut(), false },
+ { Home, I18N_NOOP2("Opposite to End","Home"), 0, Qt::CTRL+Qt::Key_Home, 0, Qt::Key_HomePage, 0, TDEShortcut(), false },
+ { End, I18N_NOOP("End"), 0, Qt::CTRL+Qt::Key_End, 0, 0, 0, TDEShortcut(), false },
+ { BeginningOfLine, "BeginningOfLine", I18N_NOOP("Beginning of Line"), Qt::Key_Home, 0, 0, 0, TDEShortcut(), false},
+ { EndOfLine, "EndOfLine", I18N_NOOP("End of Line"), Qt::Key_End, 0, 0, 0, TDEShortcut(), false},
+ { Prior, I18N_NOOP("Prior"), 0, TQt::Key_Prior, 0, 0, 0, TDEShortcut(), false },
+ { Next, I18N_NOOP2("Opposite to Prior","Next"), 0, TQt::Key_Next, 0, 0, 0, TDEShortcut(), false },
+ { GotoLine, "GotoLine", I18N_NOOP("Go to Line"), Qt::CTRL+Qt::Key_G, 0, 0, 0, TDEShortcut(), false },
+ { AddBookmark, "AddBookmark", I18N_NOOP("Add Bookmark"), Qt::CTRL+Qt::Key_B, 0, 0, 0, TDEShortcut(), false },
+ { ZoomIn, "ZoomIn", I18N_NOOP("Zoom In"), Qt::CTRL+Qt::Key_Plus, 0, 0, 0, TDEShortcut(), false },
+ { ZoomOut, "ZoomOut", I18N_NOOP("Zoom Out"), Qt::CTRL+Qt::Key_Minus, 0, 0, 0, TDEShortcut(), false },
+ { Up, I18N_NOOP("Up"), 0, Qt::ALT+Qt::Key_Up, 0, 0, 0, TDEShortcut(), false },
+ { Back, I18N_NOOP("Back"), 0, Qt::ALT+Qt::Key_Left, 0, Qt::Key_Back, 0, TDEShortcut(), false },
+ { Forward, I18N_NOOP("Forward"), 0, Qt::ALT+Qt::Key_Right, 0, Qt::Key_Forward, 0, TDEShortcut(), false },
+ { Reload, I18N_NOOP("Reload"), 0, Qt::Key_F5, 0, Qt::Key_Refresh, 0, TDEShortcut(), false },
+ { PopupMenuContext, "PopupMenuContext", I18N_NOOP("Popup Menu Context"), Qt::Key_Menu, 0, 0, 0, TDEShortcut(), false },
+ { ShowMenubar, "ShowMenubar", I18N_NOOP("Show Menu Bar"), Qt::CTRL+Qt::Key_M, 0, 0, 0, TDEShortcut(), false },
+ { BackwardWord, "BackwardWord", I18N_NOOP("Backward Word"), Qt::CTRL+Qt::Key_Left, 0, 0, 0, TDEShortcut(), false },
+ { ForwardWord, "ForwardWord", I18N_NOOP("Forward Word"), Qt::CTRL+Qt::Key_Right, 0, 0, 0, TDEShortcut(), false },
+ { TabNext, I18N_NOOP("Activate Next Tab"), 0, Qt::CTRL+Qt::Key_Period, 0, Qt::CTRL+Qt::Key_BracketRight, 0, TDEShortcut(), false },
+ { TabPrev, I18N_NOOP("Activate Previous Tab"), 0, Qt::CTRL+Qt::Key_Comma, 0, Qt::CTRL+Qt::Key_BracketLeft, 0, TDEShortcut(), false },
+ { FullScreen, "FullScreen", I18N_NOOP("Full Screen Mode"), Qt::CTRL+Qt::SHIFT+Qt::Key_F, 0, 0, 0, TDEShortcut(), false },
+ {AccelNone, "Group:Help", I18N_NOOP("Help"), 0, 0, 0, 0, TDEShortcut(), false },
+ { Help, I18N_NOOP("Help"), 0, Qt::Key_F1, 0, 0, 0, TDEShortcut(), false },
+ { WhatsThis, "WhatsThis", I18N_NOOP("What's This"), Qt::SHIFT+Qt::Key_F1, 0, 0, 0, TDEShortcut(), false },
+ {AccelNone, "Group:TextCompletion", I18N_NOOP("Text Completion"), 0, 0, 0, 0, TDEShortcut(), false },
+ { TextCompletion, "TextCompletion", I18N_NOOP("Text Completion"), Qt::CTRL+Qt::Key_E, 0, 0, 0, TDEShortcut(), false },
+ { PrevCompletion, "PrevCompletion", I18N_NOOP("Previous Completion Match"), Qt::CTRL+Qt::Key_Up, 0, 0, 0, TDEShortcut(), false },
+ { NextCompletion, "NextCompletion", I18N_NOOP("Next Completion Match"), Qt::CTRL+Qt::Key_Down, 0, 0, 0, TDEShortcut(), false },
+ { SubstringCompletion, "SubstringCompletion", I18N_NOOP("Substring Completion"), Qt::CTRL+Qt::Key_T, 0, 0, 0, TDEShortcut(), false },
+ { RotateUp, "RotateUp", I18N_NOOP("Previous Item in List"), Qt::Key_Up, 0, 0, 0, TDEShortcut(), false },
+ { RotateDown, "RotateDown", I18N_NOOP("Next Item in List"), Qt::Key_Down, 0, 0, 0, TDEShortcut(), false },
+ { AccelNone, 0, 0, 0, 0, 0, 0, TDEShortcut(), false }
};
-/** Search for the KStdAccelInfo object associated with the given @p id. */
-static KStdAccelInfo* infoPtr( StdAccel id )
+/** Search for the TDEStdAccelInfo object associated with the given @p id. */
+static TDEStdAccelInfo* infoPtr( StdAccel id )
{
if( id != AccelNone ) {
// Linear search. Changing the data structure doesn't seem possible
@@ -127,10 +127,10 @@ static KStdAccelInfo* infoPtr( StdAccel id )
static void initialize( StdAccel id )
{
TDEConfigGroupSaver saver( TDEGlobal::config(), "Shortcuts" );
- KStdAccelInfo* pInfo = infoPtr( id );
+ TDEStdAccelInfo* pInfo = infoPtr( id );
if( !pInfo ) {
- kdWarning(125) << "KStdAccel: id not found!" << endl; // -- ellis
+ kdWarning(125) << "TDEStdAccel: id not found!" << endl; // -- ellis
return;
}
@@ -147,7 +147,7 @@ static void initialize( StdAccel id )
TQString name( StdAccel id )
{
- KStdAccelInfo* pInfo = infoPtr( id );
+ TDEStdAccelInfo* pInfo = infoPtr( id );
if( !pInfo )
return TQString::null;
return pInfo->psName;
@@ -155,27 +155,27 @@ TQString name( StdAccel id )
TQString label( StdAccel id )
{
- KStdAccelInfo* pInfo = infoPtr( id );
+ TDEStdAccelInfo* pInfo = infoPtr( id );
if( !pInfo )
return TQString::null;
return i18n((pInfo->psDesc) ? pInfo->psDesc : pInfo->psName);
}
-// TODO: Add psWhatsThis entry to KStdAccelInfo
+// TODO: Add psWhatsThis entry to TDEStdAccelInfo
TQString whatsThis( StdAccel /*id*/ )
{
-// KStdAccelInfo* pInfo = infoPtr( id );
+// TDEStdAccelInfo* pInfo = infoPtr( id );
// if( pInfo && pInfo->psWhatsThis )
// return i18n(pInfo->psWhatsThis);
// else
return TQString::null;
}
-const KShortcut& shortcut( StdAccel id )
+const TDEShortcut& shortcut( StdAccel id )
{
- KStdAccelInfo* pInfo = infoPtr( id );
+ TDEStdAccelInfo* pInfo = infoPtr( id );
if( !pInfo )
- return KShortcut::null();
+ return TDEShortcut::null();
if( !pInfo->bInitialized )
initialize( id );
@@ -199,17 +199,17 @@ StdAccel findStdAccel( const KKeySequence& seq )
return AccelNone;
}
-KShortcut shortcutDefault( StdAccel id )
+TDEShortcut shortcutDefault( StdAccel id )
{
- return (KAccelAction::useFourModifierKeys())
+ return (TDEAccelAction::useFourModifierKeys())
? shortcutDefault4(id) : shortcutDefault3(id);
}
-KShortcut shortcutDefault3( StdAccel id )
+TDEShortcut shortcutDefault3( StdAccel id )
{
- KShortcut cut;
+ TDEShortcut cut;
- KStdAccelInfo* pInfo = infoPtr( id );
+ TDEStdAccelInfo* pInfo = infoPtr( id );
if( pInfo ) {
if( pInfo->cutDefault )
cut.init( pInfo->cutDefault );
@@ -222,13 +222,13 @@ KShortcut shortcutDefault3( StdAccel id )
return cut;
}
-KShortcut shortcutDefault4( StdAccel id )
+TDEShortcut shortcutDefault4( StdAccel id )
{
- KShortcut cut;
+ TDEShortcut cut;
- KStdAccelInfo* pInfo = infoPtr( id );
+ TDEStdAccelInfo* pInfo = infoPtr( id );
if( pInfo ) {
- KStdAccelInfo& info = *pInfo;
+ TDEStdAccelInfo& info = *pInfo;
KKeySequence key2;
cut.init( (info.cutDefault4) ?
@@ -247,13 +247,13 @@ KShortcut shortcutDefault4( StdAccel id )
}
#if 0 // unused
-void createAccelActions( KAccelActions& actions )
+void createAccelActions( TDEAccelActions& actions )
{
actions.clear();
for( uint i = 0; g_infoStdAccel[i].psName != 0; i++ ) {
StdAccel id = g_infoStdAccel[i].id;
- KStdAccelInfo* pInfo = &g_infoStdAccel[i];
+ TDEStdAccelInfo* pInfo = &g_infoStdAccel[i];
if( id != AccelNone ) {
actions.insert( pInfo->psName,
@@ -267,54 +267,54 @@ void createAccelActions( KAccelActions& actions )
}
#endif
-const KShortcut& open() { return shortcut( Open ); }
-const KShortcut& openNew() { return shortcut( New ); }
-const KShortcut& close() { return shortcut( Close ); }
-const KShortcut& save() { return shortcut( Save ); }
-const KShortcut& print() { return shortcut( Print ); }
-const KShortcut& quit() { return shortcut( Quit ); }
-const KShortcut& cut() { return shortcut( Cut ); }
-const KShortcut& copy() { return shortcut( Copy ); }
-const KShortcut& paste() { return shortcut( Paste ); }
-const KShortcut& pasteSelection() { return shortcut( PasteSelection ); }
-const KShortcut& deleteWordBack() { return shortcut( DeleteWordBack ); }
-const KShortcut& deleteWordForward() { return shortcut( DeleteWordForward ); }
-const KShortcut& undo() { return shortcut( Undo ); }
-const KShortcut& redo() { return shortcut( Redo ); }
-const KShortcut& find() { return shortcut( Find ); }
-const KShortcut& findNext() { return shortcut( FindNext ); }
-const KShortcut& findPrev() { return shortcut( FindPrev ); }
-const KShortcut& replace() { return shortcut( Replace ); }
-const KShortcut& home() { return shortcut( Home ); }
-const KShortcut& end() { return shortcut( End ); }
-const KShortcut& beginningOfLine() { return shortcut( BeginningOfLine ); }
-const KShortcut& endOfLine() { return shortcut( EndOfLine ); }
-const KShortcut& prior() { return shortcut( Prior ); }
-const KShortcut& next() { return shortcut( Next ); }
-const KShortcut& backwardWord() { return shortcut( BackwardWord ); }
-const KShortcut& forwardWord() { return shortcut( ForwardWord ); }
-const KShortcut& gotoLine() { return shortcut( GotoLine ); }
-const KShortcut& addBookmark() { return shortcut( AddBookmark ); }
-const KShortcut& tabNext() { return shortcut( TabNext ); }
-const KShortcut& tabPrev() { return shortcut( TabPrev ); }
-const KShortcut& fullScreen() { return shortcut( FullScreen ); }
-const KShortcut& zoomIn() { return shortcut( ZoomIn ); }
-const KShortcut& zoomOut() { return shortcut( ZoomOut ); }
-const KShortcut& help() { return shortcut( Help ); }
-const KShortcut& completion() { return shortcut( TextCompletion ); }
-const KShortcut& prevCompletion() { return shortcut( PrevCompletion ); }
-const KShortcut& nextCompletion() { return shortcut( NextCompletion ); }
-const KShortcut& rotateUp() { return shortcut( RotateUp ); }
-const KShortcut& rotateDown() { return shortcut( RotateDown ); }
-const KShortcut& substringCompletion() { return shortcut( SubstringCompletion ); }
-const KShortcut& popupMenuContext() { return shortcut( PopupMenuContext ); }
-const KShortcut& whatsThis() { return shortcut( WhatsThis ); }
-const KShortcut& reload() { return shortcut( Reload ); }
-const KShortcut& selectAll() { return shortcut( SelectAll ); }
-const KShortcut& up() { return shortcut( Up ); }
-const KShortcut& back() { return shortcut( Back ); }
-const KShortcut& forward() { return shortcut( Forward ); }
-const KShortcut& showMenubar() { return shortcut( ShowMenubar ); }
+const TDEShortcut& open() { return shortcut( Open ); }
+const TDEShortcut& openNew() { return shortcut( New ); }
+const TDEShortcut& close() { return shortcut( Close ); }
+const TDEShortcut& save() { return shortcut( Save ); }
+const TDEShortcut& print() { return shortcut( Print ); }
+const TDEShortcut& quit() { return shortcut( Quit ); }
+const TDEShortcut& cut() { return shortcut( Cut ); }
+const TDEShortcut& copy() { return shortcut( Copy ); }
+const TDEShortcut& paste() { return shortcut( Paste ); }
+const TDEShortcut& pasteSelection() { return shortcut( PasteSelection ); }
+const TDEShortcut& deleteWordBack() { return shortcut( DeleteWordBack ); }
+const TDEShortcut& deleteWordForward() { return shortcut( DeleteWordForward ); }
+const TDEShortcut& undo() { return shortcut( Undo ); }
+const TDEShortcut& redo() { return shortcut( Redo ); }
+const TDEShortcut& find() { return shortcut( Find ); }
+const TDEShortcut& findNext() { return shortcut( FindNext ); }
+const TDEShortcut& findPrev() { return shortcut( FindPrev ); }
+const TDEShortcut& replace() { return shortcut( Replace ); }
+const TDEShortcut& home() { return shortcut( Home ); }
+const TDEShortcut& end() { return shortcut( End ); }
+const TDEShortcut& beginningOfLine() { return shortcut( BeginningOfLine ); }
+const TDEShortcut& endOfLine() { return shortcut( EndOfLine ); }
+const TDEShortcut& prior() { return shortcut( Prior ); }
+const TDEShortcut& next() { return shortcut( Next ); }
+const TDEShortcut& backwardWord() { return shortcut( BackwardWord ); }
+const TDEShortcut& forwardWord() { return shortcut( ForwardWord ); }
+const TDEShortcut& gotoLine() { return shortcut( GotoLine ); }
+const TDEShortcut& addBookmark() { return shortcut( AddBookmark ); }
+const TDEShortcut& tabNext() { return shortcut( TabNext ); }
+const TDEShortcut& tabPrev() { return shortcut( TabPrev ); }
+const TDEShortcut& fullScreen() { return shortcut( FullScreen ); }
+const TDEShortcut& zoomIn() { return shortcut( ZoomIn ); }
+const TDEShortcut& zoomOut() { return shortcut( ZoomOut ); }
+const TDEShortcut& help() { return shortcut( Help ); }
+const TDEShortcut& completion() { return shortcut( TextCompletion ); }
+const TDEShortcut& prevCompletion() { return shortcut( PrevCompletion ); }
+const TDEShortcut& nextCompletion() { return shortcut( NextCompletion ); }
+const TDEShortcut& rotateUp() { return shortcut( RotateUp ); }
+const TDEShortcut& rotateDown() { return shortcut( RotateDown ); }
+const TDEShortcut& substringCompletion() { return shortcut( SubstringCompletion ); }
+const TDEShortcut& popupMenuContext() { return shortcut( PopupMenuContext ); }
+const TDEShortcut& whatsThis() { return shortcut( WhatsThis ); }
+const TDEShortcut& reload() { return shortcut( Reload ); }
+const TDEShortcut& selectAll() { return shortcut( SelectAll ); }
+const TDEShortcut& up() { return shortcut( Up ); }
+const TDEShortcut& back() { return shortcut( Back ); }
+const TDEShortcut& forward() { return shortcut( Forward ); }
+const TDEShortcut& showMenubar() { return shortcut( ShowMenubar ); }
//---------------------------------------------------------------------
// ShortcutList
@@ -345,24 +345,24 @@ TQString ShortcutList::label( uint i ) const
TQString ShortcutList::whatsThis( uint ) const
{ return TQString::null; }
-const KShortcut& ShortcutList::shortcut( uint i ) const
+const TDEShortcut& ShortcutList::shortcut( uint i ) const
{
if( !g_infoStdAccel[i].bInitialized )
initialize( g_infoStdAccel[i].id );
return g_infoStdAccel[i].cut;
}
-const KShortcut& ShortcutList::shortcutDefault( uint i ) const
+const TDEShortcut& ShortcutList::shortcutDefault( uint i ) const
{
- static KShortcut cut;
- cut = KStdAccel::shortcutDefault( g_infoStdAccel[i].id );
+ static TDEShortcut cut;
+ cut = TDEStdAccel::shortcutDefault( g_infoStdAccel[i].id );
return cut;
}
bool ShortcutList::isConfigurable( uint i ) const
{ return (g_infoStdAccel[i].id != AccelNone); }
-bool ShortcutList::setShortcut( uint i, const KShortcut& cut )
+bool ShortcutList::setShortcut( uint i, const TDEShortcut& cut )
{ g_infoStdAccel[i].cut = cut; return true; }
TQVariant ShortcutList::getOther( Other, uint ) const
diff --git a/tdecore/kstdaccel.h b/tdecore/kstdaccel.h
index 813255cc3..580204673 100644
--- a/tdecore/kstdaccel.h
+++ b/tdecore/kstdaccel.h
@@ -25,20 +25,20 @@
#include "tdelibs_export.h"
class TQKeyEvent;
-class KAccelActions;
+class TDEAccelActions;
/**
- * \namespace KStdAccel
+ * \namespace TDEStdAccel
* Convenient methods for access to the common accelerator keys in
* the key configuration. These are the standard keybindings that should
* be used in all KDE applications. They will be configurable,
* so do not hardcode the default behavior.
*
* If you want real configurable keybindings in your applications,
- * please checkout the class KAccel in kaccel.h
- * @see KAccelShortcutList
+ * please checkout the class TDEAccel in kaccel.h
+ * @see TDEAccelShortcutList
*/
-namespace KStdAccel
+namespace TDEStdAccel
{
// Always add new std-accels to the end of this enum, never in the middle!
/**
@@ -87,7 +87,7 @@ namespace KStdAccel
* Returns the keybinding for @p accel.
* @param id the id of the accelerator
*/
- TDECORE_EXPORT const KShortcut& shortcut(StdAccel id);
+ TDECORE_EXPORT const TDEShortcut& shortcut(StdAccel id);
/**
* Returns a unique name for the given accel.
@@ -126,326 +126,326 @@ namespace KStdAccel
* @param id the id of the accelerator
* @return the default shortcut of the accelerator
*/
- TDECORE_EXPORT KShortcut shortcutDefault(StdAccel id);
+ TDECORE_EXPORT TDEShortcut shortcutDefault(StdAccel id);
/**
* Returns the hardcoded default 3 modifier shortcut for @p id.
* This does not take into account the user's configuration.
* @param id the id of the accelerator
* @return the default 3 modifier shortcut
*/
- TDECORE_EXPORT KShortcut shortcutDefault3(StdAccel id);
+ TDECORE_EXPORT TDEShortcut shortcutDefault3(StdAccel id);
/**
* Returns the hardcoded default 4 modifier shortcut for @p id.
* This does not take into account the user's configuration.
* @param id the id of the accelerator
* @return the default 4 modifier shortcut
*/
- TDECORE_EXPORT KShortcut shortcutDefault4(StdAccel id);
+ TDECORE_EXPORT TDEShortcut shortcutDefault4(StdAccel id);
/**
* Open file. Default: Ctrl-o
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& open();
+ TDECORE_EXPORT const TDEShortcut& open();
/**
* Create a new document (or whatever). Default: Ctrl-n
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& openNew();
+ TDECORE_EXPORT const TDEShortcut& openNew();
/**
* Close current document. Default: Ctrl-w
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& close();
+ TDECORE_EXPORT const TDEShortcut& close();
/**
* Save current document. Default: Ctrl-s
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& save();
+ TDECORE_EXPORT const TDEShortcut& save();
/**
* Print current document. Default: Ctrl-p
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& print();
+ TDECORE_EXPORT const TDEShortcut& print();
/**
* Quit the program. Default: Ctrl-q
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& quit();
+ TDECORE_EXPORT const TDEShortcut& quit();
/**
* Undo last operation. Default: Ctrl-z
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& undo();
+ TDECORE_EXPORT const TDEShortcut& undo();
/**
* Redo. Default: Shift-Ctrl-z
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& redo();
+ TDECORE_EXPORT const TDEShortcut& redo();
/**
* Cut selected area and store it in the clipboard. Default: Ctrl-x
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& cut();
+ TDECORE_EXPORT const TDEShortcut& cut();
/**
* Copy selected area into the clipboard. Default: Ctrl-c
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& copy();
+ TDECORE_EXPORT const TDEShortcut& copy();
/**
* Paste contents of clipboard at mouse/cursor position. Default: Ctrl-v
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& paste();
+ TDECORE_EXPORT const TDEShortcut& paste();
/**
* Paste the selection at mouse/cursor position. Default: Ctrl-Shift-Insert
* @return the shortcut of the standard accelerator
* @since 3.4
*/
- TDECORE_EXPORT const KShortcut& pasteSelection();
+ TDECORE_EXPORT const TDEShortcut& pasteSelection();
/**
* Reload. Default: Ctrl-A
* @return the shortcut of the standard accelerator
**/
- TDECORE_EXPORT const KShortcut& selectAll();
+ TDECORE_EXPORT const TDEShortcut& selectAll();
/**
* Delete a word back from mouse/cursor position. Default: Ctrl-Backspace
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& deleteWordBack();
+ TDECORE_EXPORT const TDEShortcut& deleteWordBack();
/**
* Delete a word forward from mouse/cursor position. Default: Ctrl-Delete
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& deleteWordForward();
+ TDECORE_EXPORT const TDEShortcut& deleteWordForward();
/**
* Find, search. Default: Ctrl-f
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& find();
+ TDECORE_EXPORT const TDEShortcut& find();
/**
* Find/search next. Default: F3
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& findNext();
+ TDECORE_EXPORT const TDEShortcut& findNext();
/**
* Find/search previous. Default: Shift-F3
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& findPrev();
+ TDECORE_EXPORT const TDEShortcut& findPrev();
/**
* Find and replace matches. Default: Ctrl-r
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& replace();
+ TDECORE_EXPORT const TDEShortcut& replace();
/**
* Zoom in. Default: Ctrl-Plus
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& zoomIn();
+ TDECORE_EXPORT const TDEShortcut& zoomIn();
/**
* Zoom out. Default: Ctrl-Minus
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& zoomOut();
+ TDECORE_EXPORT const TDEShortcut& zoomOut();
/**
* Toggle insert/overwrite (with visual feedback, e.g. in the statusbar). Default: Insert
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& insert();
+ TDECORE_EXPORT const TDEShortcut& insert();
/**
* Goto beginning of the document. Default: Ctrl-Home
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& home();
+ TDECORE_EXPORT const TDEShortcut& home();
/**
* Goto end of the document. Default: Ctrl-End
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& end();
+ TDECORE_EXPORT const TDEShortcut& end();
/**
* Goto beginning of current line. Default: Home
* @return the shortcut of the standard accelerator
* @since 3.3
*/
- TDECORE_EXPORT const KShortcut& beginningOfLine();
+ TDECORE_EXPORT const TDEShortcut& beginningOfLine();
/**
* Goto end of current line. Default: End
* @return the shortcut of the standard accelerator
* @since 3.3
*/
- TDECORE_EXPORT const KShortcut& endOfLine();
+ TDECORE_EXPORT const TDEShortcut& endOfLine();
/**
* Scroll up one page. Default: Prior
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& prior();
+ TDECORE_EXPORT const TDEShortcut& prior();
/**
* Scroll down one page. Default: Next
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& next();
+ TDECORE_EXPORT const TDEShortcut& next();
/**
* Go to line. Default: Ctrl+G
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& gotoLine();
+ TDECORE_EXPORT const TDEShortcut& gotoLine();
/**
* Add current page to bookmarks. Default: Ctrl+B
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& addBookmark();
+ TDECORE_EXPORT const TDEShortcut& addBookmark();
/**
* Next Tab. Default: Ctrl-<
* @return the shortcut of the standard accelerator
* @since 3.2
*/
- TDECORE_EXPORT const KShortcut& tabNext();
+ TDECORE_EXPORT const TDEShortcut& tabNext();
/**
* Previous Tab. Default: Ctrl->
* @return the shortcut of the standard accelerator
* @since 3.2
*/
- TDECORE_EXPORT const KShortcut& tabPrev();
+ TDECORE_EXPORT const TDEShortcut& tabPrev();
/**
* Full Screen Mode. Default: Ctrl+Shift+F
* @return the shortcut of the standard accelerator
* @since 3.2
*/
- TDECORE_EXPORT const KShortcut& fullScreen();
+ TDECORE_EXPORT const TDEShortcut& fullScreen();
/**
* Help the user in the current situation. Default: F1
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& help();
+ TDECORE_EXPORT const TDEShortcut& help();
/**
* Complete text in input widgets. Default Ctrl+E
* @return the shortcut of the standard accelerator
**/
- TDECORE_EXPORT const KShortcut& completion();
+ TDECORE_EXPORT const TDEShortcut& completion();
/**
* Iterate through a list when completion returns
* multiple items. Default: Ctrl+Up
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& prevCompletion();
+ TDECORE_EXPORT const TDEShortcut& prevCompletion();
/**
* Iterate through a list when completion returns
* multiple items. Default: Ctrl+Down
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& nextCompletion();
+ TDECORE_EXPORT const TDEShortcut& nextCompletion();
/**
* Find a string within another string or list of strings.
* Default: Ctrl-T
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& substringCompletion();
+ TDECORE_EXPORT const TDEShortcut& substringCompletion();
/**
* Help users iterate through a list of entries. Default: Up
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& rotateUp();
+ TDECORE_EXPORT const TDEShortcut& rotateUp();
/**
* Help users iterate through a list of entries. Default: Down
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& rotateDown();
+ TDECORE_EXPORT const TDEShortcut& rotateDown();
/**
* popup a context menu. Default: Menu
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& popupMenuContext();
+ TDECORE_EXPORT const TDEShortcut& popupMenuContext();
/**
* What's This button. Default: Shift+F1
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& whatsThis();
+ TDECORE_EXPORT const TDEShortcut& whatsThis();
/**
* Reload. Default: F5
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& reload();
+ TDECORE_EXPORT const TDEShortcut& reload();
/**
* Up. Default: Alt+Up
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& up();
+ TDECORE_EXPORT const TDEShortcut& up();
/**
* Back. Default: Alt+Left
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& back();
+ TDECORE_EXPORT const TDEShortcut& back();
/**
* Forward. Default: ALT+Right
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& forward();
+ TDECORE_EXPORT const TDEShortcut& forward();
/**
* BackwardWord. Default: Ctrl+Left
* @return the shortcut of the standard accelerator
* @since 3.3
*/
- TDECORE_EXPORT const KShortcut& backwardWord();
+ TDECORE_EXPORT const TDEShortcut& backwardWord();
/**
* ForwardWord. Default: Ctrl+Right
* @return the shortcut of the standard accelerator
* @since 3.3
*/
- TDECORE_EXPORT const KShortcut& forwardWord();
+ TDECORE_EXPORT const TDEShortcut& forwardWord();
/**
* Show Menu Bar. Default: Ctrl-M
* @return the shortcut of the standard accelerator
*/
- TDECORE_EXPORT const KShortcut& showMenubar();
+ TDECORE_EXPORT const TDEShortcut& showMenubar();
#if !defined(KDE_NO_COMPAT) && !defined(__KSTDACCEL_CPP_)
/**
diff --git a/tdecore/tdeconfigdialogmanager.cpp b/tdecore/tdeconfigdialogmanager.cpp
index c488e43cb..ab5218687 100644
--- a/tdecore/tdeconfigdialogmanager.cpp
+++ b/tdecore/tdeconfigdialogmanager.cpp
@@ -95,9 +95,9 @@ void TDEConfigDialogManager::init(bool trackChanges)
// KDE
changedMap.insert( "KComboBox", TQT_SIGNAL(activated (int)));
- changedMap.insert( "KFontCombo", TQT_SIGNAL(activated (int)));
- changedMap.insert( "KFontRequester", TQT_SIGNAL(fontSelected(const TQFont &)));
- changedMap.insert( "KFontChooser", TQT_SIGNAL(fontSelected(const TQFont &)));
+ changedMap.insert( "TDEFontCombo", TQT_SIGNAL(activated (int)));
+ changedMap.insert( "TDEFontRequester", TQT_SIGNAL(fontSelected(const TQFont &)));
+ changedMap.insert( "TDEFontChooser", TQT_SIGNAL(fontSelected(const TQFont &)));
changedMap.insert( "KHistoryCombo", TQT_SIGNAL(activated (int)));
changedMap.insert( "KColorButton", TQT_SIGNAL(changed(const TQColor &)));
@@ -105,7 +105,7 @@ void TDEConfigDialogManager::init(bool trackChanges)
changedMap.insert( "KDateWidget", TQT_SIGNAL(changed (TQDate)));
changedMap.insert( "KDateTimeWidget", TQT_SIGNAL(valueChanged (const TQDateTime &)));
changedMap.insert( "KEditListBox", TQT_SIGNAL(changed()));
- changedMap.insert( "KListBox", TQT_SIGNAL(selectionChanged()));
+ changedMap.insert( "TDEListBox", TQT_SIGNAL(selectionChanged()));
changedMap.insert( "KLineEdit", TQT_SIGNAL(textChanged(const TQString &)));
changedMap.insert( "KPasswordEdit", TQT_SIGNAL(textChanged(const TQString &)));
changedMap.insert( "KRestrictedLine", TQT_SIGNAL(textChanged(const TQString &)));
diff --git a/tdecore/tests/kstdacceltest.cpp b/tdecore/tests/kstdacceltest.cpp
index 4540e89d7..a3e2d2473 100644
--- a/tdecore/tests/kstdacceltest.cpp
+++ b/tdecore/tests/kstdacceltest.cpp
@@ -26,14 +26,14 @@ int main(int argc, char *argv[])
TDEApplication::disableAutoDcopRegistration();
TDEApplication app(argc,argv,"kstdacceltest",false,false);
- check( "shortcutDefault FullScreen", KStdAccel::shortcutDefault( KStdAccel::FullScreen ).toString(), "Ctrl+Shift+F" );
- check( "shortcutDefault BeginningOfLine", KStdAccel::shortcutDefault( KStdAccel::BeginningOfLine ).toString(), "Home" );
- check( "shortcutDefault EndOfLine", KStdAccel::shortcutDefault( KStdAccel::EndOfLine ).toString(), "End" );
+ check( "shortcutDefault FullScreen", TDEStdAccel::shortcutDefault( TDEStdAccel::FullScreen ).toString(), "Ctrl+Shift+F" );
+ check( "shortcutDefault BeginningOfLine", TDEStdAccel::shortcutDefault( TDEStdAccel::BeginningOfLine ).toString(), "Home" );
+ check( "shortcutDefault EndOfLine", TDEStdAccel::shortcutDefault( TDEStdAccel::EndOfLine ).toString(), "End" );
- check( "name BeginningOfLine", KStdAccel::name( KStdAccel::BeginningOfLine ), "BeginningOfLine" );
- check( "name EndOfLine", KStdAccel::name( KStdAccel::EndOfLine ), "EndOfLine" );
+ check( "name BeginningOfLine", TDEStdAccel::name( TDEStdAccel::BeginningOfLine ), "BeginningOfLine" );
+ check( "name EndOfLine", TDEStdAccel::name( TDEStdAccel::EndOfLine ), "EndOfLine" );
- check( "shortcut method", KStdAccel::shortcut( KStdAccel::ZoomIn ).toString(), KStdAccel::zoomIn().toString() );
+ check( "shortcut method", TDEStdAccel::shortcut( TDEStdAccel::ZoomIn ).toString(), TDEStdAccel::zoomIn().toString() );
return 0;
}