Usermode - Removed axwin2 (completly defunct)
authorJohn Hodge <[email protected]>
Wed, 1 Aug 2012 01:11:20 +0000 (09:11 +0800)
committerJohn Hodge <[email protected]>
Wed, 1 Aug 2012 01:11:20 +0000 (09:11 +0800)
32 files changed:
Notes/SIF.txt [new file with mode: 0644]
Usermode/Applications/axwin2_src/Makefile [deleted file]
Usermode/Applications/axwin2_src/SIF.txt [deleted file]
Usermode/Applications/axwin2_src/Shell_src/Makefile [deleted file]
Usermode/Applications/axwin2_src/Shell_src/main.c [deleted file]
Usermode/Applications/axwin2_src/WM/Makefile [deleted file]
Usermode/Applications/axwin2_src/WM/commandline.c [deleted file]
Usermode/Applications/axwin2_src/WM/common.h [deleted file]
Usermode/Applications/axwin2_src/WM/decorator.c [deleted file]
Usermode/Applications/axwin2_src/WM/font_8x16.h [deleted file]
Usermode/Applications/axwin2_src/WM/helpers.c [deleted file]
Usermode/Applications/axwin2_src/WM/image.c [deleted file]
Usermode/Applications/axwin2_src/WM/image.h [deleted file]
Usermode/Applications/axwin2_src/WM/input.c [deleted file]
Usermode/Applications/axwin2_src/WM/interface.c [deleted file]
Usermode/Applications/axwin2_src/WM/main.c [deleted file]
Usermode/Applications/axwin2_src/WM/messages.c [deleted file]
Usermode/Applications/axwin2_src/WM/render.c [deleted file]
Usermode/Applications/axwin2_src/WM/resources/LogoSmall.sif [deleted file]
Usermode/Applications/axwin2_src/WM/resources/cursor.h [deleted file]
Usermode/Applications/axwin2_src/WM/video.c [deleted file]
Usermode/Applications/axwin2_src/WM/video_text.c [deleted file]
Usermode/Applications/axwin2_src/WM/wm.c [deleted file]
Usermode/Applications/axwin2_src/WM/wm.h [deleted file]
Usermode/Applications/axwin2_src/notes.txt [deleted file]
Usermode/Libraries/libaxwin2.so_src/Makefile [deleted file]
Usermode/Libraries/libaxwin2.so_src/common.h [deleted file]
Usermode/Libraries/libaxwin2.so_src/include_exp/axwin2/axwin.h [deleted file]
Usermode/Libraries/libaxwin2.so_src/include_exp/axwin2/messages.h [deleted file]
Usermode/Libraries/libaxwin2.so_src/main.c [deleted file]
Usermode/Libraries/libaxwin2.so_src/messages.c [deleted file]
Usermode/Libraries/libaxwin2.so_src/windows.c [deleted file]

