wmmixer: Warnings about g++ const removed
This commit is contained in:
parent
a3bf2a318c
commit
8b8feebc1b
|
@ -1,5 +1,5 @@
|
|||
/* XPM */
|
||||
static char * icons_xpm[] = {
|
||||
static char const *icons_xpm[] = {
|
||||
"220 22 4 1",
|
||||
" c #282828 s back_color",
|
||||
". c #00ffff s led_color_high",
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/* XPM */
|
||||
static char * norec_xpm[] = {
|
||||
static char const *norec_xpm[] = {
|
||||
"10 9 3 1",
|
||||
" c None",
|
||||
". c #AEAAAE",
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/* XPM */
|
||||
static char *tile_xpm[] = {
|
||||
static char const *tile_xpm[] = {
|
||||
"64 64 54 1",
|
||||
" c #F3CEF3CEF3CE",
|
||||
". c #000000000000",
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/* XPM */
|
||||
static char * wmmixer_xpm[] = {
|
||||
static char const *wmmixer_xpm[] = {
|
||||
"64 64 10 1",
|
||||
" c None",
|
||||
". c #000000",
|
||||
|
|
|
@ -23,8 +23,8 @@ MixCtl::MixCtl(char *device_name) throw(MixerDeviceException)
|
|||
if((mixfd = open(device_,O_RDONLY | O_NONBLOCK)) != -1)
|
||||
{
|
||||
num_devices_ = SOUND_MIXER_NRDEVICES;
|
||||
char *devnames[] = SOUND_DEVICE_NAMES;
|
||||
char *devlabels[] = SOUND_DEVICE_LABELS;
|
||||
const char *devnames[] = SOUND_DEVICE_NAMES;
|
||||
const char *devlabels[] = SOUND_DEVICE_LABELS;
|
||||
ioctl(mixfd, SOUND_MIXER_READ_DEVMASK, &devmask);
|
||||
ioctl(mixfd, SOUND_MIXER_READ_STEREODEVS, &stmask);
|
||||
ioctl(mixfd, SOUND_MIXER_READ_RECMASK, &recmask);
|
||||
|
@ -39,8 +39,8 @@ MixCtl::MixCtl(char *device_name) throw(MixerDeviceException)
|
|||
mixer_devices_[count].stereo = stmask & mixmask;
|
||||
mixer_devices_[count].records = recmask & mixmask;
|
||||
mixer_devices_[count].mask = mixmask;
|
||||
mixer_devices_[count].name = devnames[count];
|
||||
mixer_devices_[count].label = devlabels[count];
|
||||
mixer_devices_[count].name = (char *) devnames[count];
|
||||
mixer_devices_[count].label = (char *) devlabels[count];
|
||||
mixer_devices_[count].muted = 0;
|
||||
mixmask*=2;
|
||||
}
|
||||
|
|
|
@ -403,22 +403,22 @@ void XHandler::initGraphicsContext()
|
|||
//--------------------------------------------------------------------
|
||||
void XHandler::initPixmaps(int display_depth)
|
||||
{
|
||||
XpmColorSymbol xpmcsym[4]={{"back_color", NULL, colors_[0]},
|
||||
{"led_color_high", NULL, colors_[1]},
|
||||
{"led_color_med", NULL, colors_[2]},
|
||||
{"led_color_low", NULL, colors_[3]}};
|
||||
XpmColorSymbol const xpmcsym[4]={{(char *)"back_color", NULL, colors_[0]},
|
||||
{(char *)"led_color_high", NULL, colors_[1]},
|
||||
{(char *)"led_color_med", NULL, colors_[2]},
|
||||
{(char *)"led_color_low", NULL, colors_[3]}};
|
||||
XpmAttributes xpmattr;
|
||||
|
||||
xpmattr.numsymbols = 4;
|
||||
xpmattr.colorsymbols = xpmcsym;
|
||||
xpmattr.colorsymbols = (XpmColorSymbol *)xpmcsym;
|
||||
xpmattr.exactColors = false;
|
||||
xpmattr.closeness = 40000;
|
||||
xpmattr.valuemask = XpmColorSymbols | XpmExactColors | XpmCloseness;
|
||||
|
||||
XpmCreatePixmapFromData(display_default_, window_root_, wmmixer_xpm, &pixmap_main, &pixmap_mask, &xpmattr);
|
||||
XpmCreatePixmapFromData(display_default_, window_root_, tile_xpm, &pixmap_tile, NULL, &xpmattr);
|
||||
XpmCreatePixmapFromData(display_default_, window_root_, icons_xpm, &pixmap_icon, NULL, &xpmattr);
|
||||
XpmCreatePixmapFromData(display_default_, window_root_, norec_xpm, &pixmap_nrec, NULL, &xpmattr);
|
||||
XpmCreatePixmapFromData(display_default_, window_root_, (char **)wmmixer_xpm, &pixmap_main, &pixmap_mask, &xpmattr);
|
||||
XpmCreatePixmapFromData(display_default_, window_root_, (char **)tile_xpm, &pixmap_tile, NULL, &xpmattr);
|
||||
XpmCreatePixmapFromData(display_default_, window_root_, (char **)icons_xpm, &pixmap_icon, NULL, &xpmattr);
|
||||
XpmCreatePixmapFromData(display_default_, window_root_, (char **)norec_xpm, &pixmap_nrec, NULL, &xpmattr);
|
||||
|
||||
pixmap_disp = XCreatePixmap(display_default_, window_root_, 64, 64, display_depth);
|
||||
}
|
||||
|
@ -461,8 +461,8 @@ void XHandler::initWindow(int argc, char** argv)
|
|||
|
||||
window_root_ = RootWindow(display_default_, screen);
|
||||
|
||||
back_pix = getColor("white");
|
||||
fore_pix = getColor("black");
|
||||
back_pix = getColor((char *)"white");
|
||||
fore_pix = getColor((char *)"black");
|
||||
|
||||
window_main_ = XCreateSimpleWindow(display_default_, window_root_, shints.x, shints.y,
|
||||
shints.width, shints.height, 0, fore_pix, back_pix);
|
||||
|
@ -495,7 +495,7 @@ void XHandler::initWindow(int argc, char** argv)
|
|||
wmhints.flags = WindowGroupHint | StateHint;
|
||||
}
|
||||
|
||||
classHint.res_name=NAME;
|
||||
classHint.res_name=(char *)NAME;
|
||||
classHint.res_class = window_class_;
|
||||
|
||||
XSetClassHint(display_default_, window_main_, &classHint);
|
||||
|
|
Loading…
Reference in a new issue