~cairo-dock-team/ubuntu/oneiric/cairo-dock-plug-ins/2.3.0-2.1

« back to all changes in this revision

Viewing changes to Doncky/src/applet-struct.h

  • Committer: Bazaar Package Importer
  • Author(s): Matthieu Baerts (matttbe)
  • Date: 2011-04-20 20:46:51 UTC
  • mfrom: (1.1.9 upstream)
  • Revision ID: james.westby@ubuntu.com-20110420204651-ftnpzesj6uc7qeul
Tags: 2.3.0~1-0ubuntu1
* New Upstream Version (LP: #723995)
* Upstream short ChangeLog (since 2.3.0~0rc1):
 - Updated translations
 - Updated the integration of the new versions of kwin and compiz
    (Switcher, ShowDesktop, etc.)
 - Removed a lot of useless g_print
 - Updated a few plug-ins to fit with the new version of the API (gldit)
 - Fixed a few bugs
 - Updated MeMenu, MessagingMenu and Status-Notifier to works
    with the latest version of dbusmenu, etc.
* Switch to dpkg-source 3.0 (quilt) format
* debian/cairo-dock-plug-ins.install:
 - Added new files (interfaces for python, ruby, vala and mono)
* debian/control:
 - Added new dependences for new applets (sensors and zeitgeist)
    and new interfaces (python, valac, ruby and mono)
 - Updated the version of cairo-dock build-dependences
* debian/rules:
 - Added a new CMake flag to install python interface in debian/tmp
* Updated debian/watch

Show diffs side-by-side

added added

removed removed

Lines of Context:
26
26
#define CD_SYSMONITOR_PROC_FS "/proc"   // REPRIS DE SYSTEM-MONITOR
27
27
#define CD_SYSMONITOR_NB_MAX_VALUES 4   // REPRIS DE SYSTEM-MONITOR
28
28
 
29
 
 // REPRIS DE SYSTEM-MONITOR :
30
 
typedef enum _CDSysmonitorDisplayType {
31
 
        CD_SYSMONITOR_GAUGE=0,
32
 
        CD_SYSMONITOR_GRAPH,
33
 
        CD_SYSMONITOR_BAR,
34
 
        CD_SYSMONITOR_NB_TYPES
35
 
        } CDSysmonitorDisplayType;
36
 
        
37
 
 
38
 
 
39
29
typedef struct _CDDiskUsage {
40
30
        long long iPrevAvail;
41
31
        long long iAvail;
45
35
        int iType;
46
36
        } CDDiskUsage;
47
37
 
48
 
 
49
 
 
50
38
//\___________ structure containing the applet's configuration parameters.
51
39
struct _AppletConfig {
52
 
        
 
40
        gchar *cDefaultFont;
 
41
        double fDefaultTextColor[4];
 
42
        gint iTextMargin;
 
43
        gint iSpaceBetweenLines;
53
44
        gboolean bDisplayBackground;
54
45
        double fBackgroundColor1[4];
55
46
        double fBackgroundColor2[4];
56
47
        gint iBackgroundRadius;
57
48
        gint iBorderThickness;
58
49
        double fBorderColor[4];
59
 
        double fDefaultTextColor[4];
60
 
        gchar *cDefaultFont;
61
 
        gint iTextMargin;
62
 
        gint iSpaceBetweenLines;        
 
50
        
 
51
        gchar *cDeskletSize;
63
52
        gchar *cXmlFilePath;
64
 
        
65
53
        gint iCheckInterval;
66
54
        
67
 
        
68
 
        
69
55
        // REPRIS DE SYSTEM-MONITOR :
70
 
        gchar *defaultTitle;
71
56
        gboolean bShowCpu;
72
57
        gboolean bShowRam;
73
58
        gboolean bShowNvidia;
74
59
        gboolean bShowSwap;
75
 
        gchar *cGThemePath;
76
 
        gchar *cWatermarkImagePath;
77
 
        gdouble fAlpha; 
78
 
        CDSysmonitorDisplayType iDisplayType;
79
 
        CairoDockTypeGraph iGraphType;
80
 
        gdouble fLowColor[3];
81
 
        gdouble fHigholor[3];
82
 
        gdouble fBgColor[4];
83
 
        gboolean bMixGraph;     
84
 
        gint iNbDisplayedProcesses;
85
 
        gboolean bTopInPercent;
86
 
        CairoDockLabelDescription *pTopTextDescription; 
87
 
        gchar *cSystemMonitorCommand;
88
60
        gchar *cSystemMonitorClass;
89
 
        gboolean bStealTaskBarIcon;
90
 
        gdouble fUserHZ;        
91
 
        gchar *cSoundPath;
 
61
        gdouble fUserHZ;
92
62
        } ;
93
63
 
94
 
 
95
 
 
96
 
// REPRIS DE SYSTEM-MONITOR :
97
 
typedef struct {
98
 
        gint iPid;
99
 
        gchar *cName;
100
 
        gint iCpuTime;
101
 
        gdouble fCpuPercent;
102
 
        gdouble iMemAmount;
103
 
        gdouble fLastCheckTime;
104
 
        } CDProcess;
105
 
 
106
 
 
107
 
 
108
 
 
109
 
 
110
64
//\___________ structure containing the applet's data, like surfaces, dialogs, results of calculus, etc.
111
65
struct _AppletData {
112
 
        // Nouveau Doncky
113
 
        
114
 
        
 
66
        //~ // Copy of myConfig :
 
67
        //~ gchar *cDefaultFont;
 
68
        //~ double fDefaultTextColor[4];
 
69
        //~ gint iTextMargin;
 
70
        //~ gint iSpaceBetweenLines;
 
71
        //~ gboolean bDisplayBackground;
 
72
        //~ double fBackgroundColor1[4];
 
73
        //~ double fBackgroundColor2[4];
 
74
        //~ gint iBackgroundRadius;
 
75
        //~ gint iBorderThickness;
 
76
        //~ double fBorderColor[4];
 
77
        
 
78
        gchar *cThemeFolder;
 
79
        gchar *cXmlFileName;
115
80
        gchar *cPrevAlignWidth;
116
81
        gchar *cPrevAlignHeight;
117
82
        gchar *cPrevFont;
118
83
        double fPrevTextColor[4];
119
84
        gint iPrevOverrideH;
120
 
        gint iPrevOverrideW;
121
 
        
122
 
        
123
 
        
124
 
        
125
 
        
126
 
        
127
 
        
128
 
        
129
 
        
130
 
        
131
 
        
132
 
        
133
 
        // Ancien Doncky
134
 
        CairoDockTask *pPeriodicRefreshTask;
135
 
        
136
 
        GList *pTextZoneList;
137
 
        
138
 
        gchar *cTempoText;
 
85
        gint iPrevOverrideW;    
 
86
        CairoDockTask *pPeriodicRefreshTask;    
 
87
        GList *pTextZoneList;   
139
88
        gchar *cCurrentText;    
140
89
        double fCurrentX; // Position du curseur dans le desklet
141
90
        double fCurrentY;
142
91
        double fCurrentYalign;
143
92
        gchar *cLastAlignHeight;
144
93
        gint iLastLineHeight;
145
 
        gboolean bLastWasSameLine;
146
 
        gint iMaxGraphHistory;
147
 
        
 
94
        gboolean bLastWasSameLine;      
148
95
        cairo_surface_t *pImgSurface;
149
 
        
150
 
        
 
96
        gint iCurrentFileSize;
151
97
        
152
98
        // REPRIS DE SYSTEM-MONITOR :
153
 
        
154
99
        // infos, constantes.
155
100
        gint iNbCPU;
156
 
        gulong iMemPageSize;
157
101
        gint iFrequency;
158
102
        gchar *cModelName;
159
103
        gchar *cGPUName;
160
104
        gint iVideoRam;
161
105
        gchar *cDriverVersion;
162
 
        
163
106
        // shared memory for the main thread.
164
107
        gboolean bInitialized;
165
108
        gboolean bAcquisitionOK;
177
120
        gboolean bNeedsUpdate;
178
121
        gint iTimerCount;
179
122
        // end of shared memory.
180
 
        gint iCount;  // pour sous-echantilloner les acquisitions de valeurs moins variables.
181
 
        
182
 
        gint iNbProcesses;
183
 
        CairoDialog *pTopDialog;
184
 
        cairo_surface_t *pTopSurface;
185
 
        CairoDockTask *pTopTask;
186
 
        // shared memory for the "top" thread.
187
 
        GHashTable *pProcessTable;
188
 
        CDProcess **pTopList;
189
 
        GTimer *pTopClock;
190
 
        gboolean bSortTopByRam;
191
 
        // end of shared memory.
192
 
        
193
 
        gint iMaxFrequency;
194
123
        } ;
195
124
 
196
125
#endif