~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~ [ freetext search ] ~ [ file search ] ~

Linux Cross Reference
Tina4/src/PCwin/tw_interrupt.cpp

Version: ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

  1 /**@(#)Interval timer handling & interupt processing.
  2   @(#)Interrupt on 'escape' key, interrupt button or '^C' press.
  3 **/
  4 
  5 #include <stdio.h>
  6 
  7 #include <dibapi.h>
  8 
  9 #ifdef __cplusplus
 10 extern "C" {
 11 #endif  /* __cplusplus */
 12 #include <tina/sys.h>
 13 #include <tina/sysfuncs.h>
 14 #include <tina/tv.h>
 15 #include <tina/tv_screen.h>
 16 #ifdef __cplusplus
 17 }
 18 #endif  /* __cplusplus */
 19 
 20 extern void (*screen_text) (char *);
 21 #define Print(x)  if(screen_text!=NULL) screen_text(x)
 22 
 23 
 24 
 25 /* Interrupt lengthy processing and return to event read/dispatch loop */
 26 extern "C" void abandon(void)
 27 {
 28     Print("abandon?");
 29 }
 30 
 31 /* Handle alarm signals. Ie SIGALRM (from timer). */
 32 /* ARGSUSED Quieten lint */
 33 /* void    alarm_handler(int sig, int code, void *scp, char *addr) */
 34 extern "C" void alarm_handler(int sig, int code)
 35 {
 36     Print("alarm_handler?");
 37 }
 38 
 39 
 40 /* Check for interrupts (escape key, interrupt button, ^C). Return true
 41  * iff interruptible is true AND interrupt found. NB only detects ^C &
 42  * escape button presses IF interrupt_button has been created. */
 43 extern "C" Bool interrupt_check(void)
 44 {
 45     Print("interrupt_check?");
 46     return (Bool) (NULL);
 47 }
 48 
 49 /* Handle interrupt signals.  Ie SIGINT (^C) */
 50 /* ARGSUSED Quieten lint */
 51 extern "C" void interrupt_handler(int sig, int code, void *scp, char 
 52 *addr)
 53 {
 54     Print("interrupt_handler?");
 55 }
 56 
 57 
 58 /* Start timer to interrupt program every second.  The alarm_handler
 59  * catches alarm signals and ^C (SIGINT).  */
 60 static void itimer_start(void)
 61 {
 62     Print("itimer_start?");
 63 }
 64 
 65 /* STOP timer.  */
 66 static void itimer_stop(void)
 67 {
 68     Print("itimer_stop?");
 69 
 70 }
 71 
 72 
 73 /* Toggle X synchronisation.  When on, X is unbuffered, errors are
 74  * reported immediately but runs much slower. */
 75 extern "C" void toggle_sync(void)
 76 {
 77     extern Display *tw_get_display();
 78     static int sync = 1;
 79 
 80     Print("toggle_sync?");
 81 }
 82 

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~ [ freetext search ] ~ [ file search ] ~

This page was automatically generated by the LXR engine.
Visit the LXR main site for more information.