Removed unused stuff; cleanup
svn-id: r14052
This commit is contained in:
parent
c399ca8486
commit
bb3ef09efa
6 changed files with 10 additions and 49 deletions
|
@ -68,7 +68,7 @@ int GFX_Init(OSystem *system, int width, int height) {
|
||||||
|
|
||||||
// For now, always show the mouse cursor.
|
// For now, always show the mouse cursor.
|
||||||
GFX_SetCursor(1);
|
GFX_SetCursor(1);
|
||||||
SYSINPUT_ShowMouse();
|
g_system->showMouse(true);
|
||||||
|
|
||||||
return R_SUCCESS;
|
return R_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,11 +32,7 @@
|
||||||
|
|
||||||
namespace Saga {
|
namespace Saga {
|
||||||
|
|
||||||
static int _mouse_x, _mouse_y;
|
static R_POINT _mousePos;
|
||||||
|
|
||||||
int SYSINPUT_Init() {
|
|
||||||
return R_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
int SYSINPUT_ProcessInput() {
|
int SYSINPUT_ProcessInput() {
|
||||||
OSystem::Event event;
|
OSystem::Event event;
|
||||||
|
@ -120,10 +116,9 @@ int SYSINPUT_ProcessInput() {
|
||||||
INTERFACE_Update(&imouse_pt, UPDATE_MOUSECLICK);
|
INTERFACE_Update(&imouse_pt, UPDATE_MOUSECLICK);
|
||||||
break;
|
break;
|
||||||
case OSystem::EVENT_MOUSEMOVE:
|
case OSystem::EVENT_MOUSEMOVE:
|
||||||
_mouse_x = event.mouse.x;
|
_mousePos.x = event.mouse.x;
|
||||||
_mouse_y = event.mouse.y;
|
_mousePos.y = event.mouse.y;
|
||||||
imouse_pt.x = _mouse_x;
|
imouse_pt = _mousePos;
|
||||||
imouse_pt.y = _mouse_y;
|
|
||||||
break;
|
break;
|
||||||
case OSystem::EVENT_QUIT:
|
case OSystem::EVENT_QUIT:
|
||||||
g_system->quit();
|
g_system->quit();
|
||||||
|
@ -136,23 +131,8 @@ int SYSINPUT_ProcessInput() {
|
||||||
return R_SUCCESS;
|
return R_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
int SYSINPUT_GetMousePos(int *mouse_x, int *mouse_y) {
|
R_POINT SYSINPUT_GetMousePos() {
|
||||||
*mouse_x = _mouse_x;
|
return _mousePos;
|
||||||
*mouse_y = _mouse_y;
|
|
||||||
|
|
||||||
return R_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
int SYSINPUT_HideMouse() {
|
|
||||||
g_system->showMouse(false);
|
|
||||||
|
|
||||||
return R_SUCCESS;
|
|
||||||
}
|
|
||||||
|
|
||||||
int SYSINPUT_ShowMouse() {
|
|
||||||
g_system->showMouse(true);
|
|
||||||
|
|
||||||
return R_SUCCESS;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
} // End of namespace Saga
|
} // End of namespace Saga
|
||||||
|
|
|
@ -71,14 +71,6 @@ struct R_SURFACE {
|
||||||
#define R_RGB_GREEN 0x0000FF00UL
|
#define R_RGB_GREEN 0x0000FF00UL
|
||||||
#define R_RGB_BLUE 0x000000FFUL
|
#define R_RGB_BLUE 0x000000FFUL
|
||||||
|
|
||||||
struct SAGA_COLOR {
|
|
||||||
byte r;
|
|
||||||
byte g;
|
|
||||||
byte b;
|
|
||||||
};
|
|
||||||
|
|
||||||
#define SAGA_COLOR_LEN 3
|
|
||||||
|
|
||||||
struct PALENTRY {
|
struct PALENTRY {
|
||||||
byte red;
|
byte red;
|
||||||
byte green;
|
byte green;
|
||||||
|
@ -86,7 +78,6 @@ struct PALENTRY {
|
||||||
};
|
};
|
||||||
|
|
||||||
enum R_ERRORCODE {
|
enum R_ERRORCODE {
|
||||||
R_STOP = -3,
|
|
||||||
R_MEM = -2,
|
R_MEM = -2,
|
||||||
R_FAILURE = -1,
|
R_FAILURE = -1,
|
||||||
R_SUCCESS = 0
|
R_SUCCESS = 0
|
||||||
|
@ -102,7 +93,6 @@ int TRANSITION_Dissolve(byte *dst_img, int dst_w, int dst_h,
|
||||||
#define R_PAL_ENTRIES 256
|
#define R_PAL_ENTRIES 256
|
||||||
|
|
||||||
int GFX_Init(OSystem *system, int width, int height);
|
int GFX_Init(OSystem *system, int width, int height);
|
||||||
R_SURFACE *GFX_GetScreenSurface();
|
|
||||||
R_SURFACE *GFX_GetBackBuffer();
|
R_SURFACE *GFX_GetBackBuffer();
|
||||||
int GFX_GetWhite();
|
int GFX_GetWhite();
|
||||||
int GFX_GetBlack();
|
int GFX_GetBlack();
|
||||||
|
@ -113,11 +103,8 @@ int GFX_PalToBlack(R_SURFACE *surface, PALENTRY *src_pal, double percent);
|
||||||
int GFX_BlackToPal(R_SURFACE *surface, PALENTRY *src_pal, double percent);
|
int GFX_BlackToPal(R_SURFACE *surface, PALENTRY *src_pal, double percent);
|
||||||
|
|
||||||
// System : Input
|
// System : Input
|
||||||
int SYSINPUT_Init();
|
|
||||||
int SYSINPUT_ProcessInput(void);
|
int SYSINPUT_ProcessInput(void);
|
||||||
int SYSINPUT_GetMousePos(int *mouse_x, int *mouse_y);
|
R_POINT SYSINPUT_GetMousePos();
|
||||||
int SYSINPUT_HideMouse(void);
|
|
||||||
int SYSINPUT_ShowMouse(void);
|
|
||||||
|
|
||||||
} // End of namespace Saga
|
} // End of namespace Saga
|
||||||
|
|
||||||
|
|
|
@ -112,7 +112,6 @@ int RENDER_DrawScene() {
|
||||||
char txt_buf[20];
|
char txt_buf[20];
|
||||||
int fps_width;
|
int fps_width;
|
||||||
R_POINT mouse_pt;
|
R_POINT mouse_pt;
|
||||||
int mouse_x, mouse_y;
|
|
||||||
|
|
||||||
if (!RenderModule.initialized) {
|
if (!RenderModule.initialized) {
|
||||||
return R_FAILURE;
|
return R_FAILURE;
|
||||||
|
@ -123,10 +122,7 @@ int RENDER_DrawScene() {
|
||||||
backbuf_surface = RenderModule.r_backbuf_surface;
|
backbuf_surface = RenderModule.r_backbuf_surface;
|
||||||
|
|
||||||
// Get mouse coordinates
|
// Get mouse coordinates
|
||||||
SYSINPUT_GetMousePos(&mouse_x, &mouse_y);
|
mouse_pt = SYSINPUT_GetMousePos();
|
||||||
|
|
||||||
mouse_pt.x = mouse_x;
|
|
||||||
mouse_pt.y = mouse_y;
|
|
||||||
|
|
||||||
SCENE_GetBGInfo(&bg_info);
|
SCENE_GetBGInfo(&bg_info);
|
||||||
GAME_GetDisplayInfo(&disp_info);
|
GAME_GetDisplayInfo(&disp_info);
|
||||||
|
|
|
@ -206,8 +206,6 @@ void SagaEngine::go() {
|
||||||
debug(0, "Sound disabled.");
|
debug(0, "Sound disabled.");
|
||||||
}
|
}
|
||||||
|
|
||||||
SYSINPUT_Init();
|
|
||||||
|
|
||||||
SYSTIMER_ResetMSCounter();
|
SYSTIMER_ResetMSCounter();
|
||||||
|
|
||||||
// Begin Main Engine Loop
|
// Begin Main Engine Loop
|
||||||
|
|
|
@ -42,7 +42,7 @@ class SndRes;
|
||||||
class Sound;
|
class Sound;
|
||||||
class Music;
|
class Music;
|
||||||
|
|
||||||
typedef Common::MemoryReadStream MemoryReadStream;
|
using Common::MemoryReadStream;
|
||||||
|
|
||||||
#define R_PBOUNDS(n,max) (((n)>=(0))&&((n)<(max)))
|
#define R_PBOUNDS(n,max) (((n)>=(0))&&((n)<(max)))
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue