Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7899 in orxonox.OLD for branches/gui/src/lib


Ignore:
Timestamp:
May 27, 2006, 12:50:32 PM (18 years ago)
Author:
bensch
Message:

gui: added timer class for a more exact time

Location:
branches/gui/src/lib
Files:
2 added
4 edited

Legend:

Unmodified
Added
Removed
  • branches/gui/src/lib/Makefile.am

    r7819 r7899  
    2828                util/file.cc \
    2929                util/directory.cc \
     30                util/timer.cc \
    3031                \
    3132                data/data_tank.cc
     
    4950                util/file.h \
    5051                util/directory.h \
     52                util/timer.h \
    5153                \
    5254                util/loading/resource_manager.h \
  • branches/gui/src/lib/gui/gl_gui/glgui_handler.cc

    r7895 r7899  
    6161  void GLGuiHandler::activateCursor()
    6262  {
    63     this->cursor = new GLGuiCursor();
     63    if (this->cursor == NULL)
     64      this->cursor = new GLGuiCursor();
    6465    this->cursor->show();
    6566  }
     
    101102        if (event.bPressed)
    102103        {
     104          if (GLGuiWidget::focused()->clickable())
    103105          GLGuiWidget::focused()->click();
    104106        }
    105107        else
    106           GLGuiWidget::focused()->release();
     108        {
     109          if (GLGuiWidget::focused()->clickable())
     110            GLGuiWidget::focused()->release();
     111        }
    107112      }
    108113    }
  • branches/gui/src/lib/gui/gl_gui/glgui_widget.h

    r7896 r7899  
    1313#include "glincl.h"
    1414#include "signal_connector.h"
     15#include <vector>
    1516
    1617// FORWARD DECLARATION
     
    9798
    9899
     100    DeclareSignal(testSignal, ());
    99101
    100102  protected:
  • branches/gui/src/lib/gui/gl_gui/signal_connector.h

    r7855 r7899  
    1111namespace OrxGui
    1212{
     13
     14#define DeclareSignal(name, params) \
     15  public: \
     16   void signal_ ##connect ##name(const SignalConnector& connector) { \
     17     name ## connected.push_back(connector); \
     18   }\
     19  private: \
     20   void  signal_ ## name params { \
     21     for (unsigned int i = 0; i < name ## connected . size(); i++) \
     22       name ## connected[i] ("TEST"); \
     23   }\
     24   std::vector<SignalConnector> name ## connected
     25
    1326  //! A class for Conncting Signals to Objects, inside of the GUI
    1427  class SignalConnector
Note: See TracChangeset for help on using the changeset viewer.