diff options
author | John Ankarström <john@ankarstrom.se> | 2022-09-02 20:16:04 +0200 |
---|---|---|
committer | John Ankarström <john@ankarstrom.se> | 2022-09-02 20:16:18 +0200 |
commit | bc4cef92d8efbf97a9215122abc2d7247c287f12 (patch) | |
tree | a5ca307281c4f143b5f172428c9fd2b629d6b426 /c/test.cpp | |
parent | 5c1c2ce2bdbf9735ad8a4d162609a8c22a4f0954 (diff) | |
download | EpisodeBrowser-bc4cef92d8efbf97a9215122abc2d7247c287f12.tar.gz |
Improve Window object.
Diffstat (limited to 'c/test.cpp')
-rw-r--r-- | c/test.cpp | 16 |
1 files changed, 9 insertions, 7 deletions
@@ -4,11 +4,11 @@ #include "data.h" #include "episodelistview.h" #include "ext.h" -#include "main.h" #include "util.h" -#include "win.h" +#include "win32.h" +#include "window.h" -extern Window* g_window; +Window* s_window; struct Test { @@ -36,8 +36,8 @@ TESTS TEST(IO) { - ElvDataA& e1_0 = g_window->fvElv.At(5); - ElvDataA& e2_0 = g_window->fvElv.At(9); + ElvDataA& e1_0 = s_window->fvElv.At(5); + ElvDataA& e2_0 = s_window->fvElv.At(9); /* Write two ElvDataA structs to disk. */ { @@ -91,7 +91,7 @@ TESTS // TEST(MigrateCfg) // { // FileView<CfgB> fvb = FileView<CfgB>::Initialized(L"cfgb.dat", 1); -// CfgA* a = &g_window->cfg; +// CfgA* a = &s_window->cfg; // CfgB* b = fvb+0; // #define CPY(member) b->member = a->member; @@ -113,8 +113,10 @@ TESTS // } }; -int RunTests() +int RunTests(Window& window) { + s_window = &window; + const Test tests[] = { StrcpyWithSmallerDestination(), //IO(), |