~ubuntu-branches/ubuntu/oneiric/cairo-dock-plug-ins/oneiric-updates

« back to all changes in this revision

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

  • Committer: Bazaar Package Importer
  • Author(s): Didier Roche
  • Date: 2009-08-26 21:07:39 UTC
  • Revision ID: james.westby@ubuntu.com-20090826210739-gyjuuqezrzuluao4
Tags: upstream-2.0.8.1
ImportĀ upstreamĀ versionĀ 2.0.8.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/**
 
2
* This file is a part of the Cairo-Dock project
 
3
*
 
4
* Copyright : (C) see the 'copyright' file.
 
5
* E-mail    : see the 'copyright' file.
 
6
*
 
7
* This program is free software; you can redistribute it and/or
 
8
* modify it under the terms of the GNU General Public License
 
9
* as published by the Free Software Foundation; either version 3
 
10
* of the License, or (at your option) any later version.
 
11
*
 
12
* This program is distributed in the hope that it will be useful,
 
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
 
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
15
* GNU General Public License for more details.
 
16
* You should have received a copy of the GNU General Public License
 
17
* along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
18
*/
 
19
 
 
20
 
 
21
#ifndef __CD_APPLET_STRUCT__
 
22
#define  __CD_APPLET_STRUCT__
 
23
 
 
24
#include <cairo-dock.h>
 
25
 
 
26
typedef enum {
 
27
        WIFI_INFO_NONE = 0,
 
28
        WIFI_INFO_SIGNAL_STRENGTH_LEVEL,
 
29
        WIFI_INFO_SIGNAL_STRENGTH_PERCENT,
 
30
        WIFI_INFO_SIGNAL_STRENGTH_DB,
 
31
        WIFI_NB_INFO_TYPE
 
32
} CDWifiInfoType;
 
33
 
 
34
typedef enum {
 
35
        WIFI_QUALITY_NO_SIGNAL = 0,
 
36
        WIFI_QUALITY_VERY_LOW,
 
37
        WIFI_QUALITY_LOW,
 
38
        WIFI_QUALITY_MIDDLE,
 
39
        WIFI_QUALITY_GOOD,
 
40
        WIFI_QUALITY_EXCELLENT,
 
41
        WIFI_NB_QUALITY
 
42
} CDWifiQuality;
 
43
 
 
44
typedef enum {
 
45
        WIFI_EFFECT_NONE = 0,
 
46
        WIFI_EFFECT_ZOOM,
 
47
        WIFI_EFFECT_TRANSPARENCY,
 
48
        WIFI_EFFECT_BAR,
 
49
} CDWifiEffect;
 
50
 
 
51
 
 
52
typedef enum _CDWifiDisplayType {
 
53
        CD_WIFI_GAUGE=0,
 
54
        CD_WIFI_GRAPH,
 
55
        CD_WIFI_BAR,
 
56
        CD_WIFI_NB_TYPES
 
57
        } CDWifiDisplayType; 
 
58
 
 
59
struct _AppletConfig {
 
60
        gchar *defaultTitle;
 
61
        gchar *cUserImage[WIFI_NB_QUALITY];
 
62
        gchar *cGThemePath;
 
63
        gchar *cUserCommand;
 
64
        gchar *cWatermarkImagePath;
 
65
        gdouble fAlpha;
 
66
        
 
67
        CDWifiInfoType quickInfoType;
 
68
        CDWifiEffect iEffect;
 
69
        CDWifiDisplayType iDisplayType;
 
70
        
 
71
        gint iCheckInterval;
 
72
        
 
73
        CairoDockTypeGraph iGraphType;
 
74
        gdouble fLowColor[3];
 
75
        gdouble fHigholor[3];
 
76
        gdouble fBgColor[4];
 
77
        gdouble fSmoothFactor;
 
78
        
 
79
        gboolean bESSID;
 
80
};
 
81
 
 
82
struct _AppletData {
 
83
        // shared memory
 
84
        CDWifiQuality iQuality, iPreviousQuality;
 
85
        gint iPercent, iPrevPercent;
 
86
        gint iSignalLevel, iPrevSignalLevel;
 
87
        gint iPrevNoiseLevel, iNoiseLevel;
 
88
        gchar *cESSID;
 
89
        gchar *cInterface;
 
90
        gchar *cAccessPoint;
 
91
        // end of shared memory
 
92
        gboolean bWirelessExt;
 
93
        CairoDockTask *pTask;
 
94
        cairo_surface_t *pSurfaces[WIFI_NB_QUALITY];
 
95
};
 
96
 
 
97
 
 
98
#endif