original_string: public function isactive() {
          global $PAGE;
  
          if ($this->is_section()) {
              $active = $PAGE->navigation->find_active_node();
              while ($active = $active->parent) {
                  if ($active->key == $this->key && $active->type == $this->type) {
                      return true;
                  }
              }
          }
          return $this->isactive;
      }
code: public function isactive() {
          global $PAGE;
  
          if ($this->is_section()) {
              $active = $PAGE->navigation->find_active_node();
              while ($active = $active->parent) {
                  if ($active->key == $this->key && $active->type == $this->type) {
                      return true;
                  }
              }
          }
          return $this->isactive;
      }
code_tokens: public function isactive ( ) { global $ PAGE ; if ( $ this -> is_section ( ) ) { $ active = $ PAGE -> navigation -> find_active_node ( ) ; while ( $ active = $ active -> parent ) { if ( $ active -> key == $ this -> key && $ active -> type == $ this -> type ) { return true ; } } } return $ this -> isactive ; }
docstring: In flat navigation - sections are active if we are looking at activities in the section.
  @return boolean
docstring_tokens: In flat navigation - sections are active if we are looking at activities in the section .