diff options
-rw-r--r-- | c/data.h | 1 | ||||
-rw-r--r-- | c/datalistview.cpp | 1 | ||||
-rw-r--r-- | c/debug.cpp | 2 | ||||
-rw-r--r-- | c/episodelistview.cpp | 3 | ||||
-rw-r--r-- | c/episodelistview.h | 2 |
5 files changed, 5 insertions, 4 deletions
@@ -2,6 +2,7 @@ #define DATA_H #include <stdexcept> +#include <windows.h> #include "pl.h" #include "util.h" diff --git a/c/datalistview.cpp b/c/datalistview.cpp index f04b270..9b3de7a 100644 --- a/c/datalistview.cpp +++ b/c/datalistview.cpp @@ -10,6 +10,7 @@ #include "listview.h" #include "layout.h" #include "pl.h" +#include "wcharptr.h" DataListView::DataListView(const HWND hWndParent) : ListView(hWndParent, reinterpret_cast<HMENU>(IDC_DATALISTVIEW), LVS_NOCOLUMNHEADER) diff --git a/c/debug.cpp b/c/debug.cpp index b23df37..a7f7595 100644 --- a/c/debug.cpp +++ b/c/debug.cpp @@ -11,13 +11,13 @@ struct Avg { long long sum; }; +static LARGE_INTEGER liFreq; static long long freq; Benchmark::Benchmark(const char* const name, const int id, const int avgmax) : id(id), avgmax(avgmax), name(name) { if (!freq) { - static LARGE_INTEGER liFreq; if (!QueryPerformanceFrequency(&liFreq)) throw Win32Error{}; freq = liFreq.QuadPart; diff --git a/c/episodelistview.cpp b/c/episodelistview.cpp index 824b527..f004f8a 100644 --- a/c/episodelistview.cpp +++ b/c/episodelistview.cpp @@ -13,8 +13,7 @@ #include "win.h" EpisodeListView::EpisodeListView(const HWND hWndParent) - : ListView(hWndParent, reinterpret_cast<HMENU>(IDC_EPISODELISTVIEW), 0), - m_fv(L"elvdata.dat", ELVMAX) + : ListView(hWndParent, reinterpret_cast<HMENU>(IDC_EPISODELISTVIEW), 0) { LVCOLUMN lvc; diff --git a/c/episodelistview.h b/c/episodelistview.h index ee5bc22..62ce42e 100644 --- a/c/episodelistview.h +++ b/c/episodelistview.h @@ -35,7 +35,7 @@ struct EpisodeListView : public ListView private: int m_iSortCol; static int CALLBACK SortProc(LPARAM lParam1, LPARAM lParam2, LPARAM extra); - FileView<ElvDataA> m_fv; + FileView<ElvDataA> m_fv{L"elvdata.dat", ELVMAX}; }; #endif |