Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,7 +42,21 @@ enum | |
TEXT_MODE_AND = 0x21 | ||
}; | ||
|
||
typedef struct | ||
{ | ||
unsigned int I1; // unknown changes indicator height, set to 0 | ||
unsigned int indicatormaximum; // max logical indicator range | ||
unsigned int indicatorheight; // height of the indicator in units | ||
unsigned int indicatorpos; // indicator position in units of max | ||
unsigned int I5; // unknown, set to 0 | ||
unsigned short barleft; // x position of bar | ||
unsigned short bartop; // y position of bar | ||
unsigned short barheight; // height of bar | ||
unsigned short barwidth; // width of bar | ||
} TScrollbar; | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
AHelper
Author
Owner
|
||
|
||
void Bdisp_AreaClr_DD_x3( void*p1 ); | ||
void Bdisp_DDRegisterSelect( int registerno ); | ||
void Bdisp_EnableColor( int n ); | ||
void Print_OS( unsigned char*msg, int mode, int zero2 ); | ||
void Bdisp_PutDisp_DD( void ); | ||
|
@@ -63,18 +77,25 @@ void MsgBoxPop( void ); | |
void Box2( int, int ); | ||
void locate_OS( int X, int y ); | ||
void PrintLine( unsigned char*msg, int imax ); | ||
void *GetMiniGlyphPtr( unsigned short mb_glyph_no, unsigned short*glyph_info ); | ||
void PrintMiniGlyph(int x, int y, void*glyph, int mode_flags, int glyph_width, int, int, int, int, int color, int back_color, int ); | ||
void PrintXY_2( int mode, int x, int y, int msgno, int color ); | ||
void PrintXY( int x, int y, char*string, int mode, int color ); | ||
void PrintMini( int *x, int *y, unsigned char *MB_string, int mode_flags, unsigned int xlimit, int P6, int P7, int color, int back_color, int writeflag, int P11 ); | ||
void PrintMiniMini( int *x, int *y, unsigned char *MB_string, int mode1, char color, int mode2 ); | ||
void SaveVRAM_1( void ); | ||
void LoadVRAM_1( void ); | ||
void SetBackGround( int ); | ||
// These are needed for current addins and should be in this file | ||
int DefineStatusAreaFlags( int, int, void*, void* ); | ||
void DefineStatusMessage( char*msg, short P2, char P3, char P4 ); | ||
void DefineStatusMessage( char*msg, short P2, char color, char P4 ); | ||
void DisplayStatusArea( void ); | ||
void DrawFrame( int color ); | ||
void DrawHeaderLine( void ); | ||
void EnableStatusArea( int ); | ||
void Scrollbar(TScrollbar *scrollbar); | ||
void ProgressBar0(int P1, int P2, int P3, int current, int max); | ||
void ProgressBar2(unsigned char *heading, int current, int max); | ||
|
||
// Original Author, Shaun McFall (Merthsoft) | ||
// Used with permission | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
#ifndef _MISC_H_ | ||
#define _MISC_H_ | ||
|
||
#include <stddef.h> | ||
|
||
typedef unsigned short color_t; | ||
|
||
int PRGM_GetKey(); | ||
This comment has been minimized.
Sorry, something went wrong. |
||
|
||
void VRAM_CopySprite(const color_t* data, int x, int y, int width, int height); | ||
This comment has been minimized.
Sorry, something went wrong. |
||
void VRAM_XORSprite(const color_t* data, int x, int y, int width, int height); | ||
|
||
void sys_rand(unsigned seed); | ||
This comment has been minimized.
Sorry, something went wrong.
tari
|
||
void sys_srand(unsigned seed); | ||
|
||
void *sys_memmove(void *dest, const void *src, size_t n); | ||
|
||
void *memsetZero(void *s, size_t n); | ||
|
||
int sys_atoi(const char * s); | ||
|
||
void *sys_calloc(int elements, int elementSize); | ||
|
||
char *sys_strcat(char *dest, const char *src); | ||
char *sys_strchr(const char *s, int c); | ||
int sys_strcmp(const char *s1, const char *s2); | ||
char *sys_strcpy(char *dest, const char *src); | ||
char *sys_strncpy(char *dest, const char *src, size_t n); | ||
|
||
#ifdef USE_FXCG_STDLIB | ||
This comment has been minimized.
Sorry, something went wrong. |
||
|
||
#define atoi sys_atoi | ||
#define rand sys_rand | ||
#define srand sys_rand | ||
#define malloc sys_malloc | ||
This comment has been minimized.
Sorry, something went wrong.
tari
|
||
#define calloc sys_calloc | ||
#define realloc sys_realloc | ||
#define free sys_free | ||
#define memcmp sys_memcmp | ||
#define memcmp3 sys_memcmp3 | ||
#define memcpy sys_memcpy | ||
#define memset sys_memset | ||
#define memmove sys_memmove | ||
#define strlen sys_strlen | ||
#define strcpy sys_strcpy | ||
#define strncpy sys_strncpy | ||
#define strchr sys_strchr | ||
#define strcmp sys_strcmp | ||
#define strcat sys_strcat | ||
|
||
#endif | ||
|
||
#endif | ||
|
||
#ifdef __cplusplus | ||
} | ||
#endif |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#ifdef __cplusplus | ||
extern "C" { | ||
#endif | ||
|
||
// This adds in syscalls for interfacing with the OS | ||
|
||
void SetAutoPowerOffTime(int duration); // in minutes | ||
This comment has been minimized.
Sorry, something went wrong.
tari
|
||
void SetBacklightDuration(char duration); // in half-minutes | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong. |
||
|
||
int GetAutoPowerOffTime(); | ||
char GetBacklightDuration(); | ||
|
||
int GetMainBatteryVoltage(int one); | ||
#ifdef __cplusplus | ||
} | ||
#endif |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,6 +20,8 @@ long strtol(const char *str, char **str_end, int base); | |
void qsort(void *base, size_t nel, size_t width, int (*compar)(const void *, const void *)); | ||
|
||
void exit(int status); | ||
// This belongs here... | ||
void itoa( int value, unsigned char*result ); | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
AHelper
Author
Owner
|
||
|
||
#ifdef __cplusplus | ||
} | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include <asm.h> | ||
|
||
SYSCALL(_Bdisp_DDRegisterSelect, 0x01a2) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include <asm.h> | ||
|
||
SYSCALL(_Bfile_RenameEntry, 0x1DB3) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include <asm.h> | ||
|
||
SYSCALL(_GetAutoPowerOffTime, 0x1E91) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include <asm.h> | ||
|
||
SYSCALL(_GetBacklightDuration, 0x12D9) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include <asm.h> | ||
|
||
SYSCALL(_PrintMiniMini, 0x021B) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include <asm.h> | ||
|
||
SYSCALL(_ProgressBar2, 0x1809) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include <asm.h> | ||
|
||
SYSCALL(_SetAutoPowerOffTime, 0x1E90) | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#include <asm.h> | ||
|
||
SYSCALL(_SetBacklightDuration, 0x12D8) | ||
|
Change this name. I like fxcg_scrollbar_t, perhaps.