summaryrefslogtreecommitdiffstats
path: root/kexi/plugins/macros/lib/macroitem.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kexi/plugins/macros/lib/macroitem.cpp')
-rw-r--r--kexi/plugins/macros/lib/macroitem.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/kexi/plugins/macros/lib/macroitem.cpp b/kexi/plugins/macros/lib/macroitem.cpp
index cf317fab..33e69c31 100644
--- a/kexi/plugins/macros/lib/macroitem.cpp
+++ b/kexi/plugins/macros/lib/macroitem.cpp
@@ -35,7 +35,7 @@ namespace KoMacro {
/**
* The @a Action this @a MacroItem has.
*/
- KSharedPtr<Action> action;
+ TDESharedPtr<Action> action;
/**
* The comment this @a MacroItem has.
@@ -109,7 +109,7 @@ namespace KoMacro {
}
MacroItem::MacroItem()
- : KShared()
+ : TDEShared()
, d( new Private() )
{
}
@@ -129,29 +129,29 @@ void MacroItem::setComment(const TQString& comment)
d->comment = comment;
}
-KSharedPtr<Action> MacroItem::action() const
+TDESharedPtr<Action> MacroItem::action() const
{
return d->action;
}
-void MacroItem::setAction(KSharedPtr<Action> action)
+void MacroItem::setAction(TDESharedPtr<Action> action)
{
d->action = action;
}
TQVariant MacroItem::variant(const TQString& name, bool checkaction) const
{
- KSharedPtr<Variable> v = variable(name, checkaction);
+ TDESharedPtr<Variable> v = variable(name, checkaction);
return v.data() ? v->variant() : TQVariant();
}
-KSharedPtr<Variable> MacroItem::variable(const TQString& name, bool checkaction) const
+TDESharedPtr<Variable> MacroItem::variable(const TQString& name, bool checkaction) const
{
if(d->variables.contains(name))
return d->variables[name];
if(checkaction && d->action.data())
return d->action->variable(name);
- return KSharedPtr<Variable>(0);
+ return TDESharedPtr<Variable>(0);
}
Variable::Map MacroItem::variables() const
@@ -163,7 +163,7 @@ bool MacroItem::setVariant(const TQString& name, const TQVariant& variant)
{
// Let's look if there is an action defined for the variable. If that's
// the case, we try to use that action to preserve the type of the variant.
- KSharedPtr<Variable> actionvariable = d->action ? d->action->variable(name) : KSharedPtr<Variable>(0);
+ TDESharedPtr<Variable> actionvariable = d->action ? d->action->variable(name) : TDESharedPtr<Variable>(0);
// If we know the expected type, we try to cast the variant to the expected
// type else the variant stays untouched (so, it will stay a string).
@@ -172,12 +172,12 @@ bool MacroItem::setVariant(const TQString& name, const TQVariant& variant)
: variant; // don't cast anything, just leave the string-type...
// Now let's try to determinate the variable which should be changed.
- KSharedPtr<Variable> variable = d->variables[name];
+ TDESharedPtr<Variable> variable = d->variables[name];
if(! variable.data()) {
// if there exists no such variable yet, create one.
kdDebug() << "MacroItem::setVariable() Creating new variable name=" << name << endl;
- variable = KSharedPtr<Variable>( new Variable() );
+ variable = TDESharedPtr<Variable>( new Variable() );
variable->setName(name);
d->variables.replace(name, variable);
}
@@ -201,11 +201,11 @@ bool MacroItem::setVariant(const TQString& name, const TQVariant& variant)
return true;
}
-KSharedPtr<Variable> MacroItem::addVariable(const TQString& name, const TQVariant& variant)
+TDESharedPtr<Variable> MacroItem::addVariable(const TQString& name, const TQVariant& variant)
{
Q_ASSERT(! d->variables.contains(name) );
// Create a new Variable.
- KSharedPtr<Variable> variable = KSharedPtr<Variable>( new Variable() );
+ TDESharedPtr<Variable> variable = TDESharedPtr<Variable>( new Variable() );
variable->setName(name);
// Put it into the Variable-map.