Annotation of uae/src/include/bebox.h, revision 1.1.1.2

1.1       root        1: /* 
                      2:  * UAE - The Un*x Amiga Emulator
                      3:  *
                      4:  * BeBox port specific stuff
                      5:  * 
1.1.1.2 ! root        6:  * (c) 1996-1997 Christian Bauer
1.1       root        7:  * (c) 1996 Patrick Hanevold
                      8:  */
                      9: 
                     10: extern "C" {
                     11: #include "sysconfig.h"
                     12: #include "sysdeps.h"
                     13: #include "config.h"
                     14: #include "options.h"
1.1.1.2 ! root       15: #include "uae.h"
1.1       root       16: #include "memory.h"
                     17: #include "custom.h"
1.1.1.2 ! root       18: #include "serial.h"
        !            19: #include "readcpu.h"
1.1       root       20: #include "newcpu.h"
                     21: #include "disk.h"
                     22: #include "debug.h"
                     23: #include "xwin.h"
                     24: #include "os.h"
1.1.1.2 ! root       25: #include "events.h"
1.1       root       26: #include "keyboard.h"
1.1.1.2 ! root       27: #include "keybuf.h"
1.1       root       28: #include "gui.h"
1.1.1.2 ! root       29: #include "zfile.h"
        !            30: #include "autoconf.h"
        !            31: #include "osemu.h"
        !            32: #include "compiler.h"
1.1       root       33: }
                     34: 
                     35: class UAEWindow;
                     36: class BitmapView;
                     37: class Emulator;
                     38: 
                     39: 
                     40: /*
                     41:  *  The BeOS application object
                     42:  */
                     43: 
                     44: class UAE : public BApplication {
                     45: public:
                     46:        UAE();
                     47:        virtual void ArgvReceived(int argc, char **argv);
                     48:        virtual void ReadyToRun(void);
                     49:        virtual bool QuitRequested(void);
                     50:        virtual void AboutRequested(void);
1.1.1.2 ! root       51:        virtual void RefsReceived(BMessage *msg);
        !            52: 
        !            53:        int GraphicsInit(void);
        !            54:        void GraphicsLeave(void);
        !            55: 
1.1       root       56: private:
1.1.1.2 ! root       57:        static long thread_func(void *obj);
        !            58: 
1.1       root       59:        BBitmap *the_bitmap;
                     60:        UAEWindow *main_window;
1.1.1.2 ! root       61:        thread_id the_thread;
1.1       root       62: };
                     63: 
                     64: 
                     65: /*
                     66:  *  The window in which the Amiga graphics are displayed, handles I/O
                     67:  */
                     68: 
                     69: class UAEWindow : public BWindow {
                     70: public:
                     71:        UAEWindow(BRect frame, BBitmap *bitmap);
                     72:        virtual bool QuitRequested(void);
1.1.1.2 ! root       73:        virtual void MessageReceived(BMessage *msg);
        !            74: 
1.1       root       75: private:
1.1.1.2 ! root       76:        void request_floppy(char *title, int drive_num);
        !            77: 
1.1       root       78:        BitmapView *main_view;
                     79: };
                     80: 
1.1.1.2 ! root       81: 
1.1       root       82: /*
                     83:  *  A simple view class for blitting a bitmap on the screen
                     84:  */
                     85: 
                     86: class BitmapView : public BView {
                     87: public:
                     88:        BitmapView(BRect frame, BBitmap *bitmap);
                     89:        virtual void Draw(BRect update);
                     90:        virtual void KeyDown(ulong);
1.1.1.2 ! root       91:        virtual void MouseMoved(BPoint point, ulong transit, BMessage *message);
1.1       root       92:        void Draw(BRect from, BRect to);
1.1.1.2 ! root       93: 
1.1       root       94: private:
                     95:        BBitmap *the_bitmap;
                     96: };
                     97: 
1.1.1.2 ! root       98: 
1.1       root       99: /*
                    100:  *     LED
                    101:  */
                    102: 
                    103: class LEDView : public BView {
                    104: public:
1.1.1.2 ! root      105:        LEDView(BRect frame, rgb_color active, rgb_color idle);
        !           106:        virtual void Draw(BRect update);
        !           107:        void SetState(bool new_state);
1.1       root      108: 
                    109: private:
1.1.1.2 ! root      110:        BRect bounds;
        !           111:        rgb_color active_color;
        !           112:        rgb_color idle_color;
        !           113:        bool state;
1.1       root      114: };
                    115: 
1.1.1.2 ! root      116: 
1.1       root      117: /*
1.1.1.2 ! root      118:  *  Global variables
1.1       root      119:  */
                    120: 
                    121: // Keyboard and mouse
                    122: int buttonstate[3];
                    123: int newmousecounters;
                    124: int lastmx, lastmy;
1.1.1.2 ! root      125: int quit_program;
1.1       root      126: 
                    127: // Color map and bitmap
                    128: xcolnr xcolors[4096];
                    129: struct vidbuf_description gfxvidinfo;

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.