diff --git a/Notes/SIF.txt b/Notes/SIF.txt
new file mode 100644 (file)
index 0000000..57c1fa7
--- /dev/null
@@ -0,0 +1,28 @@
+=== Simple Image Format ===
+
+U16    Magic   0x51F0  - This determines the endianness of the file
+U16    Flags
+       > 0-2: Compression (0: Uncompressed, 1: RLE, 2: zlib, 3: RLE-Channel)
+       > 3-5: Format (0: ARGB, 1: RGB
+U16    Width
+U16    Height
+<DATA>
+
+
+=== Compression Formats ===
+0 - Uncompressed
+       The file data is a linear sequence of Width * Height 32-bit ARGB
+       words (in file endianness, determined by the magic)
+
+1 - RLE-4
+       7-bit length followed by a 32-bit value that is repeated `n` times
+       (if bit 7 of the length byte is set, the next `n` 32-bit words are
+       verbatim)
+
+2 - zlib
+       The image data is a zlib stream of 32-bit xRGB words
+
+3 - RLE-Channel
+       The data is the alpha values, followed by red, then green, then blue
+       encoded as RLE with a 7-bit length and a verbatim flag (same as mode
+       1, except with 8-bit values instead of 32-bit) 
diff --git a/Usermode/Applications/axwin2_src/Makefile b/Usermode/Applications/axwin2_src/Makefile
deleted file mode 100644 (file)
index 89f1584..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-
-NAME = AxWin2
-DIRS = WM Shell_src
-
-SUBMAKE = $(MAKE) --no-print-directory
-
-all:
-       @$(foreach DIR,$(DIRS), echo --- $(NAME)/$(DIR) && $(SUBMAKE) -C $(DIR) $@ &&) true
-install:
-       @$(foreach DIR,$(DIRS), echo --- $(NAME)/$(DIR) && $(SUBMAKE) -C $(DIR) $@ &&) true
-
-clean:
-       @$(foreach DIR,$(DIRS), $(SUBMAKE) -C $(DIR) $@ &&) true
diff --git a/Usermode/Applications/axwin2_src/SIF.txt b/Usermode/Applications/axwin2_src/SIF.txt
deleted file mode 100644 (file)
index 57c1fa7..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-=== Simple Image Format ===
-
-U16    Magic   0x51F0  - This determines the endianness of the file
-U16    Flags
-       > 0-2: Compression (0: Uncompressed, 1: RLE, 2: zlib, 3: RLE-Channel)
-       > 3-5: Format (0: ARGB, 1: RGB
-U16    Width
-U16    Height
-<DATA>
-
-
-=== Compression Formats ===
-0 - Uncompressed
-       The file data is a linear sequence of Width * Height 32-bit ARGB
-       words (in file endianness, determined by the magic)
-
-1 - RLE-4
-       7-bit length followed by a 32-bit value that is repeated `n` times
-       (if bit 7 of the length byte is set, the next `n` 32-bit words are
-       verbatim)
-
-2 - zlib
-       The image data is a zlib stream of 32-bit xRGB words
-
-3 - RLE-Channel
-       The data is the alpha values, followed by red, then green, then blue
-       encoded as RLE with a 7-bit length and a verbatim flag (same as mode
-       1, except with 8-bit values instead of 32-bit) 
diff --git a/Usermode/Applications/axwin2_src/Shell_src/Makefile b/Usermode/Applications/axwin2_src/Shell_src/Makefile
deleted file mode 100644 (file)
index 55744b9..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-# Project: Acess GUI Default Shell
-
--include ../../Makefile.cfg
-
-CPPFLAGS +=
-LDFLAGS += -laxwin2
-
-DIR = Apps/AxWin/1.0
-BIN = Shell
-OBJ = main.o
-
--include ../../Makefile.tpl
diff --git a/Usermode/Applications/axwin2_src/Shell_src/main.c b/Usermode/Applications/axwin2_src/Shell_src/main.c
deleted file mode 100644 (file)
index f1c0416..0000000
+++ /dev/null
@@ -1,72 +0,0 @@
-/*
- * Acess2 GUI Test App
- * - By John Hodge (thePowersGang)
- */
-#include <axwin2/axwin.h>
-#include <stdlib.h>
-#include <stdio.h>
-
-// === CONSTANTS ===
-enum eTerminal_Events
-{
-       EVENT_NULL,
-       EVENT_NEW_TAB,
-       EVENT_CLOSE_TAB,
-       EVENT_EXIT
-};
-
-// === PROTOTYPES ===
- int   main(int argc, char *argv[]);
- int   Global_HandleMessage(tAxWin_Message *Message);
- int   Shell_HandleMessage(tAxWin_Message *Message);
-
-// === GLOBALS ===
-tAxWin_Element *geConsole;
-
-// === CODE ===
-int main(int argc, char *argv[])
-{
-       tAxWin_Element  *menu, *tab;
-       
-       if(argc != 1)
-       {
-               fprintf(stderr, "Usage: %s\n", argv[0]);
-               fprintf(stderr, "\tThis application takes no arguments\n");
-               return 0;
-       }
-
-       AxWin_Register("Terminal", Global_HandleMessage);
-
-       menu = AxWin_AddMenuItem(NULL, "File", 0);
-       AxWin_AddMenuItem(menu, "&New Tab\tCtrl-Shift-N", EVENT_NEW_TAB);
-       AxWin_AddMenuItem(menu, NULL, 0);
-       AxWin_AddMenuItem(menu, "&Close Tab\tCtrl-Shift-W", EVENT_CLOSE_TAB);
-       AxWin_AddMenuItem(menu, "E&xit\tAlt-F4", EVENT_EXIT);
-
-       tab = AxWin_CreateWindow("root@acess: ~");
-       //geConsole = AxWin_CreateElement();
-       
-       AxWin_MessageLoop();
-       
-       return 0;
-}
-
-/**
- */
-int Global_HandleMessage(tAxWin_Message *Message)
-{
-       switch(Message->ID)
-       {
-       default:
-               return 0;
-       }
-}
-
-int Shell_HandleMessage(tAxWin_Message *Message)
-{
-       switch(Message->ID)
-       {
-       default:
-               return 0;
-       }
-}
diff --git a/Usermode/Applications/axwin2_src/WM/Makefile b/Usermode/Applications/axwin2_src/WM/Makefile
deleted file mode 100644 (file)
index 19687e1..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-# Project: Acess GUI Window Manager
-
--include ../../Makefile.cfg
-
-CPPFLAGS += 
-
-DIR := Apps/AxWin/1.0
-BIN := AxWinWM
-OBJ := main.o helpers.o commandline.o video.o input.o video_text.o
-OBJ += messages.o interface.o wm.o decorator.o render.o
-OBJ += image.o
-
-LDFLAGS += -limage_sif -luri -lnet
-
--include ../../Makefile.tpl
-
-all: resources/LogoSmall.sif.res.h
-
-%.res.h: % Makefile
-       echo "#define RESOURCE_$(notdir $<) \\"| sed -e 's/\./_/g' > $@
-       base64 $< | sed -e 's/.*/"&"\\/' >> $@
-       echo "" >> $@
diff --git a/Usermode/Applications/axwin2_src/WM/commandline.c b/Usermode/Applications/axwin2_src/WM/commandline.c
deleted file mode 100644 (file)
index 67db574..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#include "common.h"
-#include <string.h>
-
-// === PROTOTYPES ===
-void   ShowUsage(char *ProgName);
-void   ShowHelp(char *ProgName);
-
-// === CODE ===
-void ParseCommandline(int argc, char *argv[])
-{
-        int    i;
-       char    *arg;
-       
-       for( i = 1; i < argc; i++ )
-       {
-               arg = argv[i];
-               if(arg[0] == '-')
-               {
-                       if( arg[1] == '-' )
-                       {
-                               if( strcmp(&arg[2], "help") == 0 ) {
-                                       ShowHelp(argv[0]);
-                                       exit(EXIT_SUCCESS);
-                               }
-                               else {
-                                       ShowUsage(argv[0]);
-                                       exit(EXIT_FAILURE);
-                               }
-                       }
-                       else
-                       {
-                               while( *++arg )
-                               {
-                                       switch(*arg)
-                                       {
-                                       case 'h':
-                                       case '?':
-                                               ShowHelp(argv[0]);
-                                               exit(EXIT_SUCCESS);
-                                               break;
-                                       default:
-                                               break;
-                                       }
-                               }
-                       }
-               }
-       }
-}
-
-void ShowUsage(char *ProgName)
-{
-       fprintf(stderr, "Usage: %s [-h|--help]\n", ProgName);
-}
-
-void ShowHelp(char *ProgName)
-{
-       ShowUsage(ProgName);
-       fprintf(stderr, "\n");
-       fprintf(stderr, "\t--help\tShow this message\n");
-}
diff --git a/Usermode/Applications/axwin2_src/WM/common.h b/Usermode/Applications/axwin2_src/WM/common.h
deleted file mode 100644 (file)
index b00d697..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#ifndef _COMMON_H_
-#define _COMMON_H_
-
-#include <stdlib.h>
-#include <stdio.h>
-#include <stdint.h>
-#include <acess/sys.h> // _SysDebug
-
-// === TYPES ===
-typedef struct sIPC_Type       tIPC_Type;
-typedef struct sFont   tFont;
-
-struct sIPC_Type
-{
-        int    (*GetIdentSize)(void *Ident);
-        int    (*CompareIdent)(void *Ident1, void *Ident2);
-       void    (*SendMessage)(void *Ident, size_t, void *Data);
-};
-
-#include "wm.h"
-#include "image.h"
-//#include "font.h"
-
-// === MACROS ===
-static inline uint32_t Video_AlphaBlend(uint32_t _orig, uint32_t _new, uint8_t _alpha)
-{
-       uint16_t        ao,ro,go,bo;
-       uint16_t        an,rn,gn,bn;
-       if( _alpha == 0 )       return _orig;
-       if( _alpha == 255 )     return _new;
-       
-       ao = (_orig >> 24) & 0xFF;
-       ro = (_orig >> 16) & 0xFF;
-       go = (_orig >>  8) & 0xFF;
-       bo = (_orig >>  0) & 0xFF;
-       
-       an = (_new >> 24) & 0xFF;
-       rn = (_new >> 16) & 0xFF;
-       gn = (_new >>  8) & 0xFF;
-       bn = (_new >>  0) & 0xFF;
-
-       if( _alpha == 0x80 ) {
-               ao = (ao + an) / 2;
-               ro = (ro + rn) / 2;
-               go = (go + gn) / 2;
-               bo = (bo + bn) / 2;
-       }
-       else {
-               ao = ao*(255-_alpha) + an*_alpha;
-               ro = ro*(255-_alpha) + rn*_alpha;
-               go = go*(255-_alpha) + gn*_alpha;
-               bo = bo*(255-_alpha) + bn*_alpha;
-               ao /= 255*2;
-               ro /= 255*2;
-               go /= 255*2;
-               bo /= 255*2;
-       }
-
-       return (ao << 24) | (ro << 16) | (go << 8) | bo;
-}
-
-// === GLOBALS ===
-extern const char      *gsTerminalDevice;
-extern const char      *gsMouseDevice;
-
-extern int     giScreenWidth;
-extern int     giScreenHeight;
-extern uint32_t        *gpScreenBuffer;
-
-extern int     giTerminalFD;
-extern int     giMouseFD;
-
-// === Functions ===
-extern void    memset32(void *ptr, uint32_t val, size_t count);
-// --- Initialisation ---
-extern void    ParseCommandline(int argc, char *argv[]);
-// --- Messages / IPC ---
-extern void    IPC_Init(void);
-extern void    IPC_FillSelect(int *nfds, fd_set *set);
-extern void    IPC_HandleSelect(fd_set *set);
-// --- Input ---
-extern void    Input_FillSelect(int *nfds, fd_set *set);
-extern void    Input_HandleSelect(fd_set *set);
-// --- Local WM ---
-extern tApplication    *AxWin_RegisterClient(tIPC_Type *Method, void *Ident, const char *Name);
-extern void    AxWin_DeregisterClient(tApplication *App);
-extern tApplication    *AxWin_GetClient(tIPC_Type *Method, void *Ident);
-extern tElement        *AxWin_CreateAppWindow(tApplication *App, const char *Name);
-// --- Video ---
-extern void    Video_Setup(void);
-extern void    Video_SetCursorPos(short X, short Y);
-extern void    Video_Update(void);
-extern void    Video_FillRect(short X, short Y, short W, short H, uint32_t Color);
-extern void    Video_DrawRect(short X, short Y, short W, short H, uint32_t Color);
-extern int     Video_DrawText(short X, short Y, short W, short H, tFont *Font, uint32_t Color, char *Text);
-extern void    Video_DrawImage(short X, short Y, short W, short H, tImage *Image);
-// --- Interface ---
-extern void    Interface_Init(void);
-extern void    Interface_Update(void);
-extern void    Interface_Render(void);
-// --- Decorator ---
-extern void    Decorator_RenderWidget(tElement *Element);
-
-#endif
diff --git a/Usermode/Applications/axwin2_src/WM/decorator.c b/Usermode/Applications/axwin2_src/WM/decorator.c
deleted file mode 100644 (file)
index 171b526..0000000
+++ /dev/null
@@ -1,108 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- * 
- * Widget Decorator
- */
-#include "common.h"
-#include "wm.h"
-
-#define BORDER_EVERYTHING      1
-
-#define BOX_BGCOLOUR    0xC0C0C0
-#define BOX_BORDER      0xA0A0A0
-#define BUTTON_BGCOLOUR 0xD0D0D0
-#define BUTTON_BORDER   0xF0F0F0
-#define        TEXT_COLOUR     0x000000
-
-// === CODE ===
-void Decorator_RenderWidget(tElement *Element)
-{
-       _SysDebug("Decorator_RenderWidget: (Element={Type:%i,(%i,%i) %ix%i})",
-               Element->Type,
-               Element->CachedX, Element->CachedY,
-               Element->CachedW, Element->CachedH
-               );
-       
-       #if BORDER_EVERYTHING
-       Video_DrawRect(Element->CachedX, Element->CachedY,
-                       Element->CachedW, Element->CachedH,
-                       0
-                       );
-       #endif
-       
-       switch(Element->Type)
-       {
-       case ELETYPE_NONE:
-       case ELETYPE_BOX:       break;  // Box is a meta-element
-       
-       case ELETYPE_TABBAR:    // Tab Bar
-               Video_DrawRect(
-                       Element->CachedX, Element->CachedY,
-                       Element->CachedW, Element->CachedH,
-                       BOX_BORDER
-                       );
-               Video_FillRect(
-                       Element->CachedX+1, Element->CachedY+1,
-                       Element->CachedW-2, Element->CachedH-2,
-                       BOX_BGCOLOUR
-                       );
-               // Enumerate Items.
-               break;
-       case ELETYPE_TOOLBAR:   // Tool Bar
-               Video_DrawRect(
-                       Element->CachedX, Element->CachedY,
-                       Element->CachedW, Element->CachedH,
-                       BOX_BORDER
-                       );
-               Video_FillRect(
-                       Element->CachedX+1, Element->CachedY+1,
-                       Element->CachedW-2, Element->CachedH-2,
-                       BOX_BGCOLOUR
-                       );
-               break;
-       
-       case ELETYPE_SPACER:    // Spacer (subtle line)
-               Video_FillRect(
-                       Element->CachedX+3, Element->CachedY+3,
-                       Element->CachedW-6, Element->CachedH-6,
-                       BOX_BORDER
-                       );
-               break;
-       
-       case ELETYPE_BUTTON:    // Button
-               Video_FillRect(
-                       Element->CachedX+1, Element->CachedY+1,
-                       Element->CachedW-2, Element->CachedH-2,
-                       BUTTON_BGCOLOUR
-                       );
-               Video_DrawRect(
-                       Element->CachedX, Element->CachedY,
-                       Element->CachedW-1, Element->CachedH-1,
-                       BUTTON_BORDER
-                       );
-               break;
-       
-       case ELETYPE_TEXT:
-               Video_DrawText(
-                       Element->CachedX+1, Element->CachedY+1,
-                       Element->CachedW-2, Element->CachedH-2,
-                       NULL,
-                       TEXT_COLOUR,
-                       Element->Text
-                       );
-               break;
-       
-       case ELETYPE_IMAGE:
-               Video_DrawImage(
-                       Element->CachedX, Element->CachedY,
-                       Element->CachedW, Element->CachedH,
-                       Element->Data
-                       );
-               break;
-               
-       default:
-               _SysDebug(" ERROR: Unknown type %i", Element->Type);
-               break;
-       }
-}
diff --git a/Usermode/Applications/axwin2_src/WM/font_8x16.h b/Usermode/Applications/axwin2_src/WM/font_8x16.h
deleted file mode 100644 (file)
index b9bad5d..0000000
+++ /dev/null
@@ -1,265 +0,0 @@
-/*
- * Taken from http://cvs.savannah.gnu.org/viewvc/vgabios/vgafonts.h?root=vgabios&view=markup
- * Altered for Acess2
- */
-#define FONT_WIDTH     8
-#define FONT_HEIGHT    16
-static uint8_t VTermFont[256*16]=
-{
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7e, 0x81, 0xa5, 0x81, 0x81, 0xbd, 0x99, 0x81, 0x81, 0x7e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7e, 0xff, 0xdb, 0xff, 0xff, 0xc3, 0xe7, 0xff, 0xff, 0x7e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x6c, 0xfe, 0xfe, 0xfe, 0xfe, 0x7c, 0x38, 0x10, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x10, 0x38, 0x7c, 0xfe, 0x7c, 0x38, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x18, 0x3c, 0x3c, 0xe7, 0xe7, 0xe7, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x18, 0x3c, 0x7e, 0xff, 0xff, 0x7e, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x3c, 0x3c, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xe7, 0xc3, 0xc3, 0xe7, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x3c, 0x66, 0x42, 0x42, 0x66, 0x3c, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0xff, 0xff, 0xff, 0xff, 0xff, 0xc3, 0x99, 0xbd, 0xbd, 0x99, 0xc3, 0xff, 0xff, 0xff, 0xff, 0xff,
-       0x00, 0x00, 0x1e, 0x0e, 0x1a, 0x32, 0x78, 0xcc, 0xcc, 0xcc, 0xcc, 0x78, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3c, 0x66, 0x66, 0x66, 0x66, 0x3c, 0x18, 0x7e, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3f, 0x33, 0x3f, 0x30, 0x30, 0x30, 0x30, 0x70, 0xf0, 0xe0, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7f, 0x63, 0x7f, 0x63, 0x63, 0x63, 0x63, 0x67, 0xe7, 0xe6, 0xc0, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x18, 0x18, 0xdb, 0x3c, 0xe7, 0x3c, 0xdb, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x80, 0xc0, 0xe0, 0xf0, 0xf8, 0xfe, 0xf8, 0xf0, 0xe0, 0xc0, 0x80, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x02, 0x06, 0x0e, 0x1e, 0x3e, 0xfe, 0x3e, 0x1e, 0x0e, 0x06, 0x02, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x3c, 0x7e, 0x18, 0x18, 0x18, 0x7e, 0x3c, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x00, 0x66, 0x66, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7f, 0xdb, 0xdb, 0xdb, 0x7b, 0x1b, 0x1b, 0x1b, 0x1b, 0x1b, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x7c, 0xc6, 0x60, 0x38, 0x6c, 0xc6, 0xc6, 0x6c, 0x38, 0x0c, 0xc6, 0x7c, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xfe, 0xfe, 0xfe, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x3c, 0x7e, 0x18, 0x18, 0x18, 0x7e, 0x3c, 0x18, 0x7e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x3c, 0x7e, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x7e, 0x3c, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x0c, 0xfe, 0x0c, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x60, 0xfe, 0x60, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0xc0, 0xc0, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x66, 0xff, 0x66, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x10, 0x38, 0x38, 0x7c, 0x7c, 0xfe, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0xfe, 0xfe, 0x7c, 0x7c, 0x38, 0x38, 0x10, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x3c, 0x3c, 0x3c, 0x18, 0x18, 0x18, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x66, 0x66, 0x66, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x6c, 0x6c, 0xfe, 0x6c, 0x6c, 0x6c, 0xfe, 0x6c, 0x6c, 0x00, 0x00, 0x00, 0x00,
-       0x18, 0x18, 0x7c, 0xc6, 0xc2, 0xc0, 0x7c, 0x06, 0x06, 0x86, 0xc6, 0x7c, 0x18, 0x18, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0xc2, 0xc6, 0x0c, 0x18, 0x30, 0x60, 0xc6, 0x86, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x38, 0x6c, 0x6c, 0x38, 0x76, 0xdc, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x30, 0x30, 0x30, 0x60, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x0c, 0x18, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x18, 0x0c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x30, 0x18, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x18, 0x30, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x66, 0x3c, 0xff, 0x3c, 0x66, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x7e, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x18, 0x30, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x02, 0x06, 0x0c, 0x18, 0x30, 0x60, 0xc0, 0x80, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3c, 0x66, 0xc3, 0xc3, 0xdb, 0xdb, 0xc3, 0xc3, 0x66, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x38, 0x78, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x7e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7c, 0xc6, 0x06, 0x0c, 0x18, 0x30, 0x60, 0xc0, 0xc6, 0xfe, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7c, 0xc6, 0x06, 0x06, 0x3c, 0x06, 0x06, 0x06, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x0c, 0x1c, 0x3c, 0x6c, 0xcc, 0xfe, 0x0c, 0x0c, 0x0c, 0x1e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xfe, 0xc0, 0xc0, 0xc0, 0xfc, 0x06, 0x06, 0x06, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x38, 0x60, 0xc0, 0xc0, 0xfc, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xfe, 0xc6, 0x06, 0x06, 0x0c, 0x18, 0x30, 0x30, 0x30, 0x30, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0x7e, 0x06, 0x06, 0x06, 0x0c, 0x78, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x18, 0x18, 0x30, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x06, 0x0c, 0x18, 0x30, 0x60, 0x30, 0x18, 0x0c, 0x06, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x60, 0x30, 0x18, 0x0c, 0x06, 0x0c, 0x18, 0x30, 0x60, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7c, 0xc6, 0xc6, 0x0c, 0x18, 0x18, 0x18, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xde, 0xde, 0xde, 0xdc, 0xc0, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x10, 0x38, 0x6c, 0xc6, 0xc6, 0xfe, 0xc6, 0xc6, 0xc6, 0xc6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xfc, 0x66, 0x66, 0x66, 0x7c, 0x66, 0x66, 0x66, 0x66, 0xfc, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3c, 0x66, 0xc2, 0xc0, 0xc0, 0xc0, 0xc0, 0xc2, 0x66, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xf8, 0x6c, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x6c, 0xf8, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xfe, 0x66, 0x62, 0x68, 0x78, 0x68, 0x60, 0x62, 0x66, 0xfe, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xfe, 0x66, 0x62, 0x68, 0x78, 0x68, 0x60, 0x60, 0x60, 0xf0, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3c, 0x66, 0xc2, 0xc0, 0xc0, 0xde, 0xc6, 0xc6, 0x66, 0x3a, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc6, 0xc6, 0xc6, 0xc6, 0xfe, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3c, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x1e, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0xcc, 0xcc, 0xcc, 0x78, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xe6, 0x66, 0x66, 0x6c, 0x78, 0x78, 0x6c, 0x66, 0x66, 0xe6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xf0, 0x60, 0x60, 0x60, 0x60, 0x60, 0x60, 0x62, 0x66, 0xfe, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc3, 0xe7, 0xff, 0xff, 0xdb, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc6, 0xe6, 0xf6, 0xfe, 0xde, 0xce, 0xc6, 0xc6, 0xc6, 0xc6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xfc, 0x66, 0x66, 0x66, 0x7c, 0x60, 0x60, 0x60, 0x60, 0xf0, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xd6, 0xde, 0x7c, 0x0c, 0x0e, 0x00, 0x00,
-       0x00, 0x00, 0xfc, 0x66, 0x66, 0x66, 0x7c, 0x6c, 0x66, 0x66, 0x66, 0xe6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x7c, 0xc6, 0xc6, 0x60, 0x38, 0x0c, 0x06, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xff, 0xdb, 0x99, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0x66, 0x3c, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc3, 0xc3, 0xc3, 0xc3, 0xc3, 0xdb, 0xdb, 0xff, 0x66, 0x66, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc3, 0xc3, 0x66, 0x3c, 0x18, 0x18, 0x3c, 0x66, 0xc3, 0xc3, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc3, 0xc3, 0xc3, 0x66, 0x3c, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xff, 0xc3, 0x86, 0x0c, 0x18, 0x30, 0x60, 0xc1, 0xc3, 0xff, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3c, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x30, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x80, 0xc0, 0xe0, 0x70, 0x38, 0x1c, 0x0e, 0x06, 0x02, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x10, 0x38, 0x6c, 0xc6, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00,
-       0x30, 0x30, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x78, 0x0c, 0x7c, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xe0, 0x60, 0x60, 0x78, 0x6c, 0x66, 0x66, 0x66, 0x66, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0xc6, 0xc0, 0xc0, 0xc0, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x1c, 0x0c, 0x0c, 0x3c, 0x6c, 0xcc, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0xc6, 0xfe, 0xc0, 0xc0, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x38, 0x6c, 0x64, 0x60, 0xf0, 0x60, 0x60, 0x60, 0x60, 0xf0, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0x7c, 0x0c, 0xcc, 0x78, 0x00,
-       0x00, 0x00, 0xe0, 0x60, 0x60, 0x6c, 0x76, 0x66, 0x66, 0x66, 0x66, 0xe6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x18, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x06, 0x06, 0x00, 0x0e, 0x06, 0x06, 0x06, 0x06, 0x06, 0x06, 0x66, 0x66, 0x3c, 0x00,
-       0x00, 0x00, 0xe0, 0x60, 0x60, 0x66, 0x6c, 0x78, 0x78, 0x6c, 0x66, 0xe6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xe6, 0xff, 0xdb, 0xdb, 0xdb, 0xdb, 0xdb, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xdc, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xdc, 0x66, 0x66, 0x66, 0x66, 0x66, 0x7c, 0x60, 0x60, 0xf0, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0x7c, 0x0c, 0x0c, 0x1e, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xdc, 0x76, 0x66, 0x60, 0x60, 0x60, 0xf0, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x7c, 0xc6, 0x60, 0x38, 0x0c, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x10, 0x30, 0x30, 0xfc, 0x30, 0x30, 0x30, 0x30, 0x36, 0x1c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xc3, 0xc3, 0xc3, 0xc3, 0x66, 0x3c, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xc3, 0xc3, 0xc3, 0xdb, 0xdb, 0xff, 0x66, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xc3, 0x66, 0x3c, 0x18, 0x3c, 0x66, 0xc3, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7e, 0x06, 0x0c, 0xf8, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xcc, 0x18, 0x30, 0x60, 0xc6, 0xfe, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x0e, 0x18, 0x18, 0x18, 0x70, 0x18, 0x18, 0x18, 0x18, 0x0e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x18, 0x18, 0x18, 0x00, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x70, 0x18, 0x18, 0x18, 0x0e, 0x18, 0x18, 0x18, 0x18, 0x70, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x76, 0xdc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x10, 0x38, 0x6c, 0xc6, 0xc6, 0xc6, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3c, 0x66, 0xc2, 0xc0, 0xc0, 0xc0, 0xc2, 0x66, 0x3c, 0x0c, 0x06, 0x7c, 0x00, 0x00,
-       0x00, 0x00, 0xcc, 0x00, 0x00, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x0c, 0x18, 0x30, 0x00, 0x7c, 0xc6, 0xfe, 0xc0, 0xc0, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x10, 0x38, 0x6c, 0x00, 0x78, 0x0c, 0x7c, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xcc, 0x00, 0x00, 0x78, 0x0c, 0x7c, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x60, 0x30, 0x18, 0x00, 0x78, 0x0c, 0x7c, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x38, 0x6c, 0x38, 0x00, 0x78, 0x0c, 0x7c, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x3c, 0x66, 0x60, 0x60, 0x66, 0x3c, 0x0c, 0x06, 0x3c, 0x00, 0x00, 0x00,
-       0x00, 0x10, 0x38, 0x6c, 0x00, 0x7c, 0xc6, 0xfe, 0xc0, 0xc0, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc6, 0x00, 0x00, 0x7c, 0xc6, 0xfe, 0xc0, 0xc0, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x60, 0x30, 0x18, 0x00, 0x7c, 0xc6, 0xfe, 0xc0, 0xc0, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x66, 0x00, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x18, 0x3c, 0x66, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x60, 0x30, 0x18, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0xc6, 0x00, 0x10, 0x38, 0x6c, 0xc6, 0xc6, 0xfe, 0xc6, 0xc6, 0xc6, 0x00, 0x00, 0x00, 0x00,
-       0x38, 0x6c, 0x38, 0x00, 0x38, 0x6c, 0xc6, 0xc6, 0xfe, 0xc6, 0xc6, 0xc6, 0x00, 0x00, 0x00, 0x00,
-       0x18, 0x30, 0x60, 0x00, 0xfe, 0x66, 0x60, 0x7c, 0x60, 0x60, 0x66, 0xfe, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x6e, 0x3b, 0x1b, 0x7e, 0xd8, 0xdc, 0x77, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x3e, 0x6c, 0xcc, 0xcc, 0xfe, 0xcc, 0xcc, 0xcc, 0xcc, 0xce, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x10, 0x38, 0x6c, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc6, 0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x60, 0x30, 0x18, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x30, 0x78, 0xcc, 0x00, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x60, 0x30, 0x18, 0x00, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc6, 0x00, 0x00, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7e, 0x06, 0x0c, 0x78, 0x00,
-       0x00, 0xc6, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0xc6, 0x00, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x18, 0x18, 0x7e, 0xc3, 0xc0, 0xc0, 0xc0, 0xc3, 0x7e, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x38, 0x6c, 0x64, 0x60, 0xf0, 0x60, 0x60, 0x60, 0x60, 0xe6, 0xfc, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xc3, 0x66, 0x3c, 0x18, 0xff, 0x18, 0xff, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0xfc, 0x66, 0x66, 0x7c, 0x62, 0x66, 0x6f, 0x66, 0x66, 0x66, 0xf3, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x0e, 0x1b, 0x18, 0x18, 0x18, 0x7e, 0x18, 0x18, 0x18, 0x18, 0x18, 0xd8, 0x70, 0x00, 0x00,
-       0x00, 0x18, 0x30, 0x60, 0x00, 0x78, 0x0c, 0x7c, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x0c, 0x18, 0x30, 0x00, 0x38, 0x18, 0x18, 0x18, 0x18, 0x18, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x18, 0x30, 0x60, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x18, 0x30, 0x60, 0x00, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0xcc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x76, 0xdc, 0x00, 0xdc, 0x66, 0x66, 0x66, 0x66, 0x66, 0x66, 0x00, 0x00, 0x00, 0x00,
-       0x76, 0xdc, 0x00, 0xc6, 0xe6, 0xf6, 0xfe, 0xde, 0xce, 0xc6, 0xc6, 0xc6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x3c, 0x6c, 0x6c, 0x3e, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x38, 0x6c, 0x6c, 0x38, 0x00, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x30, 0x30, 0x00, 0x30, 0x30, 0x60, 0xc0, 0xc6, 0xc6, 0x7c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0xc0, 0xc0, 0xc0, 0xc0, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x06, 0x06, 0x06, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0xc0, 0xc0, 0xc2, 0xc6, 0xcc, 0x18, 0x30, 0x60, 0xce, 0x9b, 0x06, 0x0c, 0x1f, 0x00, 0x00,
-       0x00, 0xc0, 0xc0, 0xc2, 0xc6, 0xcc, 0x18, 0x30, 0x66, 0xce, 0x96, 0x3e, 0x06, 0x06, 0x00, 0x00,
-       0x00, 0x00, 0x18, 0x18, 0x00, 0x18, 0x18, 0x18, 0x3c, 0x3c, 0x3c, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x36, 0x6c, 0xd8, 0x6c, 0x36, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xd8, 0x6c, 0x36, 0x6c, 0xd8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44, 0x11, 0x44,
-       0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa,
-       0xdd, 0x77, 0xdd, 0x77, 0xdd, 0x77, 0xdd, 0x77, 0xdd, 0x77, 0xdd, 0x77, 0xdd, 0x77, 0xdd, 0x77,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xf8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0xf8, 0x18, 0xf8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xf6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x18, 0xf8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0xf6, 0x06, 0xf6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x06, 0xf6, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0xf6, 0x06, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0xf8, 0x18, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x1f, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xff, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x1f, 0x18, 0x1f, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x30, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x30, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0xf7, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xf7, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x37, 0x30, 0x37, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0xf7, 0x00, 0xf7, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0xff, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x00, 0xff, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x3f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x1f, 0x18, 0x1f, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x18, 0x1f, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x3f, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0xff, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36, 0x36,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0xff, 0x18, 0xff, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1f, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff,
-       0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0, 0xf0,
-       0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f, 0x0f,
-       0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0xdc, 0xd8, 0xd8, 0xd8, 0xdc, 0x76, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x78, 0xcc, 0xcc, 0xcc, 0xd8, 0xcc, 0xc6, 0xc6, 0xc6, 0xcc, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0xfe, 0xc6, 0xc6, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0xc0, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0xfe, 0x6c, 0x6c, 0x6c, 0x6c, 0x6c, 0x6c, 0x6c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0xfe, 0xc6, 0x60, 0x30, 0x18, 0x30, 0x60, 0xc6, 0xfe, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0xd8, 0xd8, 0xd8, 0xd8, 0xd8, 0x70, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x66, 0x66, 0x66, 0x66, 0x66, 0x7c, 0x60, 0x60, 0xc0, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x76, 0xdc, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x7e, 0x18, 0x3c, 0x66, 0x66, 0x66, 0x3c, 0x18, 0x7e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x38, 0x6c, 0xc6, 0xc6, 0xfe, 0xc6, 0xc6, 0x6c, 0x38, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x38, 0x6c, 0xc6, 0xc6, 0xc6, 0x6c, 0x6c, 0x6c, 0x6c, 0xee, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x1e, 0x30, 0x18, 0x0c, 0x3e, 0x66, 0x66, 0x66, 0x66, 0x3c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0xdb, 0xdb, 0xdb, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x03, 0x06, 0x7e, 0xdb, 0xdb, 0xf3, 0x7e, 0x60, 0xc0, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x1c, 0x30, 0x60, 0x60, 0x7c, 0x60, 0x60, 0x60, 0x30, 0x1c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x7c, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0xc6, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0xfe, 0x00, 0x00, 0xfe, 0x00, 0x00, 0xfe, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x7e, 0x18, 0x18, 0x00, 0x00, 0xff, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x30, 0x18, 0x0c, 0x06, 0x0c, 0x18, 0x30, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x0c, 0x18, 0x30, 0x60, 0x30, 0x18, 0x0c, 0x00, 0x7e, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x0e, 0x1b, 0x1b, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18,
-       0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0x18, 0xd8, 0xd8, 0xd8, 0x70, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x7e, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x76, 0xdc, 0x00, 0x76, 0xdc, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x38, 0x6c, 0x6c, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x0f, 0x0c, 0x0c, 0x0c, 0x0c, 0x0c, 0xec, 0x6c, 0x6c, 0x3c, 0x1c, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0xd8, 0x6c, 0x6c, 0x6c, 0x6c, 0x6c, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x70, 0xd8, 0x30, 0x60, 0xc8, 0xf8, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x7c, 0x7c, 0x7c, 0x7c, 0x7c, 0x7c, 0x7c, 0x00, 0x00, 0x00, 0x00, 0x00,
-       0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
-};
diff --git a/Usermode/Applications/axwin2_src/WM/helpers.c b/Usermode/Applications/axwin2_src/WM/helpers.c
deleted file mode 100644 (file)
index 194c024..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#include "common.h"
-
-// === CODE ===
-void memset32(void *ptr, uint32_t val, size_t count)
-{
-       uint32_t *dst = ptr;
-       while(count --) *dst++ = val;
-}
diff --git a/Usermode/Applications/axwin2_src/WM/image.c b/Usermode/Applications/axwin2_src/WM/image.c
deleted file mode 100644 (file)
index 1d7d343..0000000
+++ /dev/null
@@ -1,130 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- * 
- * Window Manager and Widget Control
- */
-#include "common.h"
-#include <stdlib.h>
-#include <string.h>
-#include <uri.h>
-
-// === IMPORTS ===
-extern tImage *Image_SIF_Parse(void *Buffer, size_t Size);
-
-// === PROTOTYPES ===
- int   UnBase64(uint8_t *Dest, char *Src, int BufSize);
-
-// === CODE ===
-/**
- * \brief Open an image from a URI
- */
-tImage *Image_Load(const char *URI)
-{
-       tURI    *uri;
-        int    filesize;
-       void    *buf;
-       tImage  *img;
-       
-       uri = URI_Parse(URI);
-       if( !uri ) {
-               _SysDebug("Image_Load: Unable parse as URI '%s'\n", URI);
-               return NULL;
-       }
-       
-       if( strcmp(uri->Proto, "file") == 0 )
-       {
-               FILE    *fp;
-               fp = fopen(uri->Path, "rb");
-               if(!fp) {
-                       _SysDebug("Image_Load: Unable to open '%s'\n", uri->Path);
-                       free(uri);
-                       return NULL;
-               }
-               
-               fseek(fp, 0, SEEK_END);
-               filesize = ftell(fp);
-               buf = malloc( filesize );
-               if(!buf) {
-                       _SysDebug("Image_Load: malloc() failed!\n");
-                       fclose(fp);
-                       free(uri);
-                       return NULL;
-               }
-               
-               fread(buf, filesize, 1, buf);
-               fclose(fp);
-       }
-       else if( strcmp(uri->Proto, "base64") == 0 )
-       {
-               // 4 bytes of base64 = 3 bytes of binary (base 256)
-               filesize = strlen( uri->Path ) * 3 / 4;
-               buf = malloc(filesize);
-               if(!buf) {
-                       _SysDebug("Image_Load: malloc() failed!\n");
-                       free(uri);
-                       return NULL;
-               }
-               
-               filesize = UnBase64(buf, uri->Path, filesize);
-       }
-       else
-       {
-               _SysDebug("Image_Load: Unknow protocol '%s'\n", uri->Proto);
-               free(uri);
-               return NULL;
-       }
-       
-       img = Image_SIF_Parse(buf, filesize);
-       free(buf);
-       free(uri);
-       if( !img ) {
-               _SysDebug("Image_Load: Unable to parse SIF from '%s'\n", URI);
-               return NULL;
-       }
-       
-       return img;
-}
-
-/**
- * \brief Decode a Base64 value
- */
-int UnBase64(uint8_t *Dest, char *Src, int BufSize)
-{
-       uint32_t        val;
-        int    i, j;
-       char    *start_src = Src;
-       
-       for( i = 0; i+2 < BufSize; i += 3 )
-       {
-               val = 0;
-               for( j = 0; j < 4; j++, Src ++ ) {
-                       if('A' <= *Src && *Src <= 'Z')
-                               val |= (*Src - 'A') << ((3-j)*6);
-                       else if('a' <= *Src && *Src <= 'z')
-                               val |= (*Src - 'a' + 26) << ((3-j)*6);
-                       else if('0' <= *Src && *Src <= '9')
-                               val |= (*Src - '0' + 52) << ((3-j)*6);
-                       else if(*Src == '+')
-                               val |= 62 << ((3-j)*6);
-                       else if(*Src == '/')
-                               val |= 63 << ((3-j)*6);
-                       else if(!*Src)
-                               break;
-                       else if(*Src != '=')
-                               j --;   // Ignore invalid characters
-               }
-               Dest[i  ] = (val >> 16) & 0xFF;
-               Dest[i+1] = (val >> 8) & 0xFF;
-               Dest[i+2] = val & 0xFF;
-               if(j != 4)      break;
-       }
-       
-       // Finish things off
-       if(i   < BufSize)
-               Dest[i] = (val >> 16) & 0xFF;
-       if(i+1 < BufSize)
-               Dest[i+1] = (val >> 8) & 0xFF;
-       
-       return Src - start_src;
-}
diff --git a/Usermode/Applications/axwin2_src/WM/image.h b/Usermode/Applications/axwin2_src/WM/image.h
deleted file mode 100644 (file)
index 6cda85b..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#ifndef _IMAGE_H_
-#define _IMAGE_H_
-
-typedef struct sImage  tImage;
-
-struct sImage
-{
-       short   Width;
-       short   Height;
-        int    Format;
-       uint8_t Data[];
-};
-
-enum eImageFormats
-{
-       IMGFMT_BGRA,
-       IMGFMT_RGB,
-       NUM_IMGFMTS
-};
-
-// === PROTOTYPES ===
-extern tImage  *Image_Load(const char *URI);
-
-#endif
diff --git a/Usermode/Applications/axwin2_src/WM/input.c b/Usermode/Applications/axwin2_src/WM/input.c
deleted file mode 100644 (file)
index 9386932..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#include "common.h"
-#include <acess/sys.h>
-
-#define JOY_IOCTL_GETSETAXISLIMIT      6
-#define JOY_IOCTL_GETSETAXISPOSITION   7
-
-// === CODE ===
-int Input_Init(void)
-{
-       struct {
-                int    Num, Value;
-       }       num_value;
-
-       // Open mouse for RW
-       giMouseFD = open(gsMouseDevice, 3);
-
-       // Set mouse limits
-       num_value.Num = 0;
-       num_value.Value = giScreenWidth;
-       ioctl(giMouseFD, JOY_IOCTL_GETSETAXISLIMIT, &num_value);
-       num_value.Value = giScreenWidth/2;
-       ioctl(giMouseFD, JOY_IOCTL_GETSETAXISPOSITION, &num_value);
-
-       num_value.Num = 1;
-       num_value.Value = giScreenHeight;
-       ioctl(giMouseFD, JOY_IOCTL_GETSETAXISLIMIT, &num_value);
-       num_value.Value = giScreenHeight/2;
-       ioctl(giMouseFD, JOY_IOCTL_GETSETAXISPOSITION, &num_value);
-
-       return 0;
-}
-
-void Input_FillSelect(int *nfds, fd_set *set)
-{
-       if(*nfds < giTerminalFD)        *nfds = giTerminalFD;
-       if(*nfds < giMouseFD)   *nfds = giMouseFD;
-       FD_SET(giTerminalFD, set);
-       FD_SET(giMouseFD, set);
-}
-
-void Input_HandleSelect(fd_set *set)
-{
-       if(FD_ISSET(giTerminalFD, set))
-       {
-               uint32_t        codepoint;
-               if( read(giTerminalFD, &codepoint, sizeof(codepoint)) != sizeof(codepoint) )
-               {
-                       // oops, error
-               }
-               // TODO: pass on to message handler
-               _SysDebug("Keypress 0x%x", codepoint);
-       }
-
-       if(FD_ISSET(giMouseFD, set))
-       {
-               struct sMouseInfo {
-                       uint16_t        NAxies;
-                       uint16_t        NButtons;
-                       struct sMouseAxis {
-                                int16_t        MinValue;
-                                int16_t        MaxValue;
-                                int16_t        CurValue;
-                               uint16_t        CursorPos;
-                       }       Axies[2];
-                       uint8_t Buttons[3];
-               }       mouseinfo;
-       
-               seek(giMouseFD, 0, SEEK_SET);
-               if( read(giMouseFD, &mouseinfo, sizeof(mouseinfo)) != sizeof(mouseinfo) )
-               {
-                       // Not a 3 button mouse, oops
-                       return ;
-               }
-
-//             _SysDebug("sizeof(uint16_t) = %i, sizeof(int16_t) = %i",
-//                     sizeof(uint16_t), sizeof(int16_t));
-//             _SysDebug("NAxies=%i,NButtons=%i", mouseinfo.NAxies, mouseinfo.NButtons);
-//             _SysDebug("offsetof(Axies[0].MinValue) = %i", offsetof(struct sMouseInfo, Axies[0].MinValue));
-//             _SysDebug("[0] = {MinValue=%i,MaxValue=%i,CurValue=%i}",
-//                     mouseinfo.Axies[0].MinValue, mouseinfo.Axies[0].MaxValue,
-//                     mouseinfo.Axies[0].CurValue
-//                     );
-               // Handle movement
-               Video_SetCursorPos( mouseinfo.Axies[0].CursorPos, mouseinfo.Axies[1].CursorPos );
-//             _SysDebug("Cursor to %i,%i", mouseinfo.Axies[0].CursorPos, mouseinfo.Axies[1].CursorPos);
-       }
-}
diff --git a/Usermode/Applications/axwin2_src/WM/interface.c b/Usermode/Applications/axwin2_src/WM/interface.c
deleted file mode 100644 (file)
index 91396ee..0000000
+++ /dev/null
@@ -1,117 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- * 
- * interface.c
- * > Main Overarching UI
- */
-#include "common.h"
-#include "resources/LogoSmall.sif.res.h"
-
-// === GLOBALS ==
- int   giInterface_Width = 0;
- int   giInterface_HeaderBarSize = 20;
- int   giInterface_TabBarSize = 20;
-tElement       *gpInterface_Sidebar;
-tElement       *gpInterface_ProgramList;
-tElement       *gpInterface_MainArea;
-tElement       *gpInterface_HeaderBar;
-tElement       *gpInterface_TabBar;
-tElement       *gpInterface_TabContent;
-const char     csLogoSmall[] = "base64:///"RESOURCE_LogoSmall_sif;
-tApplication   *gpInterface_CurrentApp;
-
-typedef struct sApplicationLink        tApplicationLink;
-
-struct sApplicationLink {
-       tApplication    *App;
-       tElement        *Button;
-       char    Name[];
-};
-
-// === CODE ===
-/**
- * \brief Initialise the UI
- */
-void Interface_Init(void)
-{
-       tElement        *btn, *text;
-       tElement        *ele;
-
-       // Calculate sizes
-       giInterface_Width = giScreenWidth/16;
-       
-       // Set root window to no-border
-       AxWin_SetFlags(NULL, 0);
-       
-       // -- Create Sidebar (Menu and Window List) --
-       gpInterface_Sidebar = AxWin_CreateElement(NULL, ELETYPE_TOOLBAR, ELEFLAG_VERTICAL, "Sidebar");
-       AxWin_SetSize( gpInterface_Sidebar, giInterface_Width );
-       
-       // > System Menu Button
-       btn = AxWin_CreateElement(gpInterface_Sidebar, ELETYPE_BUTTON, ELEFLAG_NOSTRETCH, "SystemMenu");
-       AxWin_SetSize(btn, giInterface_Width-4);
-       //text = AxWin_CreateElement(btn, ELETYPE_IMAGE, ELEFLAG_SCALE, "MenuLogo");
-       text = AxWin_CreateElement(btn, ELETYPE_IMAGE, 0, "MenuLogo");
-       //AxWin_SetText(text, "file:///LogoSmall.sif");
-       AxWin_SetText(text, csLogoSmall);
-       
-       // > Plain <hr/> style spacer
-       ele = AxWin_CreateElement(gpInterface_Sidebar, ELETYPE_SPACER, ELEFLAG_NOSTRETCH, "SideBar Spacer Top");
-       AxWin_SetSize(ele, 4);
-       
-       // > Application List (Window list on most OSs)
-       gpInterface_ProgramList = AxWin_CreateElement(gpInterface_Sidebar, ELETYPE_BOX, ELEFLAG_VERTICAL, "ProgramList");
-       
-       // > Plain <hr/> style spacer
-       ele = AxWin_CreateElement(gpInterface_Sidebar, ELETYPE_SPACER, ELEFLAG_NOSTRETCH, "SideBar Spacer Bottom");
-       AxWin_SetSize(ele, 4);
-       
-       // > Version/Time
-       text = AxWin_CreateElement(gpInterface_Sidebar, ELETYPE_TEXT, ELEFLAG_NOSTRETCH, "Version String");
-       AxWin_SetSize(text, 20);
-       AxWin_SetText(text, "2.0");
-       
-       // --
-       // -- Create Main Area and regions within --
-       // --
-       // > Righthand Area
-       gpInterface_MainArea = AxWin_CreateElement(NULL, ELETYPE_BOX, ELEFLAG_VERTICAL, "MainArea");
-       //  > Header Bar (Title)
-       gpInterface_HeaderBar = AxWin_CreateElement(gpInterface_MainArea, ELETYPE_BOX, 0, "HeaderBar");
-       AxWin_SetSize(gpInterface_HeaderBar, giInterface_HeaderBarSize);
-       text = AxWin_CreateElement(gpInterface_HeaderBar, ELETYPE_TEXT, 0, NULL);
-       AxWin_SetText(text, "Acess2 GUI - By thePowersGang (John Hodge)");
-       //  > Tab Bar (Current windows)
-       gpInterface_TabBar = AxWin_CreateElement(gpInterface_MainArea, ELETYPE_TABBAR, 0, "TabBar");
-       AxWin_SetSize(gpInterface_TabBar, giInterface_TabBarSize);
-       //  > Application Space
-       gpInterface_TabContent = AxWin_CreateElement(gpInterface_MainArea, ELETYPE_BOX, 0, "TabContent");
-}
-
-void Interface_Update(void)
-{
-//     tApplication    *app;
-//     tApplicationLink        *lnk;
-       giInterface_Width = giScreenWidth/16;
-       AxWin_SetSize( gpInterface_Sidebar, giInterface_Width );
-
-       // Scan application list for changes
-       // - HACK for now, just directly access it
-//     for( app = gWM_Applications; app; app = app->Next )
-//     {
-//             AxWin_CreateElement();
-//     }
-
-       // Update current tab list
-}
-
-void Interface_Render(void)
-{
-       Video_FillRect(
-               0, 0,
-               giInterface_Width, giScreenHeight,
-               0xDDDDDD);
-       
-       Video_Update();
-}
diff --git a/Usermode/Applications/axwin2_src/WM/main.c b/Usermode/Applications/axwin2_src/WM/main.c
deleted file mode 100644 (file)
index 48e47ff..0000000
+++ /dev/null
@@ -1,64 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#include "common.h"
-#include <acess/sys.h>
-
-// === IMPORTS ===
-extern void    WM_Update(void);
-extern int     Input_Init(void);
-
-// === GLOBALS ===
-const char     *gsTerminalDevice = NULL;
-const char     *gsMouseDevice = NULL;
-
- int   giScreenWidth = 640;
- int   giScreenHeight = 480;
-uint32_t       *gpScreenBuffer = NULL;
-
- int   giTerminalFD = -1;
- int   giMouseFD = -1;
-
-// === CODE ===
-/**
- * \brief Program Entrypoint
- */
-int main(int argc, char *argv[])
-{
-       ParseCommandline(argc, argv);
-       
-       if( gsTerminalDevice == NULL ) {
-               gsTerminalDevice = "/Devices/VTerm/6";
-       }
-       if( gsMouseDevice == NULL ) {
-               gsMouseDevice = "/Devices/PS2Mouse";
-       }
-       
-       Video_Setup();
-       Interface_Init();
-       IPC_Init();
-       Input_Init();
-       
-       WM_Update();
-       
-       // Main Loop
-       for(;;)
-       {
-               fd_set  fds;
-                int    nfds = 0;
-               FD_ZERO(&fds);
-       
-               Input_FillSelect(&nfds, &fds);
-               IPC_FillSelect(&nfds, &fds);
-               
-               nfds ++;
-               select(nfds, &fds, NULL, NULL, NULL);
-
-               Input_HandleSelect(&fds);
-               IPC_HandleSelect(&fds);
-       }
-       return 0;
-}
-
diff --git a/Usermode/Applications/axwin2_src/WM/messages.c b/Usermode/Applications/axwin2_src/WM/messages.c
deleted file mode 100644 (file)
index f25e1c4..0000000
+++ /dev/null
@@ -1,227 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#include "common.h"
-#include <acess/sys.h>
-#include <net.h>
-#include <axwin2/messages.h>
-#include <string.h>
-
-#define AXWIN_PORT     4101
-
-#define STATICBUF_SIZE 64
-
-// === TYPES ===
-
-// === PROTOTYPES ===
-void   IPC_Init(void);
-void   IPC_FillSelect(int *nfds, fd_set *set);
-void   IPC_HandleSelect(fd_set *set);
-void   IPC_Handle(tIPC_Type *IPCType, void *Ident, size_t MsgLen, tAxWin_Message *Msg);
-void   IPC_ReturnValue(tIPC_Type *IPCType, void *Ident, int MessageID, uint32_t Value);
- int   IPC_Type_Datagram_GetSize(void *Ident);
- int   IPC_Type_Datagram_Compare(void *Ident1, void *Ident2);
-void   IPC_Type_Datagram_Send(void *Ident, size_t Length, void *Data);
- int   IPC_Type_Sys_GetSize(void *Ident);
- int   IPC_Type_Sys_Compare(void *Ident1, void *Ident2);
-void   IPC_Type_Sys_Send(void *Ident, size_t Length, void *Data);
-
-// === GLOBALS ===
- int   giNetworkFileHandle = -1;
- int   giMessagesFileHandle = -1;
-tIPC_Type      gIPC_Type_Datagram = {
-       IPC_Type_Datagram_GetSize,
-       IPC_Type_Datagram_Compare, 
-       IPC_Type_Datagram_Send
-};
-tIPC_Type      gIPC_Type_SysMessage = {
-       IPC_Type_Sys_GetSize,
-       IPC_Type_Sys_Compare,
-       IPC_Type_Sys_Send
-};
-
-// === CODE ===
-void IPC_Init(void)
-{
-        int    tmp;
-       // TODO: Check this
-       giNetworkFileHandle = open("/Devices/ip/loop/udp", OPENFLAG_READ);
-       tmp = AXWIN_PORT;       ioctl(giNetworkFileHandle, 4, &tmp);    // TODO: Don't hard-code IOCtl number
-}
-
-void IPC_FillSelect(int *nfds, fd_set *set)
-{
-       if( giNetworkFileHandle > *nfds )       *nfds = giNetworkFileHandle;
-       FD_SET(giNetworkFileHandle, set);
-}
-
-void IPC_HandleSelect(fd_set *set)
-{
-       if( FD_ISSET(giNetworkFileHandle, set) )
-       {
-               char    staticBuf[STATICBUF_SIZE];
-                int    readlen, identlen;
-               char    *msg;
-
-               readlen = read(giNetworkFileHandle, staticBuf, sizeof(staticBuf));
-               
-               identlen = 4 + Net_GetAddressSize( ((uint16_t*)staticBuf)[1] );
-               msg = staticBuf + identlen;
-
-               IPC_Handle(&gIPC_Type_Datagram, staticBuf, readlen - identlen, (void*)msg);
-               _SysDebug("IPC_HandleSelect: UDP handled");
-       }
-
-       while(SysGetMessage(NULL, NULL))
-       {
-               pid_t   tid;
-                int    len = SysGetMessage(&tid, NULL);
-               char    data[len];
-               SysGetMessage(NULL, data);
-
-               IPC_Handle(&gIPC_Type_SysMessage, &tid, len, (void*)data);
-               _SysDebug("IPC_HandleSelect: Message handled");
-       }
-}
-
-void IPC_Handle(tIPC_Type *IPCType, void *Ident, size_t MsgLen, tAxWin_Message *Msg)
-{
-       tApplication    *app;
-       tElement        *ele;
-       
-       _SysDebug("IPC_Handle: (IPCType=%p, Ident=%p, MsgLen=%i, Msg=%p)",
-               IPCType, Ident, MsgLen, Msg);
-       
-       if( MsgLen < sizeof(tAxWin_Message) )
-               return ;
-       if( MsgLen < sizeof(tAxWin_Message) + Msg->Size )
-               return ;
-       
-       app = AxWin_GetClient(IPCType, Ident);
-
-       switch((enum eAxWin_Messages) Msg->ID)
-       {
-       // --- Ping message (reset timeout and get server version)
-       case MSG_SREQ_PING:
-               _SysDebug(" IPC_Handle: MSG_SREQ_PING");
-               if( MsgLen < sizeof(tAxWin_Message) + 4 )       return;
-               Msg->ID = MSG_SRSP_VERSION;
-               Msg->Size = 4;
-               Msg->Data[0] = 0;
-               Msg->Data[1] = 1;
-               *(uint16_t*)&Msg->Data[2] = -1;
-               IPCType->SendMessage(Ident, sizeof(Msg->ID), Msg);
-               break;
-
-
-       // --- Register an application
-       case MSG_SREQ_REGISTER:
-               _SysDebug(" IPC_Handle: MSG_SREQ_REGISTER");
-               if( Msg->Data[Msg->Size-1] != '\0' ) {
-                       // Invalid message
-                       _SysDebug("IPC_Handle: RETURN - Not NULL terminated");
-                       return ;
-               }
-               
-               if( app != NULL ) {
-                       _SysDebug("Notice: Duplicate registration (%s)\n", Msg->Data);
-                       return ;
-               }
-               
-               // TODO: Should this function be implemented here?
-               AxWin_RegisterClient(IPCType, Ident, Msg->Data);
-               break;
-       
-       // --- Create a window
-       case MSG_SREQ_ADDWIN:
-               _SysDebug(" IPC_Handle: MSG_SREQ_ADDWIN");
-               if( Msg->Data[Msg->Size-1] != '\0' ) {
-                       // Invalid message
-                       return ;
-               }
-               
-               ele = AxWin_CreateAppWindow(app, Msg->Data);
-               IPC_ReturnValue(IPCType, Ident, MSG_SREQ_ADDWIN, ele->ApplicationID);
-               break;
-       
-       // --- Set a window's icon
-       case MSG_SREQ_SETICON:
-               _SysDebug(" IPC_Handle: MSG_SREQ_SETICON");
-               // TODO: Find a good way of implementing this
-               break;
-       
-       // --- Create an element
-       case MSG_SREQ_INSERT: {
-               _SysDebug(" IPC_Handle: MSG_SREQ_INSERT");
-               struct sAxWin_SReq_NewElement   *info = (void *)Msg->Data;
-               
-               if( Msg->Size != sizeof(*info) )        return;
-               
-               if( !app || info->Parent > app->MaxElementIndex )       return ;
-               
-               ele = AxWin_CreateElement( app->EleIndex[info->Parent], info->Type, info->Flags, NULL );
-               IPC_ReturnValue(IPCType, Ident, MSG_SREQ_ADDWIN, ele->ApplicationID);
-               break; }
-       
-       // --- Unknown message
-       default:
-               fprintf(stderr, "WARNING: Unknown message %i (%p)\n", Msg->ID, IPCType);
-               _SysDebug("WARNING: Unknown message %i (%p)\n", Msg->ID, IPCType);
-               break;
-       }
-}
-
-void IPC_ReturnValue(tIPC_Type *IPCType, void *Ident, int MessageID, uint32_t Value)
-{
-       char    data[sizeof(tAxWin_Message) + sizeof(tAxWin_RetMsg)];
-       tAxWin_Message  *msg = (void *)data;
-       tAxWin_RetMsg   *ret_msg = (void *)msg->Data;
-       
-       msg->Source = 0;        // 0 = Server
-       msg->ID = MSG_SRSP_RETURN;
-       msg->Size = sizeof(tAxWin_RetMsg);
-       ret_msg->ReqID = MessageID;
-       ret_msg->Rsvd = 0;
-       ret_msg->Value = Value;
-       
-       IPCType->SendMessage(Ident, sizeof(data), data);
-}
-
-int IPC_Type_Datagram_GetSize(void *Ident)
-{
-       return 4 + Net_GetAddressSize( ((uint16_t*)Ident)[1] );
-}
-
-int IPC_Type_Datagram_Compare(void *Ident1, void *Ident2)
-{
-       // Pass the buck :)
-       // - No need to worry about mis-matching sizes, as the size is computed
-       //   from the 3rd/4th bytes, hence it will differ before the size is hit.
-       return memcmp(Ident1, Ident2, IPC_Type_Datagram_GetSize(Ident1));
-}
-
-void IPC_Type_Datagram_Send(void *Ident, size_t Length, void *Data)
-{
-        int    identlen = IPC_Type_Datagram_GetSize(Ident);
-       char    tmpbuf[ identlen + Length ];
-       memcpy(tmpbuf, Ident, identlen);        // Header
-       memcpy(tmpbuf + identlen, Data, Length);        // Data
-       // TODO: Handle fragmented packets
-       write(giNetworkFileHandle, tmpbuf, sizeof(tmpbuf));
-}
-
-int IPC_Type_Sys_GetSize(void *Ident)
-{
-       return sizeof(pid_t);
-}
-
-int IPC_Type_Sys_Compare(void *Ident1, void *Ident2)
-{
-       return *(int*)Ident1 - *(int*)Ident2;
-}
-
-void IPC_Type_Sys_Send(void *Ident, size_t Length, void *Data)
-{
-       SysSendMessage( *(tid_t*)Ident, Length, Data );
-}
diff --git a/Usermode/Applications/axwin2_src/WM/render.c b/Usermode/Applications/axwin2_src/WM/render.c
deleted file mode 100644 (file)
index 0ee9e80..0000000
+++ /dev/null
@@ -1,312 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- * 
- * Rendering code
- */
-#include "common.h"
-#include <stdlib.h>
-#include <string.h>
-#include "wm.h"
-#include <acess/sys.h> // _SysDebug
-
-// === IMPORTS ===
-extern void    Decorator_RenderWidget(tElement *Element);
-extern tElement        gWM_RootElement;
-extern tApplication    *gWM_Applications;
-extern int     giWM_MaxAreaX;
-extern int     giWM_MaxAreaY;
-extern int     giWM_MaxAreaW;
-extern int     giWM_MaxAreaH;
-
-// === PROTOTYPES ===
-void   WM_UpdateMinDims(tElement *Element);
-void   WM_UpdateDimensions(tElement *Element, int Pass);
-void   WM_UpdatePosition(tElement *Element);
-void   WM_RenderWidget(tElement *Element);
-void   WM_Update(void);
-
-// === CODE ===
-/**
- * \brief Updates the dimensions of an element
- * \todo What is the \a Pass parameter for
- * 
- * The dimensions of an element are calculated from the parent's
- * cross dimension (the side at right angles to the alignment) sans some
- * padding.
- */
-void WM_UpdateDimensions(tElement *Element, int Pass)
-{
-       tElement        *child;
-        int    nChildren = 0;
-        int    nFixed = 0;
-        int    maxCross = 0;
-        int    fixedSize = 0;
-        int    fullCross, dynWith;
-       
-       _SysDebug("WM_UpdateDimensions %p'%s'", Element, Element->DebugName);
-       _SysDebug(" -> Flags = 0x%x", Element->Flags);
-       _SysDebug(" ->CachedH = %i, ->PaddingT = %i, ->PaddingB = %i",
-               Element->CachedH, Element->PaddingT, Element->PaddingB
-               );
-       _SysDebug(" ->CachedW = %i, ->PaddingL = %i, ->PaddingR = %i",
-               Element->CachedW, Element->PaddingL, Element->PaddingR
-               );
-       
-       // Pass 1
-       for( child = Element->FirstChild; child; child = child->NextSibling )
-       {
-               if( child->Flags & ELEFLAG_ABSOLUTEPOS )
-                       continue ;
-               
-               _SysDebug(" > %p'%s' ->FixedWith = %i", child, child->DebugName, child->FixedWith);
-               if( child->FixedWith )
-               {
-                       nFixed ++;
-                       fixedSize += child->FixedWith;
-               }
-               
-               if( child->FixedCross && maxCross < child->FixedCross )
-                       maxCross = child->FixedCross;
-               if( child->MinCross && maxCross < child->MinCross )
-                       maxCross = child->MinCross;
-               nChildren ++;
-       }
-       
-       _SysDebug(" - nChildren = %i, nFixed = %i", Element, nChildren, nFixed);
-       if( nChildren > nFixed ) {
-               if( Element->Flags & ELEFLAG_VERTICAL )
-                       dynWith = Element->CachedH - Element->PaddingT
-                               - Element->PaddingB;
-               else
-                       dynWith = Element->CachedW - Element->PaddingL
-                               - Element->PaddingR;
-               dynWith -= fixedSize;
-               if( dynWith < 0 )       return ;
-               dynWith /= nChildren - nFixed;
-               _SysDebug(" - dynWith = %i", dynWith);
-       }
-       
-       if( Element->Flags & ELEFLAG_VERTICAL )
-               fullCross = Element->CachedW - Element->PaddingL - Element->PaddingR;
-       else
-               fullCross = Element->CachedH - Element->PaddingT - Element->PaddingB;
-       
-       _SysDebug(" - fullCross = %i", Element, fullCross);
-       
-       // Pass 2 - Set sizes and recurse
-       for( child = Element->FirstChild; child; child = child->NextSibling )
-       {
-                int    cross, with;
-               
-               _SysDebug(" > %p'%s' ->MinCross = %i", child, child->DebugName, child->MinCross);
-
-               
-               // --- Cross Size ---
-               if( child->FixedCross )
-                       cross = child->FixedCross;
-               // Expand to fill?
-               // TODO: Extra flag so options are (Expand, Equal, Wrap)
-               else if( child->Flags & ELEFLAG_NOEXPAND )
-                       cross = child->MinCross;
-               else
-                       cross = fullCross;
-               _SysDebug(" > %p'%s' - cross = %i", child, child->DebugName, cross);
-               if( Element->Flags & ELEFLAG_VERTICAL )
-                       child->CachedW = cross;
-               else
-                       child->CachedH = cross;
-               
-               // --- With Size ---
-               if( child->FixedWith)
-                       with = child->FixedWith;
-               else if( child->Flags & ELEFLAG_NOSTRETCH )
-                       with = child->MinWith;
-               else
-                       with = dynWith;
-               _SysDebug(" > %p'%s' - with = %i", child, child->DebugName, with);
-               if( Element->Flags & ELEFLAG_VERTICAL )
-                       child->CachedH = with;
-               else
-                       child->CachedW = with;
-               
-               WM_UpdateDimensions(child, Pass);
-       }
-       
-       _SysDebug("%p'%s' Done", Element, Element->DebugName);
-}
-
-/**
- * \brief Updates the position of an element
- * 
- * The parent element sets the positions of its children
- */
-void WM_UpdatePosition(tElement *Element)
-{
-       tElement        *child;
-        int    x, y;
-       static int      depth = 0;
-       char    indent[depth+1];
-       
-       if( Element->Flags & ELEFLAG_NORENDER ) return ;
-       
-       memset(indent, ' ', depth);
-       indent[depth] = '\0';
-       depth ++;
-       
-       _SysDebug("%sWM_UpdatePosition %p'%s'{PaddingL:%i, PaddingT:%i}",
-               indent, Element, Element->DebugName, Element->PaddingL, Element->PaddingT);
-       
-       // Initialise
-       x = Element->CachedX + Element->PaddingL;
-       y = Element->CachedY + Element->PaddingT;
-       
-       _SysDebug("%s- Alignment = %s", indent,
-               (Element->Flags & ELEFLAG_VERTICAL) ? "vertical" : "horizontal");
-
-       // Update each child
-       for(child = Element->FirstChild; child; child = child->NextSibling)
-       {
-               _SysDebug("%s- x = %i, y = %i", indent, x, y);
-               child->CachedX = x;
-               child->CachedY = y;
-               
-               // Set Alignment
-               if( Element->Flags & ELEFLAG_ALIGN_CENTER ) {
-                       _SysDebug("%sChild being aligned to center", indent);
-                       if(Element->Flags & ELEFLAG_VERTICAL)
-                               child->CachedX += Element->CachedW/2 - child->CachedW/2;
-                       else
-                               child->CachedY += Element->CachedH/2 - child->CachedH/2;
-               }
-               else if( Element->Flags & ELEFLAG_ALIGN_END) {
-                       _SysDebug("%sChild being aligned to end", indent);
-                       if(Element->Flags & ELEFLAG_VERTICAL )
-                               child->CachedX += Element->CachedW
-                                       - Element->PaddingL - Element->PaddingR
-                                       - child->CachedW;
-                       else
-                               child->CachedY += Element->CachedH
-                                       - Element->PaddingT
-                                       - Element->PaddingB
-                                       - child->CachedH;
-               }
-               
-               _SysDebug("%s> %p'%s' at (%i,%i)", indent, child, child->DebugName,
-                       child->CachedX, child->CachedY);
-       
-               // Update child's children positions
-               WM_UpdatePosition(child);
-               
-               // Increment
-               if(Element->Flags & ELEFLAG_VERTICAL ) {
-                       y += child->CachedH + Element->GapSize;
-               }
-               else {
-                       x += child->CachedW + Element->GapSize;
-               }
-       }
-       
-       _SysDebug("%sElement %p'%s' (%i,%i)",
-               indent, Element, Element->DebugName, Element->CachedX, Element->CachedY
-               );
-       depth --;
-}
-
-/**
- * \brief Update the minimum dimensions of the element
- * \note Called after a child's minimum dimensions have changed
- */
-void WM_UpdateMinDims(tElement *Element)
-{
-       tElement        *child;
-       
-       if(!Element)    return;
-       
-       Element->MinCross = 0;
-       Element->MinWith = 0;
-       
-       for(child = Element->FirstChild; child; child = child->NextSibling)
-       {
-               if( Element->Parent &&
-                       (Element->Flags & ELEFLAG_VERTICAL) == (Element->Parent->Flags & ELEFLAG_VERTICAL)
-                       )
-               {
-                       if(child->FixedCross)
-                               Element->MinCross += child->FixedCross;
-                       else
-                               Element->MinCross += child->MinCross;
-                       if(child->FixedWith)
-                               Element->MinWith += child->FixedWith;
-                       else
-                               Element->MinWith += child->MinWith;
-               }
-               else
-               {
-                       if(child->FixedCross)
-                               Element->MinWith += child->FixedCross;
-                       else
-                               Element->MinWith += child->MinCross;
-                       if(child->FixedWith)
-                               Element->MinCross += child->FixedWith;
-                       else
-                               Element->MinCross += child->MinWith;
-               }
-       }
-       
-       // Recurse upwards
-       WM_UpdateMinDims(Element->Parent);
-}
-
-// --- Render ---
-void WM_RenderWidget(tElement *Element)
-{
-       tElement        *child;
-       
-       if( Element->Flags & ELEFLAG_NORENDER ) return ;
-       if( Element->Flags & ELEFLAG_INVISIBLE )        return ;
-       
-       Decorator_RenderWidget(Element);
-       
-       for(child = Element->FirstChild; child; child = child->NextSibling)
-       {
-               WM_RenderWidget(child);
-       }
-}
-
-void WM_UpdateWindow(tElement *Ele)
-{      
-       WM_UpdateDimensions( Ele, 0 );
-       WM_UpdatePosition( Ele );
-       WM_RenderWidget( Ele );
-}
-
-void WM_Update(void)
-{
-       tApplication    *app;
-       tElement        *ele;
-       
-       for( app = gWM_Applications; app; app = app->Next )
-       {
-               for( ele = app->MetaElement.FirstChild; ele; ele = ele->NextSibling ) {
-                       if( ele->Flags & ELEFLAG_WINDOW_MAXIMISED ) {
-                               ele->CachedX = giWM_MaxAreaX;
-                               ele->CachedY = giWM_MaxAreaY;
-                               ele->CachedW = giWM_MaxAreaW;
-                               ele->CachedH = giWM_MaxAreaH;
-                       }
-                       ele->Flags |= ELEFLAG_NOEXPAND|ELEFLAG_ABSOLUTEPOS|ELEFLAG_FIXEDSIZE;
-                       WM_UpdateWindow(ele);
-               }
-       }
-       
-       gWM_RootElement.CachedX = 0;
-       gWM_RootElement.CachedY = 0;
-       gWM_RootElement.CachedW = giScreenWidth;
-       gWM_RootElement.CachedH = giScreenHeight;
-       gWM_RootElement.Flags |= ELEFLAG_NOEXPAND|ELEFLAG_ABSOLUTEPOS|ELEFLAG_FIXEDSIZE;
-       
-       WM_UpdateWindow( &gWM_RootElement );
-       
-       Video_Update();
-}
diff --git a/Usermode/Applications/axwin2_src/WM/resources/LogoSmall.sif b/Usermode/Applications/axwin2_src/WM/resources/LogoSmall.sif
deleted file mode 100644 (file)
index 2064e48..0000000
Binary files a/Usermode/Applications/axwin2_src/WM/resources/LogoSmall.sif and /dev/null differ
diff --git a/Usermode/Applications/axwin2_src/WM/resources/cursor.h b/Usermode/Applications/axwin2_src/WM/resources/cursor.h
deleted file mode 100644 (file)
index 3cce1f2..0000000
+++ /dev/null
@@ -1,34 +0,0 @@
-/*
- */
-#ifndef _RESORUCE_CURSOR_H
-#define _RESORUCE_CURSOR_H
-
-#include <stdint.h>
-
-static struct {
-       uint16_t        W, H, OfsX, OfsY;
-       uint32_t        Data[];
-} cCursorBitmap = {
-       8, 16, 0, 0,
-       {
-               0xFF000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000,
-               0xFF000000, 0xFF000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000,
-               0xFF000000, 0xFFFFFFFF, 0xFF000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000,
-               0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000,
-               0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0x00000000, 0x00000000, 0x00000000,
-               0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0x00000000, 0x00000000,
-               0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0x00000000,
-               0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0xFF000000, 0xFF000000,
-               0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0x00000000, 0x00000000,
-               0xFF000000, 0xFF000000, 0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0x00000000, 0x00000000,
-               0xFF000000, 0x00000000, 0x00000000, 0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0x00000000,
-               0x00000000, 0x00000000, 0x00000000, 0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000, 0x00000000,
-               0x00000000, 0x00000000, 0x00000000, 0x00000000, 0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000,
-               0x00000000, 0x00000000, 0x00000000, 0x00000000, 0xFF000000, 0xFFFFFFFF, 0xFFFFFFFF, 0xFF000000,
-               0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0xFF000000, 0xFF000000, 0x00000000,
-               0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000
-       }
-};
-
-#endif
-
diff --git a/Usermode/Applications/axwin2_src/WM/video.c b/Usermode/Applications/axwin2_src/WM/video.c
deleted file mode 100644 (file)
index 4121fbe..0000000
+++ /dev/null
@@ -1,203 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#include "common.h"
-#include <acess/sys.h>
-#include <acess/devices/terminal.h>
-#include <image.h>
-#include "resources/cursor.h"
-
-// === PROTOTYPES ===
-void   Video_Setup(void);
-void   Video_SetCursorPos(short X, short Y);
-void   Video_Update(void);
-void   Video_FillRect(short X, short Y, short W, short H, uint32_t Color);
-void   Video_DrawRect(short X, short Y, short W, short H, uint32_t Color);
-
-// === GLOBALS ===
- int   giVideo_CursorX;
- int   giVideo_CursorY;
-
-// === CODE ===
-void Video_Setup(void)
-{
-        int    tmpInt;
-       
-       // Open terminal
-       giTerminalFD = open(gsTerminalDevice, OPENFLAG_READ|OPENFLAG_WRITE);
-       if( giTerminalFD == -1 )
-       {
-               fprintf(stderr, "ERROR: Unable to open '%s' (%i)\n", gsTerminalDevice, _errno);
-               exit(-1);
-       }
-       
-       // Set width
-       tmpInt = giScreenWidth;
-       tmpInt = ioctl( giTerminalFD, TERM_IOCTL_WIDTH, &tmpInt );
-       if(tmpInt != giScreenWidth)
-       {
-               fprintf(stderr, "Warning: Selected width (%i) is invalid, clipped to %i\n",
-                       giScreenWidth, tmpInt);
-               giScreenWidth = tmpInt;
-       }
-       
-       // Set height
-       tmpInt = giScreenHeight;
-       tmpInt = ioctl( giTerminalFD, TERM_IOCTL_HEIGHT, &tmpInt );
-       if(tmpInt != giScreenHeight)
-       {
-               fprintf(stderr, "Warning: Selected height (%i) is invalid, clipped to %i\n",
-                       giScreenHeight, tmpInt);
-               giScreenHeight = tmpInt;
-       }
-       
-       // Set mode to video
-       tmpInt = TERM_MODE_FB;
-       ioctl( giTerminalFD, TERM_IOCTL_MODETYPE, &tmpInt );
-       
-       // Force VT to be shown
-       ioctl( giTerminalFD, TERM_IOCTL_FORCESHOW, NULL );
-       
-       // Create local framebuffer (back buffer)
-       gpScreenBuffer = malloc( giScreenWidth*giScreenHeight*4 );
-       memset32( gpScreenBuffer, 0x8888FF, giScreenWidth*giScreenHeight );
-
-       // Set cursor position and bitmap
-       ioctl(giTerminalFD, TERM_IOCTL_SETCURSORBITMAP, &cCursorBitmap);
-       Video_SetCursorPos( giScreenWidth/2, giScreenHeight/2 );
-
-       Video_Update();
-}
-
-void Video_Update(void)
-{
-       //seek(giTerminalFD, 0, SEEK_SET);
-       seek(giTerminalFD, 0, 1);
-       write(giTerminalFD, gpScreenBuffer, giScreenWidth*giScreenHeight*4);
-}
-
-void Video_SetCursorPos(short X, short Y)
-{
-       struct {
-               uint16_t        x;
-               uint16_t        y;
-       } pos;
-       pos.x = giVideo_CursorX = X;
-       pos.y = giVideo_CursorY = Y;
-       ioctl(giTerminalFD, TERM_IOCTL_GETSETCURSOR, &pos);
-}
-
-void Video_FillRect(short X, short Y, short W, short H, uint32_t Color)
-{
-       uint32_t        *buf = gpScreenBuffer + Y*giScreenWidth + X;
-       
-       _SysDebug("Video_FillRect: (X=%i, Y=%i, W=%i, H=%i, Color=%08x)",
-               X, Y, W, H, Color);
-       
-       if(W < 0 || X < 0 || X >= giScreenWidth)        return ;
-       if(X + W > giScreenWidth)       W = giScreenWidth - X;
-       
-       if(H < 0 || Y < 0 || Y >= giScreenHeight)       return ;
-       if(Y + H > giScreenHeight)      H = giScreenHeight - Y;
-       
-       while( H -- )
-       {
-               memset32( buf, Color, W );
-               buf += giScreenWidth;
-       }
-}
-
-void Video_DrawRect(short X, short Y, short W, short H, uint32_t Color)
-{      
-       Video_FillRect(X, Y, W, 1, Color);
-       Video_FillRect(X, Y+H-1, W, 1, Color);
-       Video_FillRect(X, Y, 1, H, Color);
-       Video_FillRect(X+W-1, Y, 1, H, Color);
-}
-
-/**
- * \brief Draw an image to the screen
- * \todo Maybe have support for an offset in the image
- */
-void Video_DrawImage(short X, short Y, short W, short H, tImage *Image)
-{
-        int    x, y;
-       uint8_t *buf = (uint8_t *)(gpScreenBuffer + Y*giScreenWidth + X);
-       uint8_t *data;
-       
-       // Sanity please
-       if( !Image )
-               return ;
-       
-       // Bounds Check
-       if( X >= giScreenWidth )        return ;
-       if( Y >= giScreenHeight )       return ;
-       
-       // Wrap to image size
-       if( W > Image->Width )  W = Image->Width;
-       if( H > Image->Height ) H = Image->Height;
-       
-       // Wrap to screen size
-       if( X + W > giScreenWidth )     W = giScreenWidth - X;
-       if( Y + H > giScreenHeight )    H = giScreenHeight - Y;
-       
-       // Do the render
-       data = Image->Data;
-       switch( Image->Format )
-       {
-       case IMGFMT_BGRA:
-               for( y = 0; y < H; y ++ )
-               {
-                        int    r, g, b, a;     // New
-                        int    or, og, ob;     // Original
-                       for( x = 0; x < W; x ++ )
-                       {
-                               b = data[x*4+0]; g = data[x*4+1]; r = data[x*4+2]; a = data[x*4+3];
-                               if( a == 0 )    continue;       // 100% transparent
-                               ob = buf[x*4+0]; og = buf[x*4+1]; or = buf[x*4+2];
-                               // Handle Alpha
-                               switch(a)
-                               {
-                               // Transparent: Handled above
-                               // Solid
-                               case 0xFF:      break;
-                               // Half
-                               case 0x80:
-                                       r = (or + r) / 2;
-                                       g = (og + g) / 2;
-                                       b = (ob + b) / 2;
-                                       break;
-                               // General
-                               default:
-                                       r = (or * (255-a) + r * a) / 255;
-                                       g = (og * (255-a) + g * a) / 255;
-                                       b = (ob * (255-a) + b * a) / 255;
-                                       break;
-                               }
-                               buf[x*4+0] = b; buf[x*4+1] = g; buf[x*4+2] = r;
-                       }
-                       data += Image->Width * 4;
-                       buf += giScreenWidth * 4;
-               }
-               break;
-       
-       // RGB
-       case IMGFMT_RGB:
-               for( y = 0; y < H; y ++ )
-               {
-                       for( x = 0; x < W; x ++ )
-                       {
-                               buf[x*4+0] = data[x*3+2];       // Blue
-                               buf[x*4+1] = data[x*3+1];       // Green
-                               buf[x*4+2] = data[x*3+0];       // Red
-                       }
-                       data += W * 3;
-                       buf += giScreenWidth * 4;
-               }
-               break;
-       default:
-               _SysDebug("ERROR: Unknown image format %i\n", Image->Format);
-               break;
-       }
-}
diff --git a/Usermode/Applications/axwin2_src/WM/video_text.c b/Usermode/Applications/axwin2_src/WM/video_text.c
deleted file mode 100644 (file)
index 3d680d5..0000000
+++ /dev/null
@@ -1,367 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- */
-#include <acess/sys.h>
-#include "common.h"
-
-typedef struct sGlyph {
-       struct sGlyph   *Next;
-       struct sGlyph   *Prev;
-       
-       uint32_t        Codepoint;
-       
-       // Effective dimensions (distance to move 'cursor')
-       short   Width;
-       short   Height;
-       
-       // Distance from the current cursor position to render at
-       short   OffsetX;
-       short   OffsetY;
-       
-       // True dimensions (size of the bitmap
-       short   TrueWidth;
-       short   TrueHeight;
-       
-       // Bitmap Data
-       uint8_t Bitmap[];       // 8-bit alpha
-       
-}      tGlyph;
-
-struct sFont {
-       struct sFont    *Next;
-        int    ReferenceCount;
-       
-       tGlyph  *AsciiGlyphs[128];      // Glyphs 0-127
-       
-       tGlyph  *FirstGlyph;
-       tGlyph  *LastGlyph;
-       
-       tGlyph  *(*CacheGlyph)(struct sFont *this, uint32_t Codepoint);
-       
-};
-
-
-// === PROTOTYPES ===
- int   Video_DrawText(short X, short Y, short W, short H, tFont *Font, uint32_t Color, char *Text);
-void   Video_GetTextDims(tFont *Font, const char *Text, int *W, int *H);
-tGlyph *_GetGlyph(tFont *Font, uint32_t Codepoint);
-void   _RenderGlyph(short X, short Y, tGlyph *Glyph, uint32_t Color);
-tGlyph *_SystemFont_CacheGlyph(tFont *Font, uint32_t Codepoint);
- int   ReadUTF8(const char *Input, uint32_t *Output);
-
-// === GLOBALS ===
-tFont  gSystemFont = {
-       .CacheGlyph = _SystemFont_CacheGlyph
-};
-
-// === CODE ===
-/**
- * \brief Draw text to the screen
- */
-int Video_DrawText(short X, short Y, short W, short H, tFont *Font, uint32_t Color, char *Text)
-{
-        int    xOfs = 0;
-       tGlyph  *glyph;
-       uint32_t        ch = 0;
-
-       _SysDebug("Video_DrawText: (X=%i,Y=%i,W=%i,H=%i,Font=%p,", X, Y, W, H, Font);
-       _SysDebug("  Color=%08x,Text='%s')", Color, Text);
-       
-       // Check the bounds
-       if(W < 0 || X < 0 || X >= giScreenWidth)        return 0;
-       if(X + W > giScreenWidth)       W = giScreenWidth - X;
-       
-       if(H < 0 || Y < 0 || Y >= giScreenHeight)       return 0;
-       if(Y + H > giScreenHeight)      H = giScreenHeight - Y;
-       
-       // Handle NULL font (system default monospace)
-       if( !Font )     Font = &gSystemFont;
-       
-       while( *Text )
-       {
-               // Read character
-               Text += ReadUTF8(Text, &ch);
-               
-               // Find (or load) the glyph
-               glyph = _GetGlyph(Font, ch);
-               if( !glyph )    continue ;      // If not found, just don't render it
-               
-               // End render if it will overflow the perscribed range
-               if( xOfs + glyph->TrueWidth > W )
-                       break;
-               
-               xOfs += glyph->Width;
-               _RenderGlyph(X + xOfs, Y, glyph, Color);
-       }
-       
-       return xOfs;
-}
-
-void Video_GetTextDims(tFont *Font, const char *Text, int *W, int *H)
-{
-        int    w=0, h=0;
-       uint32_t        ch;
-       tGlyph  *glyph;
-       if( !Font )     Font = &gSystemFont;
-       
-       while( *Text )
-       {
-               Text += ReadUTF8(Text, &ch);
-               glyph = _GetGlyph(Font, ch);
-               if( !glyph )    continue;
-               
-               w += glyph->Width;
-               if( h < glyph->Height ) h = glyph->Height;
-       }
-       
-       if(W)   *W = w;
-       if(H)   *H = h;
-}
-
-tGlyph *_GetGlyph(tFont *Font, uint32_t Codepoint)
-{
-       tGlyph  *next = NULL, *prev = NULL;
-       tGlyph  *new;
-       
-       // Check for ASCII
-       if( Codepoint < 128 )
-       {
-               if( Font->AsciiGlyphs[Codepoint] == NULL ) {
-                       Font->AsciiGlyphs[Codepoint] = Font->CacheGlyph(Font, Codepoint);
-               }
-               
-               return Font->AsciiGlyphs[Codepoint];
-       }
-       
-       // If within the range
-       if( Font->FirstGlyph && Font->FirstGlyph->Codepoint < Codepoint && Codepoint < Font->LastGlyph->Codepoint )
-       {
-               // Find what end is "closest"
-               if( Codepoint - Font->FirstGlyph->Codepoint < Font->LastGlyph->Codepoint - Codepoint )
-               {
-                       // Start from the bottom
-                       for( next = Font->FirstGlyph;
-                                next && next->Codepoint < Codepoint;
-                                prev = next, next = next->Next
-                                );
-                       
-                       if( next->Codepoint == Codepoint )
-                               return next;
-                       
-               }
-               else
-               {
-                       // Start at the top
-                       // NOTE: The roles of next and prev are reversed here to allow 
-                       //       the insert to be able to assume that `prev` is the
-                       //       previous entry, and `next` is the next.
-                       for( prev = Font->LastGlyph;
-                                prev && prev->Codepoint > Codepoint;
-                                next = prev, prev = prev->Prev
-                                );
-                       if( prev->Codepoint == Codepoint )
-                               return prev;
-               }
-       }
-       else
-       {
-               // If below first
-               if( !Font->FirstGlyph ||  Font->FirstGlyph->Codepoint > Codepoint ) {
-                       prev = NULL;
-                       next = Font->FirstGlyph;
-               }
-               // Above last
-               else {
-                       prev = Font->LastGlyph;
-                       next = NULL;
-               }
-       }
-       
-       // Load new
-       new = Font->CacheGlyph(Font, Codepoint);
-       if( !new )      return NULL;
-       
-       // Add to list
-       // - Forward link
-       if( prev ) {
-               new->Next = prev->Next;
-               prev->Next = new;
-       }
-       else {
-               new->Next = Font->FirstGlyph;
-               Font->FirstGlyph = new;
-       }
-       
-       // - Backlink
-       if( next ) {
-               new->Prev = next->Prev;
-               next->Prev = new;
-       }
-       else {
-               new->Prev = Font->LastGlyph;
-               Font->LastGlyph = new;
-       }
-       
-       // Return
-       return new;
-}
-
-/**
- */
-void _RenderGlyph(short X, short Y, tGlyph *Glyph, uint32_t Color)
-{
-        int    xStart = 0, yStart = 0;
-        int    x, y;
-       uint32_t        *outBuf;
-       uint8_t *inBuf;
-       // TODO: Implement
-
-       X += Glyph->OffsetX;
-       if( X < 0 ) {   // If -ve, skip the first -X collums
-               xStart = -X;
-               X = 0;
-       }
-
-       Y += Glyph->OffsetY;
-       if( Y < 0 ) {   // If -ve, skip the first -Y lines
-               yStart = -Y;
-               Y = 0;
-       }
-
-       outBuf = gpScreenBuffer + Y*giScreenWidth + X;
-       inBuf = Glyph->Bitmap + yStart*Glyph->TrueWidth;
-
-       for( y = yStart; y < Glyph->TrueHeight; y ++ )
-       {
-               for( x = xStart; x < Glyph->TrueWidth; x ++ )
-               {
-                       outBuf[x] = Video_AlphaBlend( outBuf[x], Color, inBuf[x] );
-               }
-               outBuf += giScreenWidth;
-               inBuf += Glyph->TrueWidth;
-
-       }
-}
-
-// Load system font (8x16 monospace)
-#include "font_8x16.h"
-
-/*
- */
-tGlyph *_SystemFont_CacheGlyph(tFont *Font, uint32_t Codepoint)
-{
-        int    i;
-       uint8_t index = 0;
-       tGlyph  *ret;
-       uint8_t *data;
-
-       _SysDebug("_SystemFont_CacheGlyph: (Font=%p, Codepoint=0x%06x)", Font, Codepoint);
-       
-       if( Codepoint < 128 ) {
-               index = Codepoint;
-       }
-       else {
-               index = '?';    // Unknowns come out as a question mark
-       }
-
-       _SysDebug(" index = %i", index);
-
-       ret = malloc( sizeof(tGlyph) + FONT_WIDTH*FONT_HEIGHT );
-       if( !ret ) {
-               _SysDebug("ERROR: malloc(%i) failed", sizeof(tGlyph) + FONT_WIDTH*FONT_HEIGHT);
-               return NULL;
-       }
-
-       ret->Codepoint = Codepoint;
-
-       ret->Width = FONT_WIDTH;
-       ret->Height = FONT_HEIGHT;
-       
-       ret->TrueWidth = FONT_WIDTH;
-       ret->TrueHeight = FONT_HEIGHT;
-
-       ret->OffsetX = 0;
-       ret->OffsetY = 0;
-       
-       data = &VTermFont[index * FONT_HEIGHT];
-
-       for( i = 0; i < FONT_HEIGHT; i ++ )
-       {
-               ret->Bitmap[ i * 8 + 0 ] = data[i] & (1 << 7) ? 255 : 0;
-               ret->Bitmap[ i * 8 + 1 ] = data[i] & (1 << 6) ? 255 : 0;
-               ret->Bitmap[ i * 8 + 2 ] = data[i] & (1 << 5) ? 255 : 0;
-               ret->Bitmap[ i * 8 + 3 ] = data[i] & (1 << 4) ? 255 : 0;
-               ret->Bitmap[ i * 8 + 4 ] = data[i] & (1 << 3) ? 255 : 0;
-               ret->Bitmap[ i * 8 + 5 ] = data[i] & (1 << 2) ? 255 : 0;
-               ret->Bitmap[ i * 8 + 6 ] = data[i] & (1 << 1) ? 255 : 0;
-               ret->Bitmap[ i * 8 + 7 ] = data[i] & (1 << 0) ? 255 : 0;
-       }
-
-       return ret;
-}
-
-
-/**
- * \fn int ReadUTF8(char *Input, uint32_t *Val)
- * \brief Read a UTF-8 character from a string
- */
-int ReadUTF8(const char *Input, uint32_t *Val)
-{
-       const uint8_t   *str = (const uint8_t *)Input;
-       *Val = 0xFFFD;  // Assume invalid character
-       
-       // ASCII
-       if( !(*str & 0x80) ) {
-               *Val = *str;
-               return 1;
-       }
-       
-       // Middle of a sequence
-       if( (*str & 0xC0) == 0x80 ) {
-               return 1;
-       }
-       
-       // Two Byte
-       if( (*str & 0xE0) == 0xC0 ) {
-               *Val = (*str & 0x1F) << 6;      // Upper 6 Bits
-               str ++;
-               if( (*str & 0xC0) != 0x80)      return -1;      // Validity check
-               *Val |= (*str & 0x3F);  // Lower 6 Bits
-               return 2;
-       }
-       
-       // Three Byte
-       if( (*str & 0xF0) == 0xE0 ) {
-               *Val = (*str & 0x0F) << 12;     // Upper 4 Bits
-               str ++;
-               if( (*str & 0xC0) != 0x80)      return -1;      // Validity check
-               *Val |= (*str & 0x3F) << 6;     // Middle 6 Bits
-               str ++;
-               if( (*str & 0xC0) != 0x80)      return -1;      // Validity check
-               *Val |= (*str & 0x3F);  // Lower 6 Bits
-               return 3;
-       }
-       
-       // Four Byte
-       if( (*str & 0xF1) == 0xF0 ) {
-               *Val = (*str & 0x07) << 18;     // Upper 3 Bits
-               str ++;
-               if( (*str & 0xC0) != 0x80)      return -1;      // Validity check
-               *Val |= (*str & 0x3F) << 12;    // Middle-upper 6 Bits
-               str ++;
-               if( (*str & 0xC0) != 0x80)      return -1;      // Validity check
-               *Val |= (*str & 0x3F) << 6;     // Middle-lower 6 Bits
-               str ++;
-               if( (*str & 0xC0) != 0x80)      return -1;      // Validity check
-               *Val |= (*str & 0x3F);  // Lower 6 Bits
-               return 4;
-       }
-       
-       // UTF-8 Doesn't support more than four bytes
-       return 4;
-}
-
-
-
-
diff --git a/Usermode/Applications/axwin2_src/WM/wm.c b/Usermode/Applications/axwin2_src/WM/wm.c
deleted file mode 100644 (file)
index b073223..0000000
+++ /dev/null
@@ -1,300 +0,0 @@
-/*
- * Acess GUI (AxWin) Version 2
- * By John Hodge (thePowersGang)
- * 
- * Window Manager and Widget Control
- */
-#include "common.h"
-#include <stdlib.h>
-#include <string.h>
-#include "wm.h"
-#include <acess/sys.h> // _SysDebug
-
-// === IMPORTS ===
-extern void    Video_GetTextDims(tFont *Font, const char *Text, int *W, int *H);
-
-// === PROTOTYPES ===
-tApplication   *AxWin_RegisterClient(tIPC_Type *IPCType, void *Ident, const char *Name);
-void   AxWin_DeregisterClient(tApplication *App);
-tApplication   *AxWin_GetClient(tIPC_Type *Method, void *Ident);
-tElement       *AxWin_CreateElement(tElement *Parent, int Type, int Flags, const char *DebugName);
-void   AxWin_DeleteElement(tElement *Element);
-void   AxWin_SetFlags(tElement *Element, int Flags);
-void   AxWin_SetSize(tElement *Element, int Size);
-void   AxWin_SetText(tElement *Element, const char *Text);
-
-// === GLOBALS ===
-// - TODO: Handle windows by having multiple root elements
-tElement       gWM_RootElement = {
-       .DebugName = "ROOT"
-};
-tWindow        *gWM_WindowFirst;
-tWindow        *gWM_WindowLast;
-tApplication   *gWM_Applications;
- int   giWM_MaxAreaX = 0;
- int   giWM_MaxAreaY = 0;
- int   giWM_MaxAreaW = -1;
- int   giWM_MaxAreaH = -1;
-
-// --- Element type flags
-struct {
-       void    (*Init)(tElement *This);
-       void    (*Delete)(tElement *This);
-       void    (*UpdateFlags)(tElement *This);
-       void    (*UpdateSize)(tElement *This);
-       void    (*UpdateText)(tElement *This);
-}      gaWM_WidgetTypes[MAX_ELETYPES] = {
-       {NULL, NULL, NULL, NULL, NULL}, // NULL
-       {NULL, NULL, NULL, NULL, NULL}, // Window
-       {NULL, NULL, NULL, NULL, NULL}  // Box
-};
-const int      ciWM_NumWidgetTypes = sizeof(gaWM_WidgetTypes)/sizeof(gaWM_WidgetTypes[0]);
-
-// === CODE ===
-tApplication *AxWin_RegisterClient(tIPC_Type *Method, void *Ident, const char *Name)
-{
-        int    identlen = Method->GetIdentSize(Ident);
-       // Structure, empty string, Name, Ident
-       tApplication    *ret = calloc( 1, sizeof(tApplication) + 1 + strlen(Name) + 1 + identlen );
-       
-       // DebugName is empty
-       
-       // Name/Title
-       ret->Name = &ret->MetaElement.DebugName[1];
-       strcpy(ret->Name, Name);
-       // Ident
-       ret->Ident = ret->Name + strlen(Name) + 1;
-       memcpy(ret->Ident, Ident, identlen);
-       // IPC Type
-       ret->IPCType = Method;
-
-       // Element index
-       ret->MaxElementIndex = DEFAULT_ELEMENTS_PER_APP;
-       ret->EleIndex = calloc( 1, ret->MaxElementIndex * sizeof(*ret->EleIndex) );
-
-       // Add to global list
-       ret->Next = gWM_Applications;
-       gWM_Applications = ret;
-
-       // TODO: Inform listeners of the new application
-
-       return ret;
-}
-
-void AxWin_DeregisterClient(tApplication *App)
-{
-       // TODO: Complete implementing DeregisterClient
-       tElement        *win, *next;
-
-       for( win = App->MetaElement.FirstChild; win; win = next )
-       {
-               next = win->NextSibling;
-               AxWin_DeleteElement(win);
-       }
-
-       // TODO: Inform listeners of deleted application
-       
-       // Remove from list
-       {
-               tApplication    *app, *prev = NULL;
-               for( app = gWM_Applications; app; app = app->Next )
-               {
-                       if( app == App )        break;
-                       prev = app;
-               }
-               
-               if( app )
-               {
-                       if(prev)
-                               prev->Next = App->Next;
-                       else
-                               gWM_Applications = App->Next;
-               }
-       }
-       
-       free(App);
-}
-
-/**
- * \brief Get an application handle from a client identifier
- */
-tApplication *AxWin_GetClient(tIPC_Type *Method, void *Ident)
-{
-       // TODO: Faster and smarter technique
-       tApplication    *app;
-       for( app = gWM_Applications; app; app = app->Next )
-       {
-               if( app->IPCType != Method )    continue;
-               if( Method->CompareIdent( app->Ident, Ident ) != 0 ) continue;
-               return app;
-       }
-       return NULL;
-}
-
-tElement *AxWin_CreateAppWindow(tApplication *App, const char *Name)
-{
-       tElement        *ret;
-       tWindow *win;
-       
-       win = calloc(1, sizeof(tWindow) + 1);
-       if(!win)        return NULL;
-       
-       ret = &win->RootElement;
-       ret->Type = ELETYPE_WINDOW;
-       ret->Data = win;
-       ret->Parent = &App->MetaElement;
-       
-       // Add to parent list
-       if(ret->Parent->LastChild)
-               ret->Parent->LastChild->NextSibling = ret;
-       ret->Parent->LastChild = ret;
-       if(!ret->Parent->FirstChild)
-               ret->Parent->FirstChild = ret;
-       
-       ret->Text = strdup(Name);
-       
-       return ret;
-}
-
-// --- Widget Creation and Control ---
-tAxWin_Element *AxWin_CreateElement(tElement *Parent, int Type, int Flags, const char *DebugName)
-{
-       tElement        *ret;
-       const char      *dbgName = DebugName ? DebugName : "";
-       
-       ret = calloc(sizeof(tElement)+strlen(dbgName)+1, 1);
-       if(!ret)        return NULL;
-       
-       // Prepare
-       ret->Type = Type;
-       strcpy(ret->DebugName, dbgName);
-       if(Parent == NULL)      Parent = &gWM_RootElement;
-       ret->Parent = Parent;
-       ret->Flags = Flags;
-       
-       // Append to parent's list
-       if(Parent->LastChild)
-               Parent->LastChild->NextSibling = ret;
-       Parent->LastChild = ret;
-       if(!Parent->FirstChild) Parent->FirstChild = ret;
-       
-       ret->PaddingL = 2;
-       ret->PaddingR = 2;
-       ret->PaddingT = 2;
-       ret->PaddingB = 2;
-       
-       if( Type < ciWM_NumWidgetTypes && gaWM_WidgetTypes[Type].Init )
-               gaWM_WidgetTypes[Type].Init(ret);
-       
-       WM_UpdateMinDims(ret->Parent);
-       
-       return ret;
-}
-
-/**
- * \brief Delete an element
- */
-void AxWin_DeleteElement(tElement *Element)
-{
-       tElement        *child, *next;
-       
-       for(child = Element->FirstChild; child; child = next)
-       {
-               next = child->NextSibling;
-               AxWin_DeleteElement(child);
-       }
-
-       // TODO: Implement AxWin_DeleteElement
-       // TODO: Clean up related data.
-       if( Element->Type < ciWM_NumWidgetTypes && gaWM_WidgetTypes[Element->Type].Delete )
-               gaWM_WidgetTypes[Element->Type].Delete(Element);
-
-       if(Element->Owner)
-               Element->Owner->EleIndex[ Element->ApplicationID ] = NULL;
-
-       Element->Type = 0;
-       Element->Owner = 0;
-       Element->Flags = 0;
-
-       free(Element);
-}
-
-/**
- * \brief Alter an element's flags 
- */
-void AxWin_SetFlags(tElement *Element, int Flags)
-{
-       // Permissions are handled in the message handler
-       if(!Element) {
-               gWM_RootElement.Flags = Flags;
-               return ;
-       }
-       
-       Element->Flags = Flags;
-       return ;
-}
-
-/**
- * \brief Set the fixed lenghthways size of an element
- */
-void AxWin_SetSize(tElement *Element, int Size)
-{
-       if(!Element)    return ;
-       Element->FixedWith = Size;
-       return ;
-}
-
-/**
- * \brief Set the text field of an element
- * \note Used for the image path on ELETYPE_IMAGE
- */
-void AxWin_SetText(tElement *Element, const char *Text)
-{
-       if(!Element)    return ;
-       if(Element->Text)       free(Element->Text);
-       Element->Text = strdup(Text);
-       
-       switch(Element->Type)
-       {
-       case ELETYPE_IMAGE:
-               if(Element->Data)       free(Element->Data);
-               Element->Data = Image_Load( Element->Text );
-               if(!Element->Data) {
-                       Element->Flags &= ~ELEFLAG_FIXEDSIZE;
-                       return ;
-               }
-               
-               //Element->Flags |= ELEFLAG_FIXEDSIZE;
-               Element->CachedW = ((tImage*)Element->Data)->Width;
-               Element->CachedH = ((tImage*)Element->Data)->Height;
-               
-               if(Element->Parent && Element->Parent->Flags & ELEFLAG_VERTICAL) {
-                       Element->MinCross = ((tImage*)Element->Data)->Width;
-                       Element->MinWith = ((tImage*)Element->Data)->Height;
-               }
-               else {
-                       Element->MinWith = ((tImage*)Element->Data)->Width;
-                       Element->MinCross = ((tImage*)Element->Data)->Height;
-               }
-               break;
-       
-       case ELETYPE_TEXT:
-               {
-                int    w=0, h=0;
-               Video_GetTextDims(NULL, Element->Text, &w, &h);
-               if(Element->Parent && Element->Parent->Flags & ELEFLAG_VERTICAL) {
-                       Element->MinCross = w;
-                       Element->MinWith = h;
-               }
-               else {
-                       Element->MinWith = w;
-                       Element->MinCross = h;
-               }
-               }
-               break;
-       default:        // Any other, no special case
-               break ; 
-       }
-       
-       return ;
-}
diff --git a/Usermode/Applications/axwin2_src/WM/wm.h b/Usermode/Applications/axwin2_src/WM/wm.h
deleted file mode 100644 (file)
index 5977fd6..0000000
+++ /dev/null
@@ -1,109 +0,0 @@
-/*
- * Acess2 Window Manager (AxWin2)
- */
-#ifndef _WM_H_
-#define _WM_H_
-
-#include <axwin2/axwin.h>
-#include "common.h"
-
-/**
- * \brief Number of elements that can be owned by each application
- */
-// TODO: Fine tune these values
-#define MAX_ELEMENTS_PER_APP   1024
-#define DEFAULT_ELEMENTS_PER_APP       128
-
-typedef struct sAxWin_Element  tElement;
-typedef struct sMenuItem       tMenuItem;
-typedef struct sWindow tWindow;
-typedef struct sApplication    tApplication;
-
-struct sAxWin_Element
-{
-       enum eElementTypes      Type;
-       
-       // Element Tree
-       tElement        *Parent;
-       tElement        *FirstChild;
-       tElement        *LastChild;
-       tElement        *NextSibling;
-       
-       // Application
-       tApplication    *Owner; //!< Owning application
-       uint16_t        ApplicationID;  //!< Index into sApplication::EleIndex
-
-       // User modifiable attributes   
-       short   PaddingL, PaddingR;
-       short   PaddingT, PaddingB;
-       short   GapSize;
-       
-       uint32_t        Flags;
-       
-       short   FixedWith;      //!< Fixed lengthways Size attribute (height)
-       short   FixedCross;     //!< Fixed Cross Size attribute (width)
-       
-       char    *Text;
-       
-       // -- Attributes maitained by the element code
-       // Not touched by the user
-       short   MinWith;        //!< Minimum long size
-       short   MinCross;       //!< Minimum cross size
-       void    *Data;  //!< Per-type data
-       
-       // -- Render Cache
-       short   CachedX, CachedY;
-       short   CachedW, CachedH;
-       
-       char    DebugName[];
-};
-
-struct sMenuItem
-{
-       tMenuItem       *Next;
-        int    Flags;
-        int    ID;     //!< ID number sent to application
-       const char      *Label;
-       const char      *Right;
-       tMenuItem       *FirstChild;
-};
-
-struct sWindow
-{
-        int    X, Y, W, H;
-       void    *Icon;
-       
-       tApplication    *App;
-       
-       tWindow *OrderNext;     // Render order
-       
-       tMenuItem       *Menus;
-       
-       tElement        RootElement;
-};
-
-struct sApplication
-{
-       tApplication    *Next;
-
-       tIPC_Type       *IPCType;
-       void    *Ident; //!< Client Identifier
-       
-       char    *Name;  //!< Application name
-       
-        int    MaxElementIndex;        //!< Number of entries in \a EleIndex
-       tElement        **EleIndex;     //!< Array of pointers to elements owned by this application
-       
-       tElement        MetaElement;    //!< Tabs child off this
-};
-
-// === FUNCTIONS ===
-
-// --- Render
-extern void    WM_UpdateMinDims(tElement *Element);
-extern void    WM_UpdateDimensions(tElement *Element, int Pass);
-extern void    WM_UpdatePosition(tElement *Element);
-extern void    WM_RenderWidget(tElement *Element);
-extern void    WM_Update(void);
-
-#endif
diff --git a/Usermode/Applications/axwin2_src/notes.txt b/Usermode/Applications/axwin2_src/notes.txt
deleted file mode 100644 (file)
index d4090b9..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-Applications can have 0-* windows
-Windows can have 1-* tabs
-Each window has a menu based on a template from the application
diff --git a/Usermode/Libraries/libaxwin2.so_src/Makefile b/Usermode/Libraries/libaxwin2.so_src/Makefile
deleted file mode 100644 (file)
index 240646b..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-# Acess 2 - AxWin GUI Library
-#
-
-include ../Makefile.cfg
-
-CPPFLAGS +=
-CFLAGS   += -Wall
-LDFLAGS  += -lc -soname libaxwin2.so
-
-OBJ = main.o messages.o
-BIN = libaxwin2.so
-
-include ../Makefile.tpl
diff --git a/Usermode/Libraries/libaxwin2.so_src/common.h b/Usermode/Libraries/libaxwin2.so_src/common.h
deleted file mode 100644 (file)
index 4e80c7f..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-/*
- * AxWin Window Manager Interface Library
- * By John Hodge (thePowersGang)
- * This file is published under the terms of the Acess Licence. See the
- * file COPYING for details.
- * 
- * common.h - Internal Variable and Constant definitions
- */
-#ifndef _COMMON_H_
-#define _COMMON_H_
-
-// === Includes ===
-#include <acess/sys.h>
-#include <axwin2/axwin.h>
-#include <stdlib.h>
-
-// === Constants ===
-enum eAxWin_Modes
-{
-       AXWIN_MODE_IPC
-};
-
-// === Variables ===
-extern int     giAxWin_Mode;
-extern int     giAxWin_PID;
-
-#endif
diff --git a/Usermode/Libraries/libaxwin2.so_src/include_exp/axwin2/axwin.h b/Usermode/Libraries/libaxwin2.so_src/include_exp/axwin2/axwin.h
deleted file mode 100644 (file)
index 77db620..0000000
+++ /dev/null
@@ -1,127 +0,0 @@
-/**
- * \file axwin2/axwin.h
- * \author John Hodge (thePowersGang)
- * \brief AxWin Core functions
- */
-#ifndef _AXWIN2_AXWIN_H
-#define _AXWIN2_AXWIN_H
-
-#include <stdlib.h>
-#include <stdint.h>
-
-#include <axwin2/messages.h>
-
-// === Core Types ===
-typedef struct sAxWin_Element  tAxWin_Element;
-typedef int    tAxWin_MessageCallback(tAxWin_Message *);
-
-// === Functions ===
-extern int     AxWin_Register(const char *ApplicationName, tAxWin_MessageCallback *DefaultHandler);
-extern tAxWin_Element  *AxWin_CreateWindow(const char *TabTitle);
-extern tAxWin_Element  *AxWin_AddMenuItem(tAxWin_Element *Parent, const char *Label, int Message);
-
-extern int     AxWin_MessageLoop(void);
-extern int     AxWin_SendMessage(tAxWin_Message *Message);
-extern tAxWin_Message  *AxWin_WaitForMessage(void);
-extern int     AxWin_HandleMessage(tAxWin_Message *Message);
-
-// === Window Control ===
-
-extern tAxWin_Element  *AxWin_CreateElement(tAxWin_Element *Parent, int ElementType, int Flags, const char *DebugName);
-extern void    AxWin_SetFlags(tAxWin_Element *Element, int Flags);
-extern void    AxWin_SetText(tAxWin_Element *Element, const char *Text);
-extern void    AxWin_SetSize(tAxWin_Element *Element, int Size);
-extern void    AxWin_DeleteElement(tAxWin_Element *Element);
-
-// === CONSTANTS ===
-enum eElementFlags
-{
-       /**
-        * \brief Rendered
-        * 
-        * If set, the element will be ignored in calculating sizes and
-        * rendering.
-        */
-       ELEFLAG_NORENDER    = 0x001,
-       /**
-        * \brief Element visibility
-        * 
-        * If set, the element is not drawn (but still is used for size calculations)
-        */
-       ELEFLAG_INVISIBLE   = 0x002,
-       
-       /**
-        * \brief Position an element absulutely (ignored in size calcs)
-        */
-       ELEFLAG_ABSOLUTEPOS = 0x004,
-       
-       /**
-        * \brief Fixed size element
-        */
-       ELEFLAG_FIXEDSIZE   = 0x008,
-       
-       /**
-        * \brief Element "orientation"
-        * 
-        * Vertical means that the children of this element are stacked,
-        * otherwise they list horizontally
-        */
-       ELEFLAG_VERTICAL    = 0x010,//  ELEFLAG_HORIZONTAL  = 0x000,
-       /**
-        * \brief Action for text that overflows
-        */
-       ELEFLAG_WRAP        = 0x020,//  ELEFLAG_NOWRAP      = 0x000,
-       /**
-        * \brief Cross size action
-        * 
-        * If this flag is set, the element will only be as large (across
-        * its parent) as is needed to encase the contents of the element.
-        * Otherwise, the element will expand to fill all avaliable space.
-        */
-       ELEFLAG_NOEXPAND    = 0x040,
-       
-       /**
-        * \brief With (length) size action
-        * If this flag is set, the element will only be as large as
-        * is required along it's parent
-        */
-       ELEFLAG_NOSTRETCH   = 0x080,
-       
-       /**
-        * \brief Center alignment
-        */
-       ELEFLAG_ALIGN_CENTER= 0x100,
-       /**
-        * \brief Right/Bottom alignment
-        * 
-        * If set, the element aligns to the end of avaliable space (instead
-        * of the beginning)
-        */
-       ELEFLAG_ALIGN_END       = 0x200
-};
-
-#define ELEFLAG_WINDOW_MAXIMISED       0x10000
-
-/**
- */
-enum eElementTypes
-{
-       ELETYPE_NONE,
-
-       ELETYPE_WINDOW, //!< Window root element
-       
-       ELETYPE_BOX,    //!< Content box (invisible in itself)
-       ELETYPE_TABBAR, //!< Tab Bar
-       ELETYPE_TOOLBAR,        //!< Tool Bar
-       
-       ELETYPE_BUTTON, //!< Push Button
-       
-       ELETYPE_TEXT,   //!< Text
-       ELETYPE_IMAGE,  //!< Image
-       
-       ELETYPE_SPACER, //!< Visual Spacer (horizontal / vertical rule)
-       
-       MAX_ELETYPES    = 0x100
-};
-
-#endif
diff --git a/Usermode/Libraries/libaxwin2.so_src/include_exp/axwin2/messages.h b/Usermode/Libraries/libaxwin2.so_src/include_exp/axwin2/messages.h
deleted file mode 100644 (file)
index 61536f3..0000000
+++ /dev/null
@@ -1,125 +0,0 @@
-/**
- * \file messages.h
- * \author John Hodge (thePowersGang)
- * \brief AxWin Control Messages and structures
- */
-#ifndef _AXWIN_MESSAGES_H
-#define _AXWIN_MESSAGES_H
-
-#include <stdint.h>
-
-typedef struct sAxWin_Message  tAxWin_Message;
-typedef struct sAxWin_RetMsg   tAxWin_RetMsg;
-
-// Higherarchy:
-// - HANDLE
-//  + ELEMENT
-//   > DIALOG
-//   > TAB
-
-/**
- * \brief Message IDs
- */
-enum eAxWin_Messages
-{
-       // Client->Server Requests
-       MSG_SREQ_PING,
-       // - Windows
-       MSG_SREQ_REGISTER,      // bool (char[] Name) - Registers this PID with the Window Manager
-       
-       MSG_SREQ_ADDWIN,        // ELEMENT (char[] Name) - Adds a tab to the window
-       
-       MSG_SREQ_SETICON,       // void (TAB Tab, char[] IconURI)       - Set the icon of a tab (or application)
-
-       MSG_SREQ_NEWDIALOG,     // DIALOG (TAB Parent, char[] Name)     - Creates a dialog
-       MSG_SREQ_DELDIALOG,     // void (DIALOG Dialog) - Closes a dialog
-       
-       MSG_SREQ_SETNAME,       // void (ELEMENT Element, char[] Name)
-       MSG_SREQ_GETNAME,       // char[] (ELEMENT Element)
-       
-       // - Builtin Elements
-       MSG_SREQ_INSERT,        // ELEMENT (ELEMENT Parent, eAxWin_Controls Type, u32 Flags)
-       MSG_SREQ_DELETE,        // void (ELEMENT Element)
-       
-       // - Drawing
-       //  All drawing functions take an ELEMENT as their first parameter.
-       //  This must be either a Window or Canvas control
-       MSG_SREQ_SETCOL,
-       MSG_SREQ_PSET,
-       MSG_SREQ_LINE,  MSG_SREQ_CURVE,
-       MSG_SREQ_RECT,  MSG_SREQ_FILLRECT,
-       MSG_SREQ_RIMG,  MSG_SREQ_SIMG,  // Register/Set Image
-       MSG_SREQ_SETFONT,       MSG_SREQ_PUTTEXT,
-
-       // - Callback Registration
-
-       // - WM Control
-       MSG_SREQ_SET_MAXIMIZE_AREA,     // void (uint16_t X, Y, W, H)
-       
-       // Server->Client Responses
-       MSG_SRSP_VERSION,
-       MSG_SRSP_RETURN,        // {int RequestID, void[] Return Value} - Returns a value from a server request
-       
-       NUM_MSG
-};
-
-// --- Server Requests (Requests from the client of the server)
-/**
- * \brief Server Request - Ping (Get Server Version)
- */
-struct sAxWin_SReq_Ping
-{
-};
-
-/**
- * \brief Server Request - New Window
- * \see eAxWin_Messages.MSG_SREQ_NEWWINDOW
- */
-struct sAxWin_SReq_NewWindow
-{
-       uint16_t        X, Y, W, H;
-       uint32_t        Flags;
-};
-
-struct sAxWin_SReq_NewElement
-{
-       uint16_t        Parent;
-       uint16_t        Type;
-       uint32_t        Flags;
-};
-
-
-// --- Server Responses
-/**
- * \brief Server Response - Pong
- * \see eAxWin_Messages.MSG_SRSP_PONG
- */
-struct sAxWin_SRsp_Version
-{
-       uint8_t Major;
-       uint8_t Minor;
-       uint16_t        Build;
-};
-
-
-// === Core Message Structure
-/**
- * \brief Overarching Message Structure
- * \note sizeof(tAxWin_Message) is never valid
- */
-struct sAxWin_Message
-{
-       uint32_t        Source;
-       uint16_t        ID;
-       uint16_t        Size;   // Size of data
-       char    Data[];
-};
-
-struct sAxWin_RetMsg
-{
-       uint16_t        ReqID;
-       uint16_t        Rsvd;
-       uint32_t        Value;
-};
-
-#endif
diff --git a/Usermode/Libraries/libaxwin2.so_src/main.c b/Usermode/Libraries/libaxwin2.so_src/main.c
deleted file mode 100644 (file)
index de08442..0000000
+++ /dev/null
@@ -1,86 +0,0 @@
-/*
- * AxWin Window Manager Interface Library
- * By John Hodge (thePowersGang)
- * This file is published under the terms of the Acess Licence. See the
- * file COPYING for details.
- * 
- * main.c - Library Initialisation
- */
-#include "common.h"
-#include <string.h>
-
-// === GLOBALS ===
- int   giAxWin_Mode = 0;
- int   giAxWin_PID = 9;        // HACK!
-tAxWin_MessageCallback *gAxWin_DefaultCallback;
-
-// === CODE ===
-int SoMain()
-{
-       return 0;
-}
-
-tAxWin_Message *AxWin_int_SendAndWait(int RetID, tAxWin_Message *Message)
-{
-       tAxWin_Message  *msg;
-       tAxWin_RetMsg   *rmsg;
-
-       AxWin_SendMessage(Message);
-       
-       for(;;)
-       {
-               msg = AxWin_WaitForMessage();
-               
-               rmsg = (void*)msg->Data;
-               if(msg->ID == MSG_SRSP_RETURN && rmsg->ReqID == Message->ID )
-                       break;
-               
-               AxWin_HandleMessage(msg);
-               free(msg);
-       }
-       
-       return msg;
-}
-
-int AxWin_Register(const char *Name, tAxWin_MessageCallback *DefaultCallback)
-{
-       tAxWin_Message  req;
-       tAxWin_Message  *msg;
-        int    ret;
-        int    len = strlen(Name);
-       
-       req.ID = MSG_SREQ_REGISTER;
-       req.Size = 1 + (len+1)/4;
-       strcpy(req.Data, Name);
-       
-       msg = AxWin_int_SendAndWait(MSG_SRSP_RETURN, &req);
-       ret = ((tAxWin_RetMsg*)msg->Data)->Value;
-       free(msg);
-
-       gAxWin_DefaultCallback = DefaultCallback;
-       
-       return !!ret;
-}
-
-tAxWin_Element *AxWin_CreateWindow(const char *Title)
-{
-       tAxWin_Message  req;
-       tAxWin_Message  *msg;
-       tAxWin_Element  *ret;
-        int    len = strlen(Title);
-       
-       req.ID = MSG_SREQ_ADDWIN;
-       req.Size = 1 + (len+1)/4;
-       strcpy(req.Data, Title);
-       
-       msg = AxWin_int_SendAndWait(MSG_SRSP_RETURN, &req);
-       ret = (tAxWin_Element*) ((tAxWin_RetMsg*)msg->Data)->Value;
-       free(msg);
-       
-       return ret;
-}
-
-tAxWin_Element *AxWin_AddMenuItem(tAxWin_Element *Parent, const char *Label, int Message)
-{
-       return NULL;
-}
diff --git a/Usermode/Libraries/libaxwin2.so_src/messages.c b/Usermode/Libraries/libaxwin2.so_src/messages.c
deleted file mode 100644 (file)
index a314703..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-/*
- * AxWin Window Manager Interface Library
- * By John Hodge (thePowersGang)
- * This file is published under the terms of the Acess Licence. See the
- * file COPYING for details.
- * 
- * messages.c - Message Handling
- */
-#include "common.h"
-
-// === PROTOTYPES ===
- int   AxWin_MessageLoop();
-tAxWin_Message *AxWin_WaitForMessage();
- int   AxWin_HandleMessage(tAxWin_Message *Message);
-
-// ===  ===
-
-// === CODE ===
-int AxWin_SendMessage(tAxWin_Message *Message)
-{
-       switch(giAxWin_Mode)
-       {
-       case AXWIN_MODE_IPC:
-               SysSendMessage(giAxWin_PID, Message->Size*4, Message);
-               break;
-       default:
-               break;
-       }
-       return 0;
-}
-
-/**
- * \brief Loop forever, checking and waiting for messages
- */
-int AxWin_MessageLoop()
-{
-       tAxWin_Message  *msg;
-        int    ret;
-       for(;;)
-       {
-               msg = AxWin_WaitForMessage();
-               ret = AxWin_HandleMessage(msg);
-               
-               if(ret < 0)     return 0;
-       }
-       return 0;
-}
-
-/**
- * \brief Wait for a message
- */
-tAxWin_Message *AxWin_WaitForMessage()
-{
-        int    length;
-       pid_t   src;
-       tAxWin_Message  *ret = NULL;
-       
-       switch( giAxWin_Mode )
-       {
-       case AXWIN_MODE_IPC:
-               while( (length = SysGetMessage(&src, NULL)) == 0 )      sleep();
-               ret = malloc(length);
-               SysGetMessage(NULL, ret);
-               break;
-       default:
-               break;
-       }
-       return ret;
-}
-
-/**
- * \brief Handles a recieved message
- */
-int AxWin_HandleMessage(tAxWin_Message *Message)
-{
-       switch(Message->ID)
-       {
-       default:        return 0;
-       }
-}
diff --git a/Usermode/Libraries/libaxwin2.so_src/windows.c b/Usermode/Libraries/libaxwin2.so_src/windows.c
deleted file mode 100644 (file)
index efb418b..0000000
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * AxWin Window Manager Interface Library
- * By John Hodge (thePowersGang)
- * This file is published under the terms of the Acess Licence. See the
- * file COPYING for details.
- * 
- * window.c - Window Control
- */
-#include "common.h"
-
-// === TYPES & STRUCTURES ===
-struct sAxWin_Window
-{
-       struct sAxWin_Window    *Next;
-       uint32_t        WmHandle;
-       tAxWin_MessageCallback  *Callback;
-};
-
-// === PROTOTYPES ===
-tAxWin_Window  *AxWin_CreateWindow(
-       int16_t X, int16_t Y, int16_t W, int16_t H,
-       uint32_t Flags, tAxWin_MessageCallback *Callback
-       );
-
-// === GLOBALS ===
-//mutex_t      glProcessWindows;
-tAxWin_Window  *gProcessWindows;
-
-// === CODE ===
-tAxWin_Window  *AxWin_CreateWindow(
-       int16_t X, int16_t Y,
-       int16_t W, int16_t H,
-       uint32_t Flags, tAxWin_MessageCallback *Callback)
-{
-       tAxWin_Message  req;
-       tAxWin_Message  *msg;
-       tAxWin_Window   *win;
-       
-       req.ID = MSG_SREQ_NEWWINDOW;
-       req.Size = 1 + sizeof(struct sAxWin_SReq_NewWindow)/4;
-       req.SReq_NewWindow.X = X;
-       req.SReq_NewWindow.Y = Y;
-       req.SReq_NewWindow.W = W;
-       req.SReq_NewWindow.H = H;
-       req.SReq_NewWindow.Flags = Flags;
-       
-       AxWin_SendMessage(&msg);
-       
-       for(;;)
-       {
-               msg = AxWin_WaitForMessage();
-               
-               if(msg.ID == MSG_SRSP_WINDOW)
-                       break;
-               
-               AxWin_HandleMessage(msg);
-               free(msg);
-       }
-       
-       win = malloc(sizeof(tAxWin_Window));
-       win->WmHandle = msg->SRsp_Window.Handle;
-       win->Callback = Callback;
-       
-       //mutex_acquire(glProcessWindows);
-       win->Next = gProcessWindows;
-       gProcessWindows = win;
-       //mutex_release(glProcessWindows);
-       
-       return 0;
-}

UCC git Repository :: git.ucc.asn.au