rnd-19981121-1
[rocksndiamonds.git] / src / buttons.c
index de63c630fe8f7cc15bc48cf848763487a0dbc7af..d3eb443adb263bd85aeab0bf176ed36c3c31c6d2 100644 (file)
@@ -84,6 +84,19 @@ void DrawVideoDisplay(unsigned long state, unsigned long value)
        0,0 }}
   };
 
+  if (state & VIDEO_STATE_PBEND_OFF)
+  {
+    int cx = DOOR_GFX_PAGEX3, cy = DOOR_GFX_PAGEY2;
+
+    XCopyArea(display,pix[PIX_DOOR],drawto,gc,
+             cx + VIDEO_REC_LABEL_XPOS,
+             cy + VIDEO_REC_LABEL_YPOS,
+             VIDEO_PBEND_LABEL_XSIZE,
+             VIDEO_PBEND_LABEL_YSIZE,
+             VX + VIDEO_REC_LABEL_XPOS,
+             VY + VIDEO_REC_LABEL_YPOS);
+  }
+
   for(i=0;i<20;i++)
   {
     if (state & (1<<i))
@@ -127,6 +140,19 @@ void DrawVideoDisplay(unsigned long state, unsigned long value)
              VY + VIDEO_PLAY_SYMBOL_YPOS);
   }
 
+  if (state & VIDEO_STATE_PBEND_ON)
+  {
+    int cx = DOOR_GFX_PAGEX6, cy = DOOR_GFX_PAGEY1;
+
+    XCopyArea(display,pix[PIX_DOOR],drawto,gc,
+             cx + VIDEO_PBEND_LABEL_XPOS,
+             cy + VIDEO_PBEND_LABEL_YPOS,
+             VIDEO_PBEND_LABEL_XSIZE,
+             VIDEO_PBEND_LABEL_YSIZE,
+             VX + VIDEO_REC_LABEL_XPOS,
+             VY + VIDEO_REC_LABEL_YPOS);
+  }
+
   if (state & VIDEO_STATE_DATE_ON)
   {
     int tag = value % 100;
@@ -598,9 +624,9 @@ int CheckSoundButtons(int mx, int my, int button)
   static boolean pressed = FALSE;
   int sound_state[3];
 
-  sound_state[0] = BUTTON_SOUND_MUSIC  | (BUTTON_ON * setup.sound_music_on);
-  sound_state[1] = BUTTON_SOUND_LOOPS  | (BUTTON_ON * setup.sound_loops_on);
-  sound_state[2] = BUTTON_SOUND_SIMPLE | (BUTTON_ON * setup.sound_simple_on);
+  sound_state[0] = BUTTON_SOUND_MUSIC  | (BUTTON_ON * setup.sound_music);
+  sound_state[1] = BUTTON_SOUND_LOOPS  | (BUTTON_ON * setup.sound_loops);
+  sound_state[2] = BUTTON_SOUND_SIMPLE | (BUTTON_ON * setup.sound_simple);
 
   if (button)
   {