Merge pull request #1327 from SeanRamey/master
Basically, renames pc.c to 86box.c for easier merging with my linux branch later.
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -14,7 +14,7 @@
|
||||
#
|
||||
|
||||
# WIN32 marks us as a GUI app on Windows
|
||||
add_executable(86Box WIN32 pc.c config.c random.c timer.c io.c acpi.c apm.c
|
||||
add_executable(86Box WIN32 86box.c config.c random.c timer.c io.c acpi.c apm.c
|
||||
dma.c ddma.c nmi.c pic.c pit.c port_92.c ppi.c pci.c mca.c usb.c
|
||||
device.c nvr.c nvr_at.c nvr_ps2.c)
|
||||
|
||||
@@ -119,4 +119,4 @@ add_subdirectory(sio)
|
||||
add_subdirectory(scsi)
|
||||
add_subdirectory(sound)
|
||||
add_subdirectory(video)
|
||||
add_subdirectory(win)
|
||||
add_subdirectory(win)
|
||||
|
@@ -64,7 +64,7 @@ extern "C" {
|
||||
/* Global variables residing in the platform module. */
|
||||
extern int dopause, /* system is paused */
|
||||
doresize, /* screen resize requested */
|
||||
quited, /* system exit requested */
|
||||
is_quit, /* system exit requested */
|
||||
mouse_capture; /* mouse is captured in app */
|
||||
|
||||
#ifdef MTR_ENABLED
|
||||
|
@@ -38,11 +38,11 @@ else()
|
||||
endif()
|
||||
|
||||
if(DISCORD)
|
||||
# PUBLIC due to config.c and pc.c
|
||||
# PUBLIC due to config.c and 86box.c
|
||||
target_compile_definitions(ui PUBLIC USE_DISCORD)
|
||||
|
||||
target_sources(ui PRIVATE win_discord.c)
|
||||
endif()
|
||||
|
||||
target_link_libraries(86Box advapi32 comctl32 comdlg32 gdi32 shell32 iphlpapi
|
||||
dxguid imm32 hid setupapi uxtheme version winmm psapi)
|
||||
dxguid imm32 hid setupapi uxtheme version winmm psapi)
|
||||
|
@@ -41,7 +41,7 @@ ifeq ($(DEV_BUILD), y)
|
||||
endif
|
||||
ifndef CYRIX_6X86
|
||||
CYRIX_6X86 := y
|
||||
endif
|
||||
endif
|
||||
ifndef GUSMAX
|
||||
GUSMAX := y
|
||||
endif
|
||||
@@ -336,7 +336,7 @@ ifeq ($(X64), y)
|
||||
ifeq ($(OPTIM), y)
|
||||
DFLAGS := -march=native
|
||||
else
|
||||
DFLAGS :=
|
||||
DFLAGS :=
|
||||
endif
|
||||
else
|
||||
ifeq ($(OPTIM), y)
|
||||
@@ -609,7 +609,7 @@ CXXFLAGS := $(CFLAGS)
|
||||
#########################################################################
|
||||
# Create the (final) list of objects to build. #
|
||||
#########################################################################
|
||||
MAINOBJ := pc.o config.o random.o timer.o io.o acpi.o apm.o dma.o ddma.o \
|
||||
MAINOBJ := 86box.o config.o random.o timer.o io.o acpi.o apm.o dma.o ddma.o \
|
||||
nmi.o pic.o pit.o port_92.o ppi.o pci.o mca.o \
|
||||
usb.o device.o nvr.o nvr_at.o nvr_ps2.o \
|
||||
$(VNCOBJ)
|
||||
@@ -687,10 +687,10 @@ HDDOBJ := hdd.o \
|
||||
hdc_xtide.o hdc_ide.o \
|
||||
hdc_ide_opti611.o \
|
||||
hdc_ide_cmd640.o hdc_ide_sff8038i.o
|
||||
|
||||
|
||||
MINIVHDOBJ := cwalk.o libxml2_encoding.o minivhd_convert.o \
|
||||
minivhd_create.o minivhd_io.o minivhd_manage.o \
|
||||
minivhd_struct_rw.o minivhd_util.o
|
||||
minivhd_struct_rw.o minivhd_util.o
|
||||
|
||||
CDROMOBJ := cdrom.o \
|
||||
cdrom_image_backend.o cdrom_image.o
|
||||
@@ -719,7 +719,7 @@ NETOBJ := network.o \
|
||||
|
||||
PRINTOBJ := png.o prt_cpmap.o \
|
||||
prt_escp.o prt_text.o prt_ps.o
|
||||
|
||||
|
||||
SNDOBJ := sound.o \
|
||||
openal.o \
|
||||
snd_opl.o snd_opl_nuked.o \
|
||||
|
@@ -402,7 +402,7 @@ WinMain(HINSTANCE hInst, HINSTANCE hPrev, LPSTR lpszArg, int nCmdShow)
|
||||
free(argw);
|
||||
return(1);
|
||||
}
|
||||
|
||||
|
||||
/* Enable crash dump services. */
|
||||
if (enable_crashdump)
|
||||
InitCrashDump();
|
||||
@@ -431,7 +431,7 @@ main_thread(void *param)
|
||||
title_update = 1;
|
||||
old_time = GetTickCount();
|
||||
drawits = frames = 0;
|
||||
while (!quited) {
|
||||
while (!is_quit) {
|
||||
/* See if it is time to run a frame of code. */
|
||||
new_time = GetTickCount();
|
||||
drawits += (new_time - old_time);
|
||||
@@ -474,7 +474,7 @@ do_start(void)
|
||||
LARGE_INTEGER qpc;
|
||||
|
||||
/* We have not stopped yet. */
|
||||
quited = 0;
|
||||
is_quit = 0;
|
||||
|
||||
/* Initialize the high-precision timer. */
|
||||
timeBeginPeriod(1);
|
||||
@@ -483,7 +483,7 @@ do_start(void)
|
||||
win_log("Main timer precision: %llu\n", timer_freq);
|
||||
|
||||
/* Start the emulator, really. */
|
||||
thMain = thread_create(main_thread, &quited);
|
||||
thMain = thread_create(main_thread, &is_quit);
|
||||
SetThreadPriority(thMain, THREAD_PRIORITY_HIGHEST);
|
||||
}
|
||||
|
||||
@@ -492,7 +492,7 @@ do_start(void)
|
||||
void
|
||||
do_stop(void)
|
||||
{
|
||||
quited = 1;
|
||||
is_quit = 1;
|
||||
|
||||
plat_delay_ms(100);
|
||||
|
||||
@@ -719,7 +719,7 @@ plat_get_ticks(void)
|
||||
LARGE_INTEGER EndingTime, ElapsedMicroseconds;
|
||||
|
||||
if (first_use) {
|
||||
QueryPerformanceFrequency(&Frequency);
|
||||
QueryPerformanceFrequency(&Frequency);
|
||||
QueryPerformanceCounter(&StartingTime);
|
||||
first_use = 0;
|
||||
}
|
||||
@@ -911,7 +911,7 @@ plat_setfullscreen(int on)
|
||||
temp_y = unscaled_size_y;
|
||||
}
|
||||
|
||||
/* Main Window. */
|
||||
/* Main Window. */
|
||||
ResizeWindowByClientArea(hwndMain, temp_x, temp_y + sbar_height);
|
||||
}
|
||||
|
||||
|
@@ -118,7 +118,7 @@ int win_get_system_metrics(int index, int dpi) {
|
||||
if (pAreDpiAwarenessContextsEqual(c, DPI_AWARENESS_CONTEXT_PER_MONITOR_AWARE_V2))
|
||||
return pGetSystemMetricsForDpi(index, dpi);
|
||||
}
|
||||
|
||||
|
||||
return GetSystemMetrics(index);
|
||||
}
|
||||
|
||||
@@ -312,7 +312,7 @@ LowLevelKeyboardProc(int nCode, WPARAM wParam, LPARAM lParam)
|
||||
|
||||
if (nCode < 0 || nCode != HC_ACTION || (!mouse_capture && !video_fullscreen))
|
||||
return(CallNextHookEx(hKeyboardHook, nCode, wParam, lParam));
|
||||
|
||||
|
||||
p = (KBDLLHOOKSTRUCT*)lParam;
|
||||
|
||||
/* disable alt-tab */
|
||||
@@ -666,7 +666,7 @@ MainWindowProcedure(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||
|
||||
case IDM_VID_FS_FULL:
|
||||
case IDM_VID_FS_43:
|
||||
case IDM_VID_FS_KEEPRATIO:
|
||||
case IDM_VID_FS_KEEPRATIO:
|
||||
case IDM_VID_FS_INT:
|
||||
CheckMenuItem(hmenu, IDM_VID_FS_FULL+video_fullscreen_scale, MF_UNCHECKED);
|
||||
video_fullscreen_scale = LOWORD(wParam) - IDM_VID_FS_FULL;
|
||||
@@ -888,7 +888,7 @@ MainWindowProcedure(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||
else if ((wParam >= 0x8000) && (wParam <= 0x80ff))
|
||||
ui_sb_timer_callback(wParam & 0xff);
|
||||
break;
|
||||
|
||||
|
||||
case WM_LEAVEFULLSCREEN:
|
||||
plat_setfullscreen(0);
|
||||
config_save();
|
||||
@@ -1332,16 +1332,16 @@ ui_init(int nCmdShow)
|
||||
do_start();
|
||||
|
||||
/* Run the message loop. It will run until GetMessage() returns 0 */
|
||||
while (! quited) {
|
||||
while (! is_quit) {
|
||||
bRet = GetMessage(&messages, NULL, 0, 0);
|
||||
if ((bRet == 0) || quited) break;
|
||||
if ((bRet == 0) || is_quit) break;
|
||||
|
||||
if (bRet == -1) {
|
||||
fatal("bRet is -1\n");
|
||||
}
|
||||
|
||||
if (messages.message == WM_QUIT) {
|
||||
quited = 1;
|
||||
is_quit = 1;
|
||||
break;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user