Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7992 in orxonox.OLD for branches/gui


Ignore:
Timestamp:
May 30, 2006, 9:29:25 PM (19 years ago)
Author:
bensch
Message:

doxytags

Location:
branches/gui/src/lib/gui/gl_gui
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/gui/src/lib/gui/gl_gui/signal_connector.cc

    r7990 r7992  
    2121{
    2222
     23  /**
     24   * @brief creates a clean SignalConnector
     25   */
    2326  SignalConnector::SignalConnector( )
    2427  {
     
    2730  }
    2831
     32  /**
     33   * @brief Creates a SignalConnector out of an ObjectPointer, and an Executor.
     34   * @param object the Object the Executor will apply to.
     35   * @param executor the Executor that will be executed.
     36   * @return a new SignalConnector.
     37   */
    2938  SignalConnector::SignalConnector(BaseObject* object, const Executor* executor)
    3039  {
     
    3342  };
    3443
     44  /**
     45   * @brief Creates a SignalConnector as a copy of another one.
     46   * @param signalConnector The SignalConnector to copy.
     47   */
    3548  SignalConnector::SignalConnector(const SignalConnector& signalConnector)
    3649  {
     
    3952  }
    4053
     54  /**
     55   * @brief deletes a SignalConnector.
     56   *
     57   * frees the stored executor
     58   */
    4159  SignalConnector::~SignalConnector()
    4260  {
     
    5270
    5371
     72  /**
     73   * @brief Executes the SignalConnector.
     74   */
    5475  void SignalConnector::operator()() const
    5576  {
     
    5879  }
    5980
     81  /**
     82   * @brief Executes the SignalConnector.
     83   * @param value0 First Value.
     84   */
    6085  void SignalConnector::operator()(const MultiType& value0) const
    6186  {
     
    6489  }
    6590
     91  /**
     92   * @brief Executes the SignalConnector.
     93   * @param value0 First Value
     94   * @param value1 Second Value
     95   */
    6696  void SignalConnector::operator()(const MultiType& value0, const MultiType& value1) const
    6797  {
     
    73103  }
    74104
     105  /**
     106   * @brief Executes the SignalConnector.
     107   * @param value0 First Value
     108   * @param value1 Second Value
     109   * @param value2 Third Value
     110   */
    75111  void SignalConnector::operator()(const MultiType& value0, const MultiType& value1, const MultiType& value2) const
    76112  {
     
    82118  }
    83119
     120  /**
     121   * @brief Executes the SignalConnector.
     122   * @param value0 First Value
     123   * @param value1 Second Value
     124   * @param value2 Third Value
     125   * @param value3 Fourth Value
     126   */
    84127  void SignalConnector::operator()(const MultiType& value0, const MultiType& value1, const MultiType& value2, const MultiType& value3) const
    85128  {
     
    91134  }
    92135
     136  /**
     137   * @brief Executes the SignalConnector.
     138   * @param value0 First Value
     139   * @param value1 Second Value
     140   * @param value2 Third Value
     141   * @param value3 Fourth Value
     142   * @param value3 Fifth Value
     143   */
    93144  void SignalConnector::operator()(const MultiType& value0, const MultiType& value1, const MultiType& value2, const MultiType& value3, const MultiType& value4) const
    94145  {
  • branches/gui/src/lib/gui/gl_gui/signal_connector.h

    r7991 r7992  
    2323#define DeclareSignalEnd(SignalName) \
    2424  Signal SignalName ## connected
    25 /////////////////////////////////////////////
     25  /////////////////////////////////////////////
    2626
    2727
     
    4242   * @brief declares a new Signal.
    4343   * @param SignalName the Name of the Signal.
     44   * @param param0 the first Parameter the Function takes
    4445   */
    4546#define DeclareSignal1(SignalName, param0) \
     
    5253
    5354  /**
    54  * @brief declares a new Signal.
    55  * @param SignalName the Name of the Signal.
     55   * @brief declares a new Signal.
     56   * @param SignalName the Name of the Signal.
     57   * @param param0 the first Parameter the Function takes
     58   * @param param1 the second Parameter the Function takes
    5659   */
    5760#define DeclareSignal2(SignalName, param0, param1) \
     
    6871   * @brief declares a new Signal.
    6972   * @param SignalName the Name of the Signal.
     73   * @param param0 the first Parameter the Function takes
     74   * @param param1 the second Parameter the Function takes
     75   * @param param2 the third Parameter the Function takes
    7076   */
    7177#define DeclareSignal3(SignalName, param0, param1, param2) \
     
    8086   * @brief declares a new Signal.
    8187   * @param SignalName the Name of the Signal.
     88   * @param param0 the first Parameter the Function takes
     89   * @param param1 the second Parameter the Function takes
     90   * @param param2 the third Parameter the Function takes
     91   * @param param3 the fourth Parameter the Function takes
    8292   */
    8393#define DeclareSignal4(SignalName, param0, param1, param2, param3) \
     
    93103   * @brief declares a new Signal.
    94104   * @param SignalName the Name of the Signal.
     105   * @param param0 the first Parameter the Function takes
     106   * @param param1 the second Parameter the Function takes
     107   * @param param2 the third Parameter the Function takes
     108   * @param param4 the fifth Parameter the Function takes
    95109   */
    96110#define DeclareSignal5(SignalName, param0, param1, param2, param3, param4) \
     
    103117
    104118
    105    /**
    106     * @brief selects a Signal.
    107     * @param SignalName the Signal to be retrieved.
    108     */
     119  /**
     120   * @brief selects a Signal.
     121   * @param SignalName the Signal to be retrieved.
     122   */
    109123#define SIGNAL(Object, SignalName) \
    110124    Object->getSignalVector_##SignalName()
    111125
    112 /**
    113  * @brief defines a Slot, the sink of a Signal.
    114  * @param Class the Class the Slot belongs to.
    115  * @param function the Function to Connect to.
    116  */
     126  /**
     127   * @brief defines a Slot, the sink of a Signal.
     128   * @param Class the Class the Slot belongs to.
     129   * @param function the Function to Connect to.
     130   */
    117131#define SLOT(Class, function) \
    118132    createExecutor<Class>(&Class::function)
    119133
    120 /**
    121  * @brief emits function
    122  */
     134  /**
     135   * @brief emits function
     136   */
    123137#define emit(function) function
    124138
    125   //! A class for Conncting Signals to Objects, inside of the GUI
     139  //! A class for Conncting Signals to Objects, inside of the Graphical user interface.
     140  /**
     141   * The SignalConnector binds an Object to a Functional (Executor)
     142   * The Usage is quite easy in the Widget for this:
     143   *
     144   * int the header (Class Definition) you can add a definition of a Signal with:
     145   * @verbatim DeclareSignal3(my_signal, int, int, float)
     146   * and a Signal with the the Parameters int,int and float will be created.
     147   *
     148   * now you can use the connect function of GLWidget to connect this Signal to a Slot.
     149   * @see GLGuiWidget::connect
     150   */
    126151  class SignalConnector
    127152  {
     
    133158
    134159    SignalConnector& operator=(const SignalConnector& signalConnector);
     160    bool operator==(const SignalConnector& signalConnector);
    135161
    136162    void operator()() const;
     
    141167    void operator()(const MultiType& value0, const MultiType& value1, const MultiType& value2, const MultiType& value3, const MultiType& value4) const;
    142168
     169    /** checks wether the SignalConnector is valid @return true on valid. */
    143170    bool isValid() const { return (this->object && this->exec); };
     171    /** @brief checks if the SignalConnector is clean, invalid @returns true if invalid */
    144172    bool isClean() const { return (this->object == NULL || this->exec == NULL); }
    145173
     
    150178  };
    151179
     180  //! TypeDefinition for SignalLists
    152181  typedef std::vector<SignalConnector> Signal;
     182  //! TypeDefinition for a Slot.
    153183  typedef Executor*                    Slot;
    154184
Note: See TracChangeset for help on using the changeset viewer.