1702a31bf0f68414955dcbf5ef59cd9e508104d1
[profile/ivi/ico-uxf-homescreen.git] / lib / system-controller / CicoSCWindow.h
1 /*
2  * Copyright (c) 2013, TOYOTA MOTOR CORPORATION.
3  *
4  * This program is licensed under the terms and conditions of the
5  * Apache License, version 2.0.  The full text of the Apache License is at
6  * http://www.apache.org/licenses/LICENSE-2.0
7  *
8  */
9
10 //==========================================================================
11 /**
12  *  @file   CicoSCWindow.h
13  *
14  *  @brief  
15  */
16 //==========================================================================
17 #ifndef __CICO_SC_WINDOW_H__
18 #define __CICO_SC_WINDOW_H__
19
20 #include <string>
21
22 using namespace std;
23
24 //==========================================================================
25 //  Forward declaration
26 //==========================================================================
27 class CicoSCDisplay;
28 class CicoSCLayer;
29 class CicoSCApplication;
30
31 //==========================================================================
32 //  define macro
33 //==========================================================================
34 #define ICO_SURFACEID_2_HOSTID(surfid)      (((unsigned int)surfid) >> 24)
35 #define ICO_SURFACEID_2_DISPLAYNO(surfid)   (((unsigned int)surfid) >> 16) 
36 #define ICO_SURFACEID_2_NODEID(surfid)      (((unsigned int)surfid) >> 16)
37 #define ICO_SURFACEID_BASE(nodeid)          (((unsigned int)nodeid) << 16)
38
39 //--------------------------------------------------------------------------
40 /**
41  *  @brief window information class
42  */
43 //--------------------------------------------------------------------------
44 class CicoSCWindow
45 {
46 public:
47     // default constructor
48     CicoSCWindow();
49
50     // destructor
51     virtual ~CicoSCWindow();
52
53     // dump log CicoSCWindow member variables
54     void dump(void);
55
56 private:
57     // assignment operator
58     CicoSCWindow& operator=(const CicoSCWindow &object);
59
60     // copy constructor
61     CicoSCWindow(const CicoSCWindow &object);
62
63 public:
64     CicoSCDisplay     *m_display;       //!< display local cache
65     CicoSCLayer       *m_layer;         //!< layer local cache
66     CicoSCApplication *m_application;   //!< process local cache
67     CicoSCWindow      *m_parent;        //!< parent window
68
69     short             state;            //!< Window status
70     unsigned char     request;          //!< Request
71
72     int               surfaceid;        //!< sruface id (window id)
73     string            name;             //!< wondow name
74     string            appid;            //!< application id
75     int               pid;              //!< process id
76
77     int               nodeid;           //!< node id
78     int               displayid;        //!< display id
79     int               layerid;          //!< layer id
80     int               zoneid;           //!< display zone id
81     int               subwindow;        //!< main window(=0) or sub window(>0)
82     unsigned int      eventmask;        //!< Event to receive through this window
83     int               x;                //!< Upperleft X coord of the window
84     int               y;                //!< Upper left Y coord of the window
85     int               width;            //!< width of window
86     int               height;           //!< height of window
87     bool              visible;          //!< visibility
88     bool              raise;            //!< raise/lower
89     bool              active;           //!  active/inactive
90 };
91 #endif  // __CICO_SC_WINDOW_H__
92 // vim:set expandtab ts=4 sw=4: