summaryrefslogtreecommitdiffstats
path: root/tdeui/kaction.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tdeui/kaction.cpp')
-rw-r--r--tdeui/kaction.cpp492
1 files changed, 246 insertions, 246 deletions
diff --git a/tdeui/kaction.cpp b/tdeui/kaction.cpp
index 6fad7d34b..24a940c2f 100644
--- a/tdeui/kaction.cpp
+++ b/tdeui/kaction.cpp
@@ -54,52 +54,52 @@
/**
* How it works.
-* KActionCollection is an organizing container for KActions.
-* KActionCollection keeps track of the information necessary to handle
+* TDEActionCollection is an organizing container for TDEActions.
+* TDEActionCollection keeps track of the information necessary to handle
* configuration and shortcuts.
*
* Focus Widget pointer:
* This is the widget which is the focus for action shortcuts.
-* It is set either by passing a TQWidget* to the KActionCollection constructor
+* It is set either by passing a TQWidget* to the TDEActionCollection constructor
* or by calling setWidget() if the widget wasn't known when the object was
* initially constructed (as in KXMLGUIClient and KParts::PartBase)
*
* Shortcuts:
* An action's shortcut will not not be connected unless a focus widget has
-* been specified in KActionCollection.
+* been specified in TDEActionCollection.
*
* XML Filename:
* This is used to save user-modified settings back to the *ui.rc file.
* It is set by KXMLGUIFactory.
*/
-int KAction::getToolButtonID()
+int TDEAction::getToolButtonID()
{
static int toolbutton_no = -2;
return toolbutton_no--;
}
//---------------------------------------------------------------------
-// KAction::KActionPrivate
+// TDEAction::TDEActionPrivate
//---------------------------------------------------------------------
-class KAction::KActionPrivate : public KGuiItem
+class TDEAction::TDEActionPrivate : public KGuiItem
{
public:
- KActionPrivate() : KGuiItem()
+ TDEActionPrivate() : KGuiItem()
{
m_kaccel = 0;
m_configurable = true;
}
- KAccel *m_kaccel;
- TQValueList<KAccel*> m_kaccelList;
+ TDEAccel *m_kaccel;
+ TQValueList<TDEAccel*> m_kaccelList;
TQString m_groupText;
TQString m_group;
- KShortcut m_cut;
- KShortcut m_cutDefault;
+ TDEShortcut m_cut;
+ TDEShortcut m_cutDefault;
bool m_configurable;
@@ -117,39 +117,39 @@ public:
};
//---------------------------------------------------------------------
-// KAction
+// TDEAction
//---------------------------------------------------------------------
-KAction::KAction( const TQString& text, const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TDEShortcut& cut,
const TQObject* receiver, const char* slot,
- KActionCollection* parent, const char* name )
-: TQObject( parent, name ), d(new KActionPrivate)
+ TDEActionCollection* parent, const char* name )
+: TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, receiver, slot );
}
-KAction::KAction( const TQString& text, const TQString& sIconName, const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TQString& sIconName, const TDEShortcut& cut,
const TQObject* receiver, const char* slot,
- KActionCollection* parent, const char* name )
-: TQObject( parent, name ), d(new KActionPrivate)
+ TDEActionCollection* parent, const char* name )
+: TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, receiver, slot );
d->setIconName( sIconName );
}
-KAction::KAction( const TQString& text, const TQIconSet& pix, const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TQIconSet& pix, const TDEShortcut& cut,
const TQObject* receiver, const char* slot,
- KActionCollection* parent, const char* name )
-: TQObject( parent, name ), d(new KActionPrivate)
+ TDEActionCollection* parent, const char* name )
+: TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, receiver, slot );
d->setIconSet( pix );
}
-KAction::KAction( const KGuiItem& item, const KShortcut& cut,
+TDEAction::TDEAction( const KGuiItem& item, const TDEShortcut& cut,
const TQObject* receiver, const char* slot,
- KActionCollection* parent, const char* name )
-: TQObject( parent, name ), d(new KActionPrivate)
+ TDEActionCollection* parent, const char* name )
+: TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( item.text(), cut, receiver, slot );
if( item.hasIcon() )
@@ -159,69 +159,69 @@ KAction::KAction( const KGuiItem& item, const KShortcut& cut,
}
#ifndef KDE_NO_COMPAT // KDE 4: remove
-KAction::KAction( const TQString& text, const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TDEShortcut& cut,
TQObject* parent, const char* name )
- : TQObject( parent, name ), d(new KActionPrivate)
+ : TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, 0, 0 );
}
-KAction::KAction( const TQString& text, const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TDEShortcut& cut,
const TQObject* receiver,
const char* slot, TQObject* parent, const char* name )
- : TQObject( parent, name ), d(new KActionPrivate)
+ : TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, receiver, slot );
}
-KAction::KAction( const TQString& text, const TQIconSet& pix,
- const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TQIconSet& pix,
+ const TDEShortcut& cut,
TQObject* parent, const char* name )
- : TQObject( parent, name ), d(new KActionPrivate)
+ : TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, 0, 0 );
setIconSet( pix );
}
-KAction::KAction( const TQString& text, const TQString& pix,
- const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TQString& pix,
+ const TDEShortcut& cut,
TQObject* parent, const char* name )
-: TQObject( parent, name ), d(new KActionPrivate)
+: TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, 0, 0 );
d->setIconName( pix );
}
-KAction::KAction( const TQString& text, const TQIconSet& pix,
- const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TQIconSet& pix,
+ const TDEShortcut& cut,
const TQObject* receiver, const char* slot, TQObject* parent,
const char* name )
- : TQObject( parent, name ), d(new KActionPrivate)
+ : TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, receiver, slot );
setIconSet( pix );
}
-KAction::KAction( const TQString& text, const TQString& pix,
- const KShortcut& cut,
+TDEAction::TDEAction( const TQString& text, const TQString& pix,
+ const TDEShortcut& cut,
const TQObject* receiver, const char* slot, TQObject* parent,
const char* name )
- : TQObject( parent, name ), d(new KActionPrivate)
+ : TQObject( parent, name ), d(new TDEActionPrivate)
{
initPrivate( text, cut, receiver, slot );
d->setIconName(pix);
}
-KAction::KAction( TQObject* parent, const char* name )
- : TQObject( parent, name ), d(new KActionPrivate)
+TDEAction::TDEAction( TQObject* parent, const char* name )
+ : TQObject( parent, name ), d(new TDEActionPrivate)
{
- initPrivate( TQString::null, KShortcut(), 0, 0 );
+ initPrivate( TQString::null, TDEShortcut(), 0, 0 );
}
#endif // KDE 4: remove end
-KAction::~KAction()
+TDEAction::~TDEAction()
{
- kdDebug(129) << "KAction::~KAction( this = \"" << name() << "\" )" << endl; // -- ellis
+ kdDebug(129) << "TDEAction::~TDEAction( this = \"" << name() << "\" )" << endl; // -- ellis
#ifndef KDE_NO_COMPAT
if (d->m_kaccel)
unplugAccel();
@@ -231,9 +231,9 @@ KAction::~KAction()
if ( m_parentCollection ) {
m_parentCollection->take( this );
- const TQValueList<KAccel*> & accelList = d->m_kaccelList;
- TQValueList<KAccel*>::const_iterator itr = accelList.constBegin();
- const TQValueList<KAccel*>::const_iterator itrEnd = accelList.constEnd();
+ const TQValueList<TDEAccel*> & accelList = d->m_kaccelList;
+ TQValueList<TDEAccel*>::const_iterator itr = accelList.constBegin();
+ const TQValueList<TDEAccel*>::const_iterator itrEnd = accelList.constEnd();
const char * const namePtr = name();
for (; itr != itrEnd; ++itr )
@@ -242,7 +242,7 @@ KAction::~KAction()
}
// Do not call unplugAll from here, as tempting as it sounds.
- // KAction is designed around the idea that you need to plug
+ // TDEAction is designed around the idea that you need to plug
// _and_ to unplug it "manually". Unplugging leads to an important
// slowdown when e.g. closing the window, in which case we simply
// want to destroy everything asap, not to remove actions one by one
@@ -251,13 +251,13 @@ KAction::~KAction()
delete d;
}
-void KAction::initPrivate( const TQString& text, const KShortcut& cut,
+void TDEAction::initPrivate( const TQString& text, const TDEShortcut& cut,
const TQObject* receiver, const char* slot )
{
d->m_cutDefault = cut;
- m_parentCollection = tqt_dynamic_cast<KActionCollection *>( parent() );
- kdDebug(129) << "KAction::initPrivate(): this = " << this << " name = \"" << name() << "\" cut = " << cut.toStringInternal() << " m_parentCollection = " << m_parentCollection << endl;
+ m_parentCollection = tqt_dynamic_cast<TDEActionCollection *>( parent() );
+ kdDebug(129) << "TDEAction::initPrivate(): this = " << this << " name = \"" << name() << "\" cut = " << cut.toStringInternal() << " m_parentCollection = " << m_parentCollection << endl;
if ( m_parentCollection )
m_parentCollection->insert( this );
@@ -265,28 +265,28 @@ void KAction::initPrivate( const TQString& text, const KShortcut& cut,
connect( this, TQT_SIGNAL( activated() ), receiver, slot );
if( !cut.isNull() && !qstrcmp( name(), "unnamed" ) )
- kdWarning(129) << "KAction::initPrivate(): trying to assign a shortcut (" << cut.toStringInternal() << ") to an unnamed action." << endl;
+ kdWarning(129) << "TDEAction::initPrivate(): trying to assign a shortcut (" << cut.toStringInternal() << ") to an unnamed action." << endl;
d->setText( text );
initShortcut( cut );
}
-bool KAction::isPlugged() const
+bool TDEAction::isPlugged() const
{
return (!d->m_containers.empty()) || d->m_kaccel;
}
-bool KAction::isPlugged( const TQWidget *container ) const
+bool TDEAction::isPlugged( const TQWidget *container ) const
{
return findContainer( container ) > -1;
}
-bool KAction::isPlugged( const TQWidget *container, int id ) const
+bool TDEAction::isPlugged( const TQWidget *container, int id ) const
{
int i = findContainer( container );
return ( i > -1 && itemId( i ) == id );
}
-bool KAction::isPlugged( const TQWidget *container, const TQWidget *_representative ) const
+bool TDEAction::isPlugged( const TQWidget *container, const TQWidget *_representative ) const
{
int i = findContainer( container );
return ( i > -1 && representative( i ) == _representative );
@@ -295,8 +295,8 @@ bool KAction::isPlugged( const TQWidget *container, const TQWidget *_representat
/*
Three actionCollection conditions:
- 1) Scope is known on creation and KAccel object is created (e.g. KMainWindow)
- 2) Scope is unknown and no KAccel object is available (e.g. KXMLGUIClient)
+ 1) Scope is known on creation and TDEAccel object is created (e.g. TDEMainWindow)
+ 2) Scope is unknown and no TDEAccel object is available (e.g. KXMLGUIClient)
a) addClient() will be called on object
b) we just want to add the actions to another KXMLGUIClient object
@@ -310,7 +310,7 @@ Undo and Redo should be available in both KoView objects, and
calling the undo->setEnabled() should affect both KoViews
When addClient is called, it needs to be able to find the undo and redo actions
-When it calls plug() on them, they need to be inserted into the KAccel object of the appropriate KoView
+When it calls plug() on them, they need to be inserted into the TDEAccel object of the appropriate KoView
In this case, the actionCollection belongs to KoDoc and we need to let it know that its shortcuts
have the same scope as the KoView actionCollection
@@ -325,9 +325,9 @@ View
add document actionCollection as sub-collection
A parentCollection is created
-Scenario 1: parentCollection has a focus widget set (e.g. via KMainWindow)
- A KAccel object is created in the parentCollection
- A KAction is created with parent=parentCollection
+Scenario 1: parentCollection has a focus widget set (e.g. via TDEMainWindow)
+ A TDEAccel object is created in the parentCollection
+ A TDEAction is created with parent=parentCollection
The shortcut is inserted into this actionCollection
Scenario 1a: xml isn't used
done
@@ -335,13 +335,13 @@ Scenario 1: parentCollection has a focus widget set (e.g. via KMainWindow)
setWidget is called -- ignore
shortcuts are set
Scenario 2: parentCollection has no focus widget (e.g., KParts)
- A KAction is created with parent=parentCollection
+ A TDEAction is created with parent=parentCollection
Scenario 2a: xml isn't used
no shortcuts
Scenario 2b: KXMLGUIBuilder::addClient() called
setWidget is called
- shortcuts are inserted into current KAccel
- shortcuts are set in all other KAccels, if the action is present in the other KAccels
+ shortcuts are inserted into current TDEAccel
+ shortcuts are set in all other TDEAccels, if the action is present in the other TDEAccels
*/
/*
@@ -352,21 +352,21 @@ shortcut may be set:
- on plugAccel (deprecated)
On Construction: [via initShortcut()]
- insert into KAccel of m_parentCollection,
+ insert into TDEAccel of m_parentCollection,
if kaccel() && isAutoConnectShortcuts() exists
On Plug: [via plug() -> plugShortcut()]
- insert into KAccel of m_parentCollection, if exists and not already inserted into
+ insert into TDEAccel of m_parentCollection, if exists and not already inserted into
On Read XML: [via setShortcut()]
- set in all current KAccels
- insert into KAccel of m_parentCollection, if exists and not already inserted into
+ set in all current TDEAccels
+ insert into TDEAccel of m_parentCollection, if exists and not already inserted into
*/
-KAccel* KAction::kaccelCurrent()
+TDEAccel* TDEAction::kaccelCurrent()
{
- if( m_parentCollection && m_parentCollection->builderKAccel() )
- return m_parentCollection->builderKAccel();
+ if( m_parentCollection && m_parentCollection->builderTDEAccel() )
+ return m_parentCollection->builderTDEAccel();
else if( m_parentCollection && m_parentCollection->kaccel() )
return m_parentCollection->kaccel();
else
@@ -374,55 +374,55 @@ KAccel* KAction::kaccelCurrent()
}
// Only to be called from initPrivate()
-bool KAction::initShortcut( const KShortcut& cut )
+bool TDEAction::initShortcut( const TDEShortcut& cut )
{
d->m_cut = cut;
- // Only insert action into KAccel if it has a valid name,
+ // Only insert action into TDEAccel if it has a valid name,
if( qstrcmp( name(), "unnamed" ) &&
m_parentCollection &&
m_parentCollection->isAutoConnectShortcuts() &&
m_parentCollection->kaccel() )
{
- insertKAccel( m_parentCollection->kaccel() );
+ insertTDEAccel( m_parentCollection->kaccel() );
return true;
}
return false;
}
// Only to be called from plug()
-void KAction::plugShortcut()
+void TDEAction::plugShortcut()
{
- KAccel* const kaccel = kaccelCurrent();
+ TDEAccel* const kaccel = kaccelCurrent();
- //kdDebug(129) << "KAction::plugShortcut(): this = " << this << " kaccel() = " << (m_parentCollection ? m_parentCollection->kaccel() : 0) << endl;
+ //kdDebug(129) << "TDEAction::plugShortcut(): this = " << this << " kaccel() = " << (m_parentCollection ? m_parentCollection->kaccel() : 0) << endl;
if( kaccel && qstrcmp( name(), "unnamed" ) ) {
- // Check if already plugged into current KAccel object
- const TQValueList<KAccel*> & accelList = d->m_kaccelList;
- TQValueList<KAccel*>::const_iterator itr = accelList.constBegin();
- const TQValueList<KAccel*>::const_iterator itrEnd = accelList.constEnd();
+ // Check if already plugged into current TDEAccel object
+ const TQValueList<TDEAccel*> & accelList = d->m_kaccelList;
+ TQValueList<TDEAccel*>::const_iterator itr = accelList.constBegin();
+ const TQValueList<TDEAccel*>::const_iterator itrEnd = accelList.constEnd();
for( ; itr != itrEnd; ++itr) {
if( (*itr) == kaccel )
return;
}
- insertKAccel( kaccel );
+ insertTDEAccel( kaccel );
}
}
-bool KAction::setShortcut( const KShortcut& cut )
+bool TDEAction::setShortcut( const TDEShortcut& cut )
{
bool bChanged = (d->m_cut != cut);
d->m_cut = cut;
- KAccel* const kaccel = kaccelCurrent();
+ TDEAccel* const kaccel = kaccelCurrent();
bool bInsertRequired = true;
- // Apply new shortcut to all existing KAccel objects
+ // Apply new shortcut to all existing TDEAccel objects
- const TQValueList<KAccel*> & accelList = d->m_kaccelList;
- TQValueList<KAccel*>::const_iterator itr = accelList.constBegin();
- const TQValueList<KAccel*>::const_iterator itrEnd = accelList.constEnd();
+ const TQValueList<TDEAccel*> & accelList = d->m_kaccelList;
+ TQValueList<TDEAccel*>::const_iterator itr = accelList.constBegin();
+ const TQValueList<TDEAccel*>::const_iterator itrEnd = accelList.constEnd();
for( ; itr != itrEnd; ++itr) {
// Check whether shortcut has already been plugged into
@@ -430,12 +430,12 @@ bool KAction::setShortcut( const KShortcut& cut )
if( (*itr) == kaccel )
bInsertRequired = false;
if( bChanged )
- updateKAccelShortcut( *itr );
+ updateTDEAccelShortcut( *itr );
}
- // Only insert action into KAccel if it has a valid name,
+ // Only insert action into TDEAccel if it has a valid name,
if( kaccel && bInsertRequired && qstrcmp( name(), "unnamed" ) )
- insertKAccel( kaccel );
+ insertTDEAccel( kaccel );
if( bChanged ) {
#ifndef KDE_NO_COMPAT // KDE 4: remove
@@ -449,10 +449,10 @@ bool KAction::setShortcut( const KShortcut& cut )
return true;
}
-bool KAction::updateKAccelShortcut( KAccel* kaccel )
+bool TDEAction::updateTDEAccelShortcut( TDEAccel* kaccel )
{
// Check if action is permitted
- if (kapp && !kapp->authorizeKAction(name()))
+ if (kapp && !kapp->authorizeTDEAction(name()))
return false;
bool b = true;
@@ -472,25 +472,25 @@ bool KAction::updateKAccelShortcut( KAccel* kaccel )
return b;
}
-void KAction::insertKAccel( KAccel* kaccel )
+void TDEAction::insertTDEAccel( TDEAccel* kaccel )
{
- //kdDebug(129) << "KAction::insertKAccel( " << kaccel << " ): this = " << this << endl;
+ //kdDebug(129) << "TDEAction::insertTDEAccel( " << kaccel << " ): this = " << this << endl;
if ( !kaccel->actions().actionPtr( name() ) ) {
- if( updateKAccelShortcut( kaccel ) ) {
+ if( updateTDEAccelShortcut( kaccel ) ) {
d->m_kaccelList.append( kaccel );
connect( kaccel, TQT_SIGNAL(destroyed()), this, TQT_SLOT(slotDestroyed()) );
}
}
else
- kdWarning(129) << "KAction::insertKAccel( kaccel = " << kaccel << " ): KAccel object already contains an action name \"" << name() << "\"" << endl; // -- ellis
+ kdWarning(129) << "TDEAction::insertTDEAccel( kaccel = " << kaccel << " ): TDEAccel object already contains an action name \"" << name() << "\"" << endl; // -- ellis
}
-void KAction::removeKAccel( KAccel* kaccel )
+void TDEAction::removeTDEAccel( TDEAccel* kaccel )
{
- //kdDebug(129) << "KAction::removeKAccel( " << i << " ): this = " << this << endl;
- TQValueList<KAccel*> & accelList = d->m_kaccelList;
- TQValueList<KAccel*>::iterator itr = accelList.begin();
- const TQValueList<KAccel*>::iterator itrEnd = accelList.end();
+ //kdDebug(129) << "TDEAction::removeTDEAccel( " << i << " ): this = " << this << endl;
+ TQValueList<TDEAccel*> & accelList = d->m_kaccelList;
+ TQValueList<TDEAccel*>::iterator itr = accelList.begin();
+ const TQValueList<TDEAccel*>::iterator itrEnd = accelList.end();
for( ; itr != itrEnd; ++itr) {
if( (*itr) == kaccel ) {
@@ -504,13 +504,13 @@ void KAction::removeKAccel( KAccel* kaccel )
#ifndef KDE_NO_COMPAT
// KDE 4: remove
-void KAction::setAccel( int keyQt )
+void TDEAction::setAccel( int keyQt )
{
- setShortcut( KShortcut(keyQt) );
+ setShortcut( TDEShortcut(keyQt) );
}
#endif // KDE 4: remove end
-void KAction::updateShortcut( int i )
+void TDEAction::updateShortcut( int i )
{
int id = itemId( i );
@@ -523,10 +523,10 @@ void KAction::updateShortcut( int i )
static_cast<TQMenuBar*>(w)->setAccel( d->m_cut.keyCodeQt(), id );
}
-void KAction::updateShortcut( TQPopupMenu* menu, int id )
+void TDEAction::updateShortcut( TQPopupMenu* menu, int id )
{
- //kdDebug(129) << "KAction::updateShortcut(): this = " << this << " d->m_kaccelList.count() = " << d->m_kaccelList.count() << endl;
- // If the action has a KAccel object,
+ //kdDebug(129) << "TDEAction::updateShortcut(): this = " << this << " d->m_kaccelList.count() = " << d->m_kaccelList.count() << endl;
+ // If the action has a TDEAccel object,
// show the string representation of its shortcut.
if ( d->m_kaccel || d->m_kaccelList.count() ) {
TQString s = menu->text( id );
@@ -540,41 +540,41 @@ void KAction::updateShortcut( TQPopupMenu* menu, int id )
}
// Otherwise insert the shortcut itself into the popup menu.
else {
- // This is a fall-hack in case the KAction is missing a proper parent collection.
+ // This is a fall-hack in case the TDEAction is missing a proper parent collection.
// It should be removed eventually. --ellis
menu->setAccel( d->m_cut.keyCodeQt(), id );
- kdDebug(129) << "KAction::updateShortcut(): name = \"" << name() << "\", cut = " << d->m_cut.toStringInternal() << "; No KAccel, probably missing a parent collection." << endl;
+ kdDebug(129) << "TDEAction::updateShortcut(): name = \"" << name() << "\", cut = " << d->m_cut.toStringInternal() << "; No TDEAccel, probably missing a parent collection." << endl;
}
}
-const KShortcut& KAction::shortcut() const
+const TDEShortcut& TDEAction::shortcut() const
{
return d->m_cut;
}
-const KShortcut& KAction::shortcutDefault() const
+const TDEShortcut& TDEAction::shortcutDefault() const
{
return d->m_cutDefault;
}
-TQString KAction::shortcutText() const
+TQString TDEAction::shortcutText() const
{
return d->m_cut.toStringInternal();
}
-void KAction::setShortcutText( const TQString& s )
+void TDEAction::setShortcutText( const TQString& s )
{
- setShortcut( KShortcut(s) );
+ setShortcut( TDEShortcut(s) );
}
#ifndef KDE_NO_COMPAT // Remove in KDE 4
-int KAction::accel() const
+int TDEAction::accel() const
{
return d->m_cut.keyCodeQt();
}
#endif
-void KAction::setGroup( const TQString& grp )
+void TDEAction::setGroup( const TQString& grp )
{
d->m_group = grp;
@@ -583,27 +583,27 @@ void KAction::setGroup( const TQString& grp )
updateGroup( i );
}
-void KAction::updateGroup( int )
+void TDEAction::updateGroup( int )
{
// DO SOMETHING
}
-TQString KAction::group() const
+TQString TDEAction::group() const
{
return d->m_group;
}
-bool KAction::isEnabled() const
+bool TDEAction::isEnabled() const
{
return d->isEnabled();
}
-bool KAction::isShortcutConfigurable() const
+bool TDEAction::isShortcutConfigurable() const
{
return d->m_configurable;
}
-void KAction::setToolTip( const TQString& tt )
+void TDEAction::setToolTip( const TQString& tt )
{
d->setToolTip( tt );
@@ -612,39 +612,39 @@ void KAction::setToolTip( const TQString& tt )
updateToolTip( i );
}
-void KAction::updateToolTip( int i )
+void TDEAction::updateToolTip( int i )
{
TQWidget *w = container( i );
- if ( ::tqqt_cast<KToolBar *>( w ) )
- TQToolTip::add( static_cast<KToolBar*>(w)->getWidget( itemId( i ) ), d->toolTip() );
+ if ( ::tqqt_cast<TDEToolBar *>( w ) )
+ TQToolTip::add( static_cast<TDEToolBar*>(w)->getWidget( itemId( i ) ), d->toolTip() );
}
-TQString KAction::toolTip() const
+TQString TDEAction::toolTip() const
{
return d->toolTip();
}
-int KAction::plug( TQWidget *w, int index )
+int TDEAction::plug( TQWidget *w, int index )
{
- //kdDebug(129) << "KAction::plug( " << w << ", " << index << " )" << endl;
+ //kdDebug(129) << "TDEAction::plug( " << w << ", " << index << " )" << endl;
if (!w ) {
- kdWarning(129) << "KAction::plug called with 0 argument\n";
+ kdWarning(129) << "TDEAction::plug called with 0 argument\n";
return -1;
}
- // Ellis: print warning if there is a shortcut, but no KAccel available (often due to no widget available in the actioncollection)
+ // Ellis: print warning if there is a shortcut, but no TDEAccel available (often due to no widget available in the actioncollection)
// David: Well, it doesn't matter much, things still work (e.g. Undo in koffice) via TQAccel.
- // We should probably re-enable the warning for things that only KAccel can do, though - e.g. WIN key (mapped to Meta).
+ // We should probably re-enable the warning for things that only TDEAccel can do, though - e.g. WIN key (mapped to Meta).
#if 0 //ndef NDEBUG
- KAccel* kaccel = kaccelCurrent();
+ TDEAccel* kaccel = kaccelCurrent();
if( !d->m_cut.isNull() && !kaccel ) {
- kdDebug(129) << "KAction::plug(): has no KAccel object; this = " << this << " name = " << name() << " parentCollection = " << m_parentCollection << endl; // ellis
+ kdDebug(129) << "TDEAction::plug(): has no TDEAccel object; this = " << this << " name = " << name() << " parentCollection = " << m_parentCollection << endl; // ellis
}
#endif
// Check if action is permitted
- if (kapp && !kapp->authorizeKAction(name()))
+ if (kapp && !kapp->authorizeTDEAction(name()))
return -1;
plugShortcut();
@@ -653,7 +653,7 @@ int KAction::plug( TQWidget *w, int index )
{
TQPopupMenu* menu = static_cast<TQPopupMenu*>( w );
int id;
- // Don't insert shortcut into menu if it's already in a KAccel object.
+ // Don't insert shortcut into menu if it's already in a TDEAccel object.
int keyQt = (d->m_kaccelList.count() || d->m_kaccel) ? 0 : d->m_cut.keyCodeQt();
if ( d->hasIcon() )
@@ -672,7 +672,7 @@ int KAction::plug( TQWidget *w, int index )
TQT_SLOT( slotPopupActivated() ),
keyQt, -1, index );
- // If the shortcut is already in a KAccel object, then
+ // If the shortcut is already in a TDEAccel object, then
// we need to set the menu item's shortcut text.
if ( d->m_kaccelList.count() || d->m_kaccel )
updateShortcut( menu, id );
@@ -693,9 +693,9 @@ int KAction::plug( TQWidget *w, int index )
return d->m_containers.count() - 1;
}
- else if ( ::tqqt_cast<KToolBar *>( w ) )
+ else if ( ::tqqt_cast<TDEToolBar *>( w ) )
{
- KToolBar *bar = static_cast<KToolBar *>( w );
+ TDEToolBar *bar = static_cast<TDEToolBar *>( w );
int id_ = getToolButtonID();
TDEInstance *instance;
@@ -720,7 +720,7 @@ int KAction::plug( TQWidget *w, int index )
d->isEnabled(), d->plainText(), index, instance );
}
- KToolBarButton* ktb = bar->getButton(id_);
+ TDEToolBarButton* ktb = bar->getButton(id_);
ktb->setName( TQCString("toolbutton_")+name() );
if ( !d->whatsThis().isEmpty() )
@@ -742,7 +742,7 @@ int KAction::plug( TQWidget *w, int index )
return -1;
}
-void KAction::unplug( TQWidget *w )
+void TDEAction::unplug( TQWidget *w )
{
int i = findContainer( w );
if ( i == -1 )
@@ -754,9 +754,9 @@ void KAction::unplug( TQWidget *w )
TQPopupMenu *menu = static_cast<TQPopupMenu *>( w );
menu->removeItem( id );
}
- else if ( ::tqqt_cast<KToolBar *>( w ) )
+ else if ( ::tqqt_cast<TDEToolBar *>( w ) )
{
- KToolBar *bar = static_cast<KToolBar *>( w );
+ TDEToolBar *bar = static_cast<TDEToolBar *>( w );
bar->removeItemDelayed( id );
}
else if ( ::tqqt_cast<TQMenuBar *>( w ) )
@@ -770,11 +770,11 @@ void KAction::unplug( TQWidget *w )
m_parentCollection->disconnectHighlight( w, this );
}
-void KAction::plugAccel(KAccel *kacc, bool configurable)
+void TDEAction::plugAccel(TDEAccel *kacc, bool configurable)
{
- kdWarning(129) << "KAction::plugAccel(): call to deprecated action." << endl;
+ kdWarning(129) << "TDEAction::plugAccel(): call to deprecated action." << endl;
kdDebug(129) << kdBacktrace() << endl;
- //kdDebug(129) << "KAction::plugAccel( kacc = " << kacc << " ): name \"" << name() << "\"" << endl;
+ //kdDebug(129) << "TDEAction::plugAccel( kacc = " << kacc << " ): name \"" << name() << "\"" << endl;
if ( d->m_kaccel )
unplugAccel();
@@ -782,25 +782,25 @@ void KAction::plugAccel(KAccel *kacc, bool configurable)
//if ( m_parentCollection && !m_parentCollection->accel() )
// m_parentCollection->setAccel( kacc );
- // We can only plug this action into the given KAccel object
+ // We can only plug this action into the given TDEAccel object
// if it does not already contain an action with the same name.
if ( !kacc->actions().actionPtr(name()) )
{
d->m_kaccel = kacc;
d->m_kaccel->insert(name(), d->plainText(), TQString::null,
- KShortcut(d->m_cut),
+ TDEShortcut(d->m_cut),
this, TQT_SLOT(slotActivated()),
configurable, isEnabled());
connect(d->m_kaccel, TQT_SIGNAL(destroyed()), this, TQT_SLOT(slotDestroyed()));
//connect(d->m_kaccel, TQT_SIGNAL(keycodeChanged()), this, TQT_SLOT(slotKeycodeChanged()));
}
else
- kdWarning(129) << "KAction::plugAccel( kacc = " << kacc << " ): KAccel object already contains an action name \"" << name() << "\"" << endl; // -- ellis
+ kdWarning(129) << "TDEAction::plugAccel( kacc = " << kacc << " ): TDEAccel object already contains an action name \"" << name() << "\"" << endl; // -- ellis
}
-void KAction::unplugAccel()
+void TDEAction::unplugAccel()
{
- //kdDebug(129) << "KAction::unplugAccel() " << this << " " << name() << endl;
+ //kdDebug(129) << "TDEAction::unplugAccel() " << this << " " << name() << endl;
if ( d->m_kaccel )
{
d->m_kaccel->remove(name());
@@ -808,7 +808,7 @@ void KAction::unplugAccel()
}
}
-void KAction::plugMainWindowAccel( TQWidget *w )
+void TDEAction::plugMainWindowAccel( TQWidget *w )
{
// Note: topLevelWidget() stops too early, we can't use it.
TQWidget * tl = w;
@@ -816,16 +816,16 @@ void KAction::plugMainWindowAccel( TQWidget *w )
while ( !tl->isDialog() && ( n = tl->parentWidget() ) ) // lookup parent and store
tl = n;
- KMainWindow * mw = tqt_dynamic_cast<KMainWindow *>(tl); // try to see if it's a kmainwindow
+ TDEMainWindow * mw = tqt_dynamic_cast<TDEMainWindow *>(tl); // try to see if it's a kmainwindow
if (mw)
plugAccel( mw->accel() );
else
- kdDebug(129) << "KAction::plugMainWindowAccel: Toplevel widget isn't a KMainWindow, can't plug accel. " << tl << endl;
+ kdDebug(129) << "TDEAction::plugMainWindowAccel: Toplevel widget isn't a TDEMainWindow, can't plug accel. " << tl << endl;
}
-void KAction::setEnabled(bool enable)
+void TDEAction::setEnabled(bool enable)
{
- //kdDebug(129) << "KAction::setEnabled( " << enable << " ): this = " << this << " d->m_kaccelList.count() = " << d->m_kaccelList.count() << endl;
+ //kdDebug(129) << "TDEAction::setEnabled( " << enable << " ): this = " << this << " d->m_kaccelList.count() = " << d->m_kaccelList.count() << endl;
if ( enable == d->isEnabled() )
return;
@@ -835,9 +835,9 @@ void KAction::setEnabled(bool enable)
d->m_kaccel->setEnabled(name(), enable);
#endif // KDE 4: remove end
- const TQValueList<KAccel*> & accelList = d->m_kaccelList;
- TQValueList<KAccel*>::const_iterator itr = accelList.constBegin();
- const TQValueList<KAccel*>::const_iterator itrEnd = accelList.constEnd();
+ const TQValueList<TDEAccel*> & accelList = d->m_kaccelList;
+ TQValueList<TDEAccel*>::const_iterator itr = accelList.constBegin();
+ const TQValueList<TDEAccel*>::const_iterator itrEnd = accelList.constEnd();
const char * const namePtr = name();
@@ -853,7 +853,7 @@ void KAction::setEnabled(bool enable)
emit enabled( d->isEnabled() );
}
-void KAction::updateEnabled( int i )
+void TDEAction::updateEnabled( int i )
{
TQWidget *w = container( i );
@@ -861,33 +861,33 @@ void KAction::updateEnabled( int i )
static_cast<TQPopupMenu*>(w)->setItemEnabled( itemId( i ), d->isEnabled() );
else if ( ::tqqt_cast<TQMenuBar *>( w ) )
static_cast<TQMenuBar*>(w)->setItemEnabled( itemId( i ), d->isEnabled() );
- else if ( ::tqqt_cast<KToolBar *>( w ) )
- static_cast<KToolBar*>(w)->setItemEnabled( itemId( i ), d->isEnabled() );
+ else if ( ::tqqt_cast<TDEToolBar *>( w ) )
+ static_cast<TDEToolBar*>(w)->setItemEnabled( itemId( i ), d->isEnabled() );
}
-void KAction::setShortcutConfigurable( bool b )
+void TDEAction::setShortcutConfigurable( bool b )
{
d->m_configurable = b;
}
-void KAction::setText( const TQString& text )
+void TDEAction::setText( const TQString& text )
{
#ifndef KDE_NO_COMPAT
// KDE 4: remove
if (d->m_kaccel) {
- KAccelAction* pAction = d->m_kaccel->actions().actionPtr(name());
+ TDEAccelAction* pAction = d->m_kaccel->actions().actionPtr(name());
if (pAction)
pAction->setLabel( text );
}
#endif // KDE 4: remove end
- const TQValueList<KAccel*> & accelList = d->m_kaccelList;
- TQValueList<KAccel*>::const_iterator itr = accelList.constBegin();
- const TQValueList<KAccel*>::const_iterator itrEnd = accelList.constEnd();
+ const TQValueList<TDEAccel*> & accelList = d->m_kaccelList;
+ TQValueList<TDEAccel*>::const_iterator itr = accelList.constBegin();
+ const TQValueList<TDEAccel*>::const_iterator itrEnd = accelList.constEnd();
const char * const namePtr = name();
for( ; itr != itrEnd; ++itr ) {
- KAccelAction* const pAction = (*itr)->actions().actionPtr(namePtr);
+ TDEAccelAction* const pAction = (*itr)->actions().actionPtr(namePtr);
if (pAction)
pAction->setLabel( text );
}
@@ -899,7 +899,7 @@ void KAction::setText( const TQString& text )
updateText( i );
}
-void KAction::updateText( int i )
+void TDEAction::updateText( int i )
{
TQWidget *w = container( i );
@@ -911,25 +911,25 @@ void KAction::updateText( int i )
}
else if ( ::tqqt_cast<TQMenuBar *>( w ) )
static_cast<TQMenuBar*>(w)->changeItem( itemId( i ), d->text() );
- else if ( ::tqqt_cast<KToolBar *>( w ) )
+ else if ( ::tqqt_cast<TDEToolBar *>( w ) )
{
- TQWidget *button = static_cast<KToolBar *>(w)->getWidget( itemId( i ) );
- if ( ::tqqt_cast<KToolBarButton *>( button ) )
- static_cast<KToolBarButton *>(button)->setText( d->plainText() );
+ TQWidget *button = static_cast<TDEToolBar *>(w)->getWidget( itemId( i ) );
+ if ( ::tqqt_cast<TDEToolBarButton *>( button ) )
+ static_cast<TDEToolBarButton *>(button)->setText( d->plainText() );
}
}
-TQString KAction::text() const
+TQString TDEAction::text() const
{
return d->text();
}
-TQString KAction::plainText() const
+TQString TDEAction::plainText() const
{
return d->plainText( );
}
-void KAction::setIcon( const TQString &icon )
+void TDEAction::setIcon( const TQString &icon )
{
d->setIconName( icon );
@@ -939,7 +939,7 @@ void KAction::setIcon( const TQString &icon )
updateIcon( i );
}
-void KAction::updateIcon( int id )
+void TDEAction::updateIcon( int id )
{
TQWidget* w = container( id );
@@ -951,16 +951,16 @@ void KAction::updateIcon( int id )
}
else if ( ::tqqt_cast<TQMenuBar *>( w ) )
static_cast<TQMenuBar*>(w)->changeItem( itemId( id ), d->iconSet( KIcon::Small ), d->text() );
- else if ( ::tqqt_cast<KToolBar *>( w ) )
- static_cast<KToolBar *>(w)->setButtonIcon( itemId( id ), d->iconName() );
+ else if ( ::tqqt_cast<TDEToolBar *>( w ) )
+ static_cast<TDEToolBar *>(w)->setButtonIcon( itemId( id ), d->iconName() );
}
-TQString KAction::icon() const
+TQString TDEAction::icon() const
{
return d->iconName( );
}
-void KAction::setIconSet( const TQIconSet &iconset )
+void TDEAction::setIconSet( const TQIconSet &iconset )
{
d->setIconSet( iconset );
@@ -970,7 +970,7 @@ void KAction::setIconSet( const TQIconSet &iconset )
}
-void KAction::updateIconSet( int id )
+void TDEAction::updateIconSet( int id )
{
TQWidget *w = container( id );
@@ -983,26 +983,26 @@ void KAction::updateIconSet( int id )
}
else if ( ::tqqt_cast<TQMenuBar *>( w ) )
static_cast<TQMenuBar*>(w)->changeItem( itemId( id ), d->iconSet(), d->text() );
- else if ( ::tqqt_cast<KToolBar *>( w ) )
+ else if ( ::tqqt_cast<TDEToolBar *>( w ) )
{
if ( icon().isEmpty() && d->hasIcon() ) // only if there is no named icon ( scales better )
- static_cast<KToolBar *>(w)->setButtonIconSet( itemId( id ), d->iconSet() );
+ static_cast<TDEToolBar *>(w)->setButtonIconSet( itemId( id ), d->iconSet() );
else
- static_cast<KToolBar *>(w)->setButtonIconSet( itemId( id ), d->iconSet( KIcon::Small ) );
+ static_cast<TDEToolBar *>(w)->setButtonIconSet( itemId( id ), d->iconSet( KIcon::Small ) );
}
}
-TQIconSet KAction::iconSet( KIcon::Group group, int size ) const
+TQIconSet TDEAction::iconSet( KIcon::Group group, int size ) const
{
return d->iconSet( group, size );
}
-bool KAction::hasIcon() const
+bool TDEAction::hasIcon() const
{
return d->hasIcon();
}
-void KAction::setWhatsThis( const TQString& text )
+void TDEAction::setWhatsThis( const TQString& text )
{
d->setWhatsThis( text );
@@ -1011,7 +1011,7 @@ void KAction::setWhatsThis( const TQString& text )
updateWhatsThis( i );
}
-void KAction::updateWhatsThis( int i )
+void TDEAction::updateWhatsThis( int i )
{
TQPopupMenu* pm = popupMenu( i );
if ( pm )
@@ -1020,7 +1020,7 @@ void KAction::updateWhatsThis( int i )
return;
}
- KToolBar *tb = toolBar( i );
+ TDEToolBar *tb = toolBar( i );
if ( tb )
{
TQWidget *w = tb->getButton( itemId( i ) );
@@ -1030,12 +1030,12 @@ void KAction::updateWhatsThis( int i )
}
}
-TQString KAction::whatsThis() const
+TQString TDEAction::whatsThis() const
{
return d->whatsThis();
}
-TQString KAction::whatsThisWithIcon() const
+TQString TDEAction::whatsThisWithIcon() const
{
TQString text = whatsThis();
if (!d->iconName().isEmpty())
@@ -1043,80 +1043,80 @@ TQString KAction::whatsThisWithIcon() const
return text;
}
-TQWidget* KAction::container( int index ) const
+TQWidget* TDEAction::container( int index ) const
{
assert( index < containerCount() );
return d->m_containers[ index ].m_container;
}
-KToolBar* KAction::toolBar( int index ) const
+TDEToolBar* TDEAction::toolBar( int index ) const
{
- return tqt_dynamic_cast<KToolBar *>( d->m_containers[ index ].m_container );
+ return tqt_dynamic_cast<TDEToolBar *>( d->m_containers[ index ].m_container );
}
-TQPopupMenu* KAction::popupMenu( int index ) const
+TQPopupMenu* TDEAction::popupMenu( int index ) const
{
return tqt_dynamic_cast<TQPopupMenu *>( d->m_containers[ index ].m_container );
}
-TQWidget* KAction::representative( int index ) const
+TQWidget* TDEAction::representative( int index ) const
{
return d->m_containers[ index ].m_representative;
}
-int KAction::itemId( int index ) const
+int TDEAction::itemId( int index ) const
{
return d->m_containers[ index ].m_id;
}
-int KAction::containerCount() const
+int TDEAction::containerCount() const
{
return d->m_containers.count();
}
-uint KAction::kaccelCount() const
+uint TDEAction::kaccelCount() const
{
return d->m_kaccelList.count();
}
-void KAction::addContainer( TQWidget* c, int id )
+void TDEAction::addContainer( TQWidget* c, int id )
{
- KActionPrivate::Container p;
+ TDEActionPrivate::Container p;
p.m_container = c;
p.m_id = id;
d->m_containers.append( p );
}
-void KAction::addContainer( TQWidget* c, TQWidget* w )
+void TDEAction::addContainer( TQWidget* c, TQWidget* w )
{
- KActionPrivate::Container p;
+ TDEActionPrivate::Container p;
p.m_container = c;
p.m_representative = w;
d->m_containers.append( p );
}
-void KAction::activate()
+void TDEAction::activate()
{
- emit activated( KAction::EmulatedActivation, Qt::NoButton );
+ emit activated( TDEAction::EmulatedActivation, Qt::NoButton );
slotActivated();
}
-void KAction::slotActivated()
+void TDEAction::slotActivated()
{
const TQObject *senderObj = TQT_TQOBJECT_CONST(sender());
if ( senderObj )
{
- if ( ::tqqt_cast<KAccelPrivate *>( senderObj ) )
- emit activated( KAction::AccelActivation, Qt::NoButton );
+ if ( ::tqqt_cast<TDEAccelPrivate *>( senderObj ) )
+ emit activated( TDEAction::AccelActivation, Qt::NoButton );
}
emit activated();
}
-// This catches signals emitted by KActions inserted into QPopupMenu
+// This catches signals emitted by TDEActions inserted into QPopupMenu
// We do crude things inside it, because we need to know which
// TQPopupMenu emitted the signal. We need to be sure that it is
// only called by QPopupMenus, we plugged us in.
-void KAction::slotPopupActivated()
+void TDEAction::slotPopupActivated()
{
if( ::tqqt_cast<TQSignal *>(sender()))
{
@@ -1127,30 +1127,30 @@ void KAction::slotPopupActivated()
TQPopupMenu* qpm = tqt_dynamic_cast<TQPopupMenu *>( container(pos) );
if(qpm)
{
- KPopupMenu* kpm = tqt_dynamic_cast<KPopupMenu *>( qpm );
+ TDEPopupMenu* kpm = tqt_dynamic_cast<TDEPopupMenu *>( qpm );
TQt::ButtonState state;
- if ( kpm ) // KPopupMenu? Nice, it stores the state.
+ if ( kpm ) // TDEPopupMenu? Nice, it stores the state.
state = kpm->state();
else { // just a QPopupMenu? We'll ask for the state now then (small race condition?)
- kdDebug(129) << "KAction::slotPopupActivated not a KPopupMenu -> using keyboardMouseState()" << endl;
+ kdDebug(129) << "TDEAction::slotPopupActivated not a TDEPopupMenu -> using keyboardMouseState()" << endl;
state = TDEApplication::keyboardMouseState();
}
- emit activated( KAction::PopupMenuActivation, state );
+ emit activated( TDEAction::PopupMenuActivation, state );
slotActivated();
return;
}
}
}
- kdWarning(129)<<"Don't connect KAction::slotPopupActivated() to anything, expect into QPopupMenus which are in containers. Use slotActivated instead."<<endl;
- emit activated( KAction::PopupMenuActivation, Qt::NoButton );
+ kdWarning(129)<<"Don't connect TDEAction::slotPopupActivated() to anything, expect into QPopupMenus which are in containers. Use slotActivated instead."<<endl;
+ emit activated( TDEAction::PopupMenuActivation, Qt::NoButton );
slotActivated();
}
-void KAction::slotButtonClicked( int, TQt::ButtonState state )
+void TDEAction::slotButtonClicked( int, TQt::ButtonState state )
{
kdDebug(129) << "slotButtonClicked() state=" << state << endl;
- emit activated( KAction::ToolBarActivation, state );
+ emit activated( TDEAction::ToolBarActivation, state );
// RightButton isn't really an activation
if ( ( state & Qt::LeftButton ) || ( state & Qt::MidButton ) )
@@ -1158,9 +1158,9 @@ void KAction::slotButtonClicked( int, TQt::ButtonState state )
}
-void KAction::slotDestroyed()
+void TDEAction::slotDestroyed()
{
- kdDebug(129) << "KAction::slotDestroyed(): this = " << this << ", name = \"" << name() << "\", sender = " << sender() << endl;
+ kdDebug(129) << "TDEAction::slotDestroyed(): this = " << this << ", name = \"" << name() << "\", sender = " << sender() << endl;
const TQObject* const o = TQT_TQOBJECT_CONST(sender());
#ifndef KDE_NO_COMPAT // KDE 4: remove
@@ -1170,9 +1170,9 @@ void KAction::slotDestroyed()
return;
}
#endif // KDE 4: remove end
- TQValueList<KAccel*> & accelList = d->m_kaccelList;
- TQValueList<KAccel*>::iterator itr = accelList.begin();
- const TQValueList<KAccel*>::iterator itrEnd = accelList.end();
+ TQValueList<TDEAccel*> & accelList = d->m_kaccelList;
+ TQValueList<TDEAccel*>::iterator itr = accelList.begin();
+ const TQValueList<TDEAccel*>::iterator itrEnd = accelList.end();
for( ; itr != itrEnd; ++itr)
{
@@ -1193,14 +1193,14 @@ void KAction::slotDestroyed()
} while ( i != -1 );
}
-int KAction::findContainer( const TQWidget* widget ) const
+int TDEAction::findContainer( const TQWidget* widget ) const
{
int pos = 0;
- const TQValueList<KActionPrivate::Container> & containers = d->m_containers;
+ const TQValueList<TDEActionPrivate::Container> & containers = d->m_containers;
- TQValueList<KActionPrivate::Container>::ConstIterator it = containers.constBegin();
- const TQValueList<KActionPrivate::Container>::ConstIterator itEnd = containers.constEnd();
+ TQValueList<TDEActionPrivate::Container>::ConstIterator it = containers.constBegin();
+ const TQValueList<TDEActionPrivate::Container>::ConstIterator itEnd = containers.constEnd();
while( it != itEnd )
{
@@ -1213,14 +1213,14 @@ int KAction::findContainer( const TQWidget* widget ) const
return -1;
}
-int KAction::findContainer( const int id ) const
+int TDEAction::findContainer( const int id ) const
{
int pos = 0;
- const TQValueList<KActionPrivate::Container> & containers = d->m_containers;
+ const TQValueList<TDEActionPrivate::Container> & containers = d->m_containers;
- TQValueList<KActionPrivate::Container>::ConstIterator it = containers.constBegin();
- const TQValueList<KActionPrivate::Container>::ConstIterator itEnd = containers.constEnd();
+ TQValueList<TDEActionPrivate::Container>::ConstIterator it = containers.constBegin();
+ const TQValueList<TDEActionPrivate::Container>::ConstIterator itEnd = containers.constEnd();
while( it != itEnd )
{
@@ -1233,14 +1233,14 @@ int KAction::findContainer( const int id ) const
return -1;
}
-void KAction::removeContainer( int index )
+void TDEAction::removeContainer( int index )
{
int i = 0;
- TQValueList<KActionPrivate::Container> & containers = d->m_containers;
+ TQValueList<TDEActionPrivate::Container> & containers = d->m_containers;
- TQValueList<KActionPrivate::Container>::Iterator it = containers.begin();
- const TQValueList<KActionPrivate::Container>::Iterator itEnd = containers.end();
+ TQValueList<TDEActionPrivate::Container>::Iterator it = containers.begin();
+ const TQValueList<TDEActionPrivate::Container>::Iterator itEnd = containers.end();
while( it != itEnd )
{
@@ -1255,31 +1255,31 @@ void KAction::removeContainer( int index )
}
// FIXME: Remove this (ellis)
-void KAction::slotKeycodeChanged()
+void TDEAction::slotKeycodeChanged()
{
- kdDebug(129) << "KAction::slotKeycodeChanged()" << endl; // -- ellis
- KAccelAction* pAction = d->m_kaccel->actions().actionPtr(name());
+ kdDebug(129) << "TDEAction::slotKeycodeChanged()" << endl; // -- ellis
+ TDEAccelAction* pAction = d->m_kaccel->actions().actionPtr(name());
if( pAction )
setShortcut(pAction->shortcut());
}
-KActionCollection *KAction::parentCollection() const
+TDEActionCollection *TDEAction::parentCollection() const
{
return m_parentCollection;
}
-void KAction::unplugAll()
+void TDEAction::unplugAll()
{
while ( containerCount() != 0 )
unplug( container( 0 ) );
}
-const KGuiItem& KAction::guiItem() const
+const KGuiItem& TDEAction::guiItem() const
{
return *d;
}
-void KAction::virtual_hook( int, void* )
+void TDEAction::virtual_hook( int, void* )
{ /*BASE::virtual_hook( id, data );*/ }
/* vim: et sw=2 ts=2