00001
00002
00003 #ifndef __OS_CLASS_H
00004 #define __OS_CLASS_H
00005
00006 typedef BApplication OsApplication;
00007 typedef BView *OsPainter;
00008 typedef BMenuItem *OsMenuItem;
00009
00010 class GView;
00011
00012 class LgiClass BViewRedir : public BView
00013 {
00014 void AttachedToWindow();
00015 void DetachedFromWindow();
00016 void Draw(BRect UpdateRect);
00017 void FrameMoved(BPoint Point);
00018 void FrameResized(float width, float height);
00019 void Pulse();
00020 void MessageReceived(BMessage *message);
00021 void MakeFocus(bool f = true);
00022 void KeyDown(const char *bytes, int32 numBytes);
00023 void KeyUp(const char *bytes, int32 numBytes);
00024 void MouseDown(BPoint point);
00025 void MouseUp(BPoint point);
00026 void MouseMoved(BPoint point, uint32 transit, const BMessage *message);
00027 bool QuitRequested();
00028
00029 GView *Wnd;
00030 uint32 WndBtn;
00031
00032 public:
00033 BViewRedir(GView *Wnd, uint32 Resize = B_FOLLOW_LEFT | B_FOLLOW_TOP);
00034 GView *WindowHandle() { return Wnd; }
00035 };
00036
00037 typedef BViewRedir DefaultOsView;
00038
00039 class LgiClass GWnd : public BWindow
00040 {
00041 friend class GWindow;
00042
00043 GView *Notify;
00044
00045 public:
00046 GWnd(GView *notify);
00047 GWnd(GView *notify, BRect frame, char *title, window_type type, uint32 flags, uint32 workspaces = B_CURRENT_WORKSPACE);
00048 ~GWnd();
00049
00050 bool QuitRequested();
00051 void MessageReceived(BMessage *Msg);
00052 void FrameMoved(BPoint origin);
00053 void FrameResized(float width, float height);
00054 };
00055
00056 #endif