Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 5247 in orxonox.OLD


Ignore:
Timestamp:
Sep 24, 2005, 9:27:48 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: fixed an error in ShellDisplay: did not show the last line on first open

Location:
trunk/src/lib
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/lib/shell/shell.cc

    r5246 r5247  
    109109  bufferIT->lastElement();
    110110  for (int i = 0; i < this->bufferDisplaySize; i++)
    111     this->bufferText[i]->setText(bufferIT->prevElement(), true);
     111  {
     112    this->bufferText[i]->setText(bufferIT->getCurrent(), true);
     113    bufferIT->prevStep();
     114  }
    112115  delete bufferIT;
    113116}
     
    128131  bufferIT->lastElement();
    129132  for (int i = 0; i < this->bufferDisplaySize; i++)
    130     this->bufferText[i]->setText(bufferIT->prevElement(), false);
     133  {
     134    this->bufferText[i]->setText(bufferIT->getCurrent(), true);
     135    bufferIT->prevStep();
     136  }
    131137  delete bufferIT;
    132138}
  • trunk/src/lib/shell/shell.h

    r5246 r5247  
    1818class Text;
    1919class ShellInput;
    20 class ShellCommandBase;
    21 template<class T> class tList;
    2220template<class T> class tIterator;
    2321
     
    9492    Text**                   bufferText;             //!< A list of stored bufferTexts for the display of the buffer.
    9593    int                      bufferOffset;           //!< how many lines from the bottom up we display the Buffer.
     94    tIterator<char>*         bufferIterator;         //!< used to move through and print the Buffer
    9695};
    9796
  • trunk/src/lib/util/list.h

    r5244 r5247  
    563563    inline T* tIterator<T>::getCurrent()
    564564{
    565   if (likeley(this->tmpEl))
     565  if (likely(this->tmpEl != NULL))
    566566    return this->tmpEl->curr;
    567567  else
Note: See TracChangeset for help on using the changeset viewer.