X-Git-Url: http://git.polytechnique.org/?a=blobdiff_plain;f=banana%2Fspool.inc.php;h=015dd5d6d55b28ff205a3a7cff9024c1be863a08;hb=d35878e0fc33525a980c2ba71c5ab5dfa7849c10;hp=04c6f7c72c8e2df184222393f84f761936962800;hpb=4f18bf36aa9d8d6a826a5ca2cc1ad47c06a3bea9;p=banana.git diff --git a/banana/spool.inc.php b/banana/spool.inc.php index 04c6f7c..015dd5d 100644 --- a/banana/spool.inc.php +++ b/banana/spool.inc.php @@ -527,37 +527,6 @@ class BananaSpool return Banana::$first ? Banana::$spool_tmax : Banana::$spool_tcontext; } - - /** computes linear post index - * @param $_id INTEGER MSGNUM of post - * @return INTEGER linear index of post - */ - public function getNdX($_id) - { - $ndx = 1; - $id_cur = $_id; - while (true) { - $id_parent = $this->overview[$id_cur]->parent; - if (is_null($id_parent)) break; - $pos = array_search($id_cur, $this->overview[$id_parent]->children); - - for ($i = 0; $i < $pos ; $i++) { - $ndx += $this->overview[$this->overview[$id_parent]->children[$i]]->desc; - } - $ndx++; //noeud père - - $id_cur = $id_parent; - } - - foreach ($this->roots as $i) { - if ($i==$id_cur) { - break; - } - $ndx += $this->overview[$i]->desc; - } - return $ndx; - } - /** Return root message of the given thread * @param id INTEGER id of a message */