mirror of
https://github.com/quantum5/Zalgo.git
synced 2025-04-24 21:52:03 -04:00
Fixed various bugs introduced by previous commit.
Signed-off-by: Xiaomao Chen <xiaomao5@live.com>
This commit is contained in:
parent
053a308d6a
commit
df3493dbcd
|
@ -11,8 +11,8 @@ void MainWindow::OnLoadFile()
|
||||||
HANDLE file = INVALID_HANDLE_VALUE, mapping = 0;
|
HANDLE file = INVALID_HANDLE_VALUE, mapping = 0;
|
||||||
LPSTR data = NULL;
|
LPSTR data = NULL;
|
||||||
LPWSTR storage = NULL;
|
LPWSTR storage = NULL;
|
||||||
int codepage = 0
|
int codepage;
|
||||||
DWORD size = 0, length = 0;
|
DWORD size, length;
|
||||||
|
|
||||||
ofn.hwndOwner = m_hwnd;
|
ofn.hwndOwner = m_hwnd;
|
||||||
ofn.lpstrFilter = L"Text Files (*.txt)\0*.txt\0All Files (*.*)\0*.*\0";
|
ofn.lpstrFilter = L"Text Files (*.txt)\0*.txt\0All Files (*.*)\0*.*\0";
|
||||||
|
@ -88,8 +88,8 @@ void MainWindow::OnSaveFile()
|
||||||
LPSTR storage = NULL;
|
LPSTR storage = NULL;
|
||||||
HANDLE file = INVALID_HANDLE_VALUE;
|
HANDLE file = INVALID_HANDLE_VALUE;
|
||||||
HLOCAL buf = NULL;
|
HLOCAL buf = NULL;
|
||||||
int codepage = 0;
|
int codepage;
|
||||||
DWORD length = 0, size = 0, written = 0;
|
DWORD length, size, written;
|
||||||
|
|
||||||
ofn.hwndOwner = m_hwnd;
|
ofn.hwndOwner = m_hwnd;
|
||||||
ofn.lpstrFilter = L"Text Files (*.txt)\0*.txt\0All Files (*.*)\0*.*\0";
|
ofn.lpstrFilter = L"Text Files (*.txt)\0*.txt\0All Files (*.*)\0*.*\0";
|
||||||
|
|
|
@ -3,6 +3,11 @@
|
||||||
#include <resource.h>
|
#include <resource.h>
|
||||||
#include <windowsx.h>
|
#include <windowsx.h>
|
||||||
|
|
||||||
|
#ifndef max
|
||||||
|
#define max(a, b) (((a) > (b)) ? (a) : (b))
|
||||||
|
#define min(a, b) (((a) < (b)) ? (a) : (b))
|
||||||
|
#endif
|
||||||
|
|
||||||
LRESULT PreviewWindow::OnCreate()
|
LRESULT PreviewWindow::OnCreate()
|
||||||
{
|
{
|
||||||
LOGFONT lf;
|
LOGFONT lf;
|
||||||
|
|
Loading…
Reference in a new issue