component.h

00001 /***************************************************************************
00002                           component.h  -  description
00003                              -------------------
00004     begin                : Sat Jan 31 2004
00005     copyright            : (C) 2004 by Dynacube Team
00006     email                : 
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018  #ifndef __COMPONENT_H
00019  #define __COMPONENT_H
00020 
00021  #ifdef __cplusplus
00022    extern "C"
00023    {
00024      #include "common/ktypes.h"
00025      #include "common/stdlib.h"
00026      #include "gui/graphics.h"
00027      #include "common/string.h"
00028    }
00029  #else
00030       #include "common/ktypes.h"
00031       #include "common/stdlib.h"
00032       #include "gui/graphics.h"
00033       #include "common/string.h"
00034  #endif
00035  
00036  #define WIND_TYPE 1
00037  #define FRM_TYPE  2
00038 
00039  //styles
00040  #define DISABLED 1
00041 
00042  //component types
00043  
00044  #define BUT_TYPE          1
00045  #define TEXT_TYPE         2
00046  #define TEXTAREA_TYPE     3
00047  #define LABEL_TYPE        4
00048  #define SCROLLBAR         5
00049  #define FOLDERVIEW_TYPE  20
00050  
00051  #define BORDER_WIDTH  2
00052  #define BORDER_HEIGHT 2
00053  #define TITLE_HEIGHT  20
00054 
00055  #define ST_SHIFT  0x1
00056  #define ST_CAPS   (0x1<<1)
00057  #define ST_CNTL   (0x1<<2)
00058  #define ST_ALT    (0x1<<3)
00059  
00060  
00061  class component
00062  {
00063    public:
00064    DW type;
00065    DW id, parent_id,alias_id;
00066    DW x, y, width, height;
00067    void *cnt_ptr;
00068    DB cnt_type;
00069    DD style;
00070 
00071    void comp_init(DW _type,DW _id,DW _parent_id,DW _cnt_type,void *_cnt_ptr,DW _alias_id,DW _x,DW _y,DW _width,DW _height,DD _style);
00072    void activate();
00073    void deactivate();
00074  };
00075 
00076  #endif

Generated on Thu Jul 27 23:52:25 2006 for Dynacube by  doxygen 1.4.7