summaryrefslogtreecommitdiffstats
path: root/kplato/kptproject.cc
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 22:19:39 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 22:19:39 +0000
commit04766b207afba7961d4d802313e426f5a2fbef63 (patch)
treec888ea1027c793e2d0386a7e5a1a0cd077b03cb3 /kplato/kptproject.cc
parentb6edfe41c9395f2e20784cbf0e630af6426950a3 (diff)
downloadkoffice-04766b207afba7961d4d802313e426f5a2fbef63.tar.gz
koffice-04766b207afba7961d4d802313e426f5a2fbef63.zip
rename the following methods:
tqparent parent tqmask mask git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1246260 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kplato/kptproject.cc')
-rw-r--r--kplato/kptproject.cc64
1 files changed, 32 insertions, 32 deletions
diff --git a/kplato/kptproject.cc b/kplato/kptproject.cc
index d06c5e51..9379de4a 100644
--- a/kplato/kptproject.cc
+++ b/kplato/kptproject.cc
@@ -42,8 +42,8 @@ namespace KPlato
{
-Project::Project(Node *tqparent)
- : Node(tqparent),
+Project::Project(Node *parent)
+ : Node(parent),
m_accounts(*this),
m_baselined(false) {
//kdDebug()<<k_funcinfo<<"("<<this<<")"<<endl;
@@ -55,7 +55,7 @@ Project::Project(Node *tqparent)
void Project::init() {
if (m_parent == 0) {
- // set sensible defaults for a project wo tqparent
+ // set sensible defaults for a project wo parent
m_constraintStartTime = TQDateTime(TQDate::tqcurrentDate(), TQTime());
m_constraintEndTime = TQDateTime(m_constraintStartTime.addDays(1));
}
@@ -173,7 +173,7 @@ Duration *Project::getRandomDuration() {
DateTime Project::calculateForward(int use) {
//kdDebug()<<k_funcinfo<<m_name<<endl;
if (type() == Node::Type_Project) {
- // Follow *tqparent* relations back and
+ // Follow *parent* relations back and
// calculate forwards following the child relations
DateTime finish;
DateTime time;
@@ -195,7 +195,7 @@ DateTime Project::calculateBackward(int use) {
//kdDebug()<<k_funcinfo<<m_name<<endl;
if (type() == Node::Type_Project) {
// Follow *child* relations back and
- // calculate backwards following tqparent relation
+ // calculate backwards following parent relation
DateTime start;
DateTime time;
TQPtrListIterator<Node> startnodes = m_startNodes;
@@ -441,7 +441,7 @@ bool Project::load(TQDomElement &element) {
TQPtrListIterator<Calendar> calit(m_calendars);
for (; calit.current(); ++calit) {
if (calit.current()->id() == calit.current()->parentId()) {
- kdError()<<k_funcinfo<<"Calendar want itself as tqparent"<<endl;
+ kdError()<<k_funcinfo<<"Calendar want itself as parent"<<endl;
continue;
}
calit.current()->setParent(calendar(calit.current()->parentId()));
@@ -491,7 +491,7 @@ void Project::save(TQDomElement &element) const {
git.current()->save(me);
}
- // Only save tqparent relations
+ // Only save parent relations
TQPtrListIterator<Relation> it(m_dependParentNodes);
for ( ; it.current(); ++it ) {
it.current()->save(me);
@@ -568,10 +568,10 @@ bool Project::addTask( Node* task, Node* position )
return addSubTask(task, position);
}
// find the position
- // we have to tell the tqparent that we want to delete one of its tqchildren
+ // we have to tell the parent that we want to delete one of its tqchildren
Node* parentNode = position->getParent();
if ( !parentNode ) {
- kdDebug()<<k_funcinfo<<"tqparent node not found???"<<endl;
+ kdDebug()<<k_funcinfo<<"parent node not found???"<<endl;
return false;
}
int index = parentNode->findChildNode( position );
@@ -588,7 +588,7 @@ bool Project::addSubTask( Node* task, Node* position )
// we want to add a subtask to the node "position". It will become
// position's last child.
if ( 0 == position ) {
- kdError()<<k_funcinfo<<"No tqparent, can not add subtask: "<<task->name()<<endl;
+ kdError()<<k_funcinfo<<"No parent, can not add subtask: "<<task->name()<<endl;
return false;
}
if (!registerNodeId(task)) {
@@ -599,30 +599,30 @@ bool Project::addSubTask( Node* task, Node* position )
return true;
}
-bool Project::addSubTask( Node* task, int index, Node* tqparent )
+bool Project::addSubTask( Node* task, int index, Node* parent )
{
- // we want to add a subtask to the node "tqparent" at the given index.
- if ( 0 == tqparent ) {
- kdError()<<k_funcinfo<<"No tqparent, can not add subtask: "<<task->name()<<endl;
+ // we want to add a subtask to the node "parent" at the given index.
+ if ( 0 == parent ) {
+ kdError()<<k_funcinfo<<"No parent, can not add subtask: "<<task->name()<<endl;
return false;
}
if (!registerNodeId(task)) {
kdError()<<k_funcinfo<<"Failed to register node id, can not add subtask: "<<task->name()<<endl;
return false;
}
- tqparent->insertChildNode(index, task);
+ parent->insertChildNode(index, task);
return true;
}
void Project::delTask(Node *node)
{
- Node *tqparent = node->getParent();
- if (tqparent == 0) {
- kdDebug()<<k_funcinfo<<"Node must have a tqparent!"<<endl;
+ Node *parent = node->getParent();
+ if (parent == 0) {
+ kdDebug()<<k_funcinfo<<"Node must have a parent!"<<endl;
return;
}
removeId(node->id());
- tqparent->delChildNode(node, false/*take*/);
+ parent->delChildNode(node, false/*take*/);
}
bool Project::canIndentTask(Node* node)
@@ -636,7 +636,7 @@ bool Project::canIndentTask(Node* node)
//kdDebug()<<k_funcinfo<<"The root node cannot be indented"<<endl;
return false;
}
- // we have to find the tqparent of task to manipulate its list of tqchildren
+ // we have to find the parent of task to manipulate its list of tqchildren
Node* parentNode = node->getParent();
if ( !parentNode ) {
return false;
@@ -647,11 +647,11 @@ bool Project::canIndentTask(Node* node)
}
Node *sib = node->siblingBefore();
if (!sib) {
- //kdDebug()<<k_funcinfo<<"new tqparent node not found"<<endl;
+ //kdDebug()<<k_funcinfo<<"new parent node not found"<<endl;
return false;
}
if (node->findParentRelation(sib) || node->findChildRelation(sib)) {
- //kdDebug()<<k_funcinfo<<"Cannot have relations to tqparent"<<endl;
+ //kdDebug()<<k_funcinfo<<"Cannot have relations to parent"<<endl;
return false;
}
return true;
@@ -679,8 +679,8 @@ bool Project::canUnindentTask( Node* node )
//kdDebug()<<k_funcinfo<<"The root node cannot be unindented"<<endl;
return false;
}
- // we have to find the tqparent of task to manipulate its list of tqchildren
- // and we need the tqparent's tqparent too
+ // we have to find the parent of task to manipulate its list of tqchildren
+ // and we need the parent's parent too
Node* parentNode = node->getParent();
if ( !parentNode ) {
return false;
@@ -714,10 +714,10 @@ bool Project::canMoveTaskUp( Node* node )
{
if (node == 0)
return false; // safety
- // we have to find the tqparent of task to manipulate its list of tqchildren
+ // we have to find the parent of task to manipulate its list of tqchildren
Node* parentNode = node->getParent();
if (!parentNode) {
- //kdDebug()<<k_funcinfo<<"No tqparent found"<<endl;
+ //kdDebug()<<k_funcinfo<<"No parent found"<<endl;
return false;
}
if (parentNode->findChildNode(node) == -1) {
@@ -742,7 +742,7 @@ bool Project::canMoveTaskDown( Node* node )
{
if (node == 0)
return false; // safety
- // we have to find the tqparent of task to manipulate its list of tqchildren
+ // we have to find the parent of task to manipulate its list of tqchildren
Node* parentNode = node->getParent();
if (!parentNode) {
return false;
@@ -765,14 +765,14 @@ bool Project::moveTaskDown( Node* node )
return false;
}
-Task *Project::createTask(Node* tqparent) {
- Task* node = new Task(tqparent);
+Task *Project::createTask(Node* parent) {
+ Task* node = new Task(parent);
node->setId(uniqueNodeId());
return node;
}
-Task *Project::createTask(Task &def, Node* tqparent) {
- Task* node = new Task(def, tqparent);
+Task *Project::createTask(Task &def, Node* parent) {
+ Task* node = new Task(def, parent);
node->setId(uniqueNodeId());
return node;
}
@@ -1009,7 +1009,7 @@ bool Project::legalParents(Node *par, Node *child) {
bool legal = true;
//kdDebug()<<k_funcinfo<<par->name()<<" ("<<par->numDependParentNodes()<<" parents) "<<child->name()<<" ("<<child->numDependChildNodes()<<" tqchildren)"<<endl;
for (int i=0; i < par->numDependParentNodes() && legal; ++i) {
- Node *pNode = par->getDependParentNode(i)->tqparent();
+ Node *pNode = par->getDependParentNode(i)->parent();
if (child->isParentOf(pNode) || pNode->isParentOf(child)) {
//kdDebug()<<k_funcinfo<<"Found: "<<pNode->name()<<" is related to "<<child->name()<<endl;
legal = false;