More clean up of the Windows x64 build (trunk only)
This commit is contained in:
@@ -152,7 +152,7 @@ CALLBACK GetlinDlgProc(HWND hWnd, UINT message, WPARAM wParam, LONG_PTR lParam)
|
||||
{
|
||||
/* OK button was pressed */
|
||||
case IDOK:
|
||||
data = (struct getlin_data*)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (struct getlin_data*)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
SendDlgItemMessage(hWnd, IDC_GETLIN_EDIT, WM_GETTEXT, (WPARAM)sizeof(wbuf), (LPARAM)wbuf );
|
||||
NH_W2A(wbuf, data->result, data->result_size);
|
||||
|
||||
@@ -256,7 +256,7 @@ CALLBACK ExtCmdDlgProc(HWND hWnd, UINT message, WPARAM wParam, LONG_PTR lParam)
|
||||
break;
|
||||
|
||||
case WM_COMMAND:
|
||||
data = (struct extcmd_data*)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (struct extcmd_data*)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch (LOWORD(wParam))
|
||||
{
|
||||
/* OK button ws clicked */
|
||||
@@ -378,7 +378,7 @@ CALLBACK PlayerSelectorDlgProc(HWND hWnd, UINT message, WPARAM wParam, LONG_PTR
|
||||
break;
|
||||
|
||||
case WM_COMMAND:
|
||||
data = (struct plsel_data*)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (struct plsel_data*)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch (LOWORD(wParam)) {
|
||||
|
||||
/* OK button was clicked */
|
||||
|
||||
@@ -213,7 +213,7 @@ LRESULT CALLBACK MainWndProc(HWND hWnd, UINT message, UINT wParam, LPARAM lParam
|
||||
|
||||
case WM_KEYDOWN:
|
||||
{
|
||||
data = (PNHMainWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMainWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
/* translate arrow keys into nethack commands */
|
||||
switch (wParam)
|
||||
@@ -524,7 +524,7 @@ LRESULT CALLBACK MainWndProc(HWND hWnd, UINT message, UINT wParam, LPARAM lParam
|
||||
WM_QUIT somehow */
|
||||
|
||||
/* clean up */
|
||||
free( (PNHMainWindow)GetWindowLong(hWnd, GWLP_USERDATA) );
|
||||
free( (PNHMainWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA) );
|
||||
SetWindowLongPtr(hWnd, GWLP_USERDATA, (LONG)0);
|
||||
|
||||
// PostQuitMessage(0);
|
||||
@@ -584,7 +584,7 @@ void mswin_layout_main_window(HWND changed_child)
|
||||
|
||||
if( GetNHApp()->bAutoLayout ) {
|
||||
GetClientRect(GetNHApp()->hMainWnd, &client_rt);
|
||||
data = (PNHMainWindow)GetWindowLong(GetNHApp()->hMainWnd, GWLP_USERDATA);
|
||||
data = (PNHMainWindow)GetWindowLongPtr(GetNHApp()->hMainWnd, GWLP_USERDATA);
|
||||
|
||||
/* get sizes of child windows */
|
||||
wnd_status = mswin_hwnd_from_winid(WIN_STATUS);
|
||||
@@ -754,7 +754,7 @@ LRESULT onWMCommand(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
int wmId, wmEvent;
|
||||
PNHMainWindow data;
|
||||
|
||||
data = (PNHMainWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMainWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
wmId = LOWORD(wParam);
|
||||
wmEvent = HIWORD(wParam);
|
||||
|
||||
@@ -1039,7 +1039,7 @@ void mswin_select_map_mode(int mode)
|
||||
winid map_id;
|
||||
|
||||
map_id = WIN_MAP;
|
||||
data = (PNHMainWindow)GetWindowLong(GetNHApp()->hMainWnd, GWLP_USERDATA);
|
||||
data = (PNHMainWindow)GetWindowLongPtr(GetNHApp()->hMainWnd, GWLP_USERDATA);
|
||||
|
||||
/* override for Rogue level */
|
||||
#ifdef REINCARNATION
|
||||
@@ -1130,7 +1130,7 @@ void nhlock_windows( BOOL lock )
|
||||
for( i=0; i<MAXWINDOWS; i++ ) {
|
||||
if( IsWindow(GetNHApp()->windowlist[i].win) && !GetNHApp()->windowlist[i].dead) {
|
||||
DWORD style;
|
||||
style = GetWindowLong(GetNHApp()->windowlist[i].win, GWL_STYLE);
|
||||
style = GetWindowLongPtr(GetNHApp()->windowlist[i].win, GWL_STYLE);
|
||||
if( lock ) style &= ~WS_CAPTION;
|
||||
else style |= WS_CAPTION;
|
||||
SetWindowLongPtr(GetNHApp()->windowlist[i].win, GWL_STYLE, style);
|
||||
|
||||
@@ -106,7 +106,7 @@ void mswin_map_stretch(HWND hWnd, LPSIZE lpsz, BOOL redraw)
|
||||
wnd_size.cy = client_rt.bottom - client_rt.top;
|
||||
|
||||
/* set new screen tile size */
|
||||
data = (PNHMapWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMapWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
data->xScrTile =
|
||||
max(1, (data->bFitToScreenMode? wnd_size.cx : lpsz->cx) / COLNO);
|
||||
data->yScrTile =
|
||||
@@ -200,7 +200,7 @@ int mswin_map_mode(HWND hWnd, int mode)
|
||||
int oldMode;
|
||||
SIZE mapSize;
|
||||
|
||||
data = (PNHMapWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMapWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
if( mode == data->mapMode ) return mode;
|
||||
|
||||
oldMode = data->mapMode;
|
||||
@@ -333,7 +333,7 @@ LRESULT CALLBACK MapWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPara
|
||||
{
|
||||
PNHMapWindow data;
|
||||
|
||||
data = (PNHMapWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMapWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch (message)
|
||||
{
|
||||
case WM_CREATE:
|
||||
@@ -427,7 +427,7 @@ void onMSNHCommand(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
PNHMapWindow data;
|
||||
RECT rt;
|
||||
|
||||
data = (PNHMapWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMapWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch(wParam) {
|
||||
case MSNH_MSG_PRINT_GLYPH:
|
||||
{
|
||||
@@ -590,7 +590,7 @@ void onPaint(HWND hWnd)
|
||||
int i, j;
|
||||
|
||||
/* get window data */
|
||||
data = (PNHMapWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMapWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
hDC = BeginPaint(hWnd, &ps);
|
||||
|
||||
@@ -750,7 +750,7 @@ void onMSNH_VScroll(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
int yDelta;
|
||||
|
||||
/* get window data */
|
||||
data = (PNHMapWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMapWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
switch(LOWORD (wParam))
|
||||
{
|
||||
@@ -808,7 +808,7 @@ void onMSNH_HScroll(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
int xDelta;
|
||||
|
||||
/* get window data */
|
||||
data = (PNHMapWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMapWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
switch(LOWORD (wParam))
|
||||
{
|
||||
|
||||
@@ -121,7 +121,7 @@ HWND mswin_init_menu_window (int type) {
|
||||
|
||||
if( !GetNHApp()->bWindowsLocked ) {
|
||||
DWORD style;
|
||||
style = GetWindowLong(ret, GWL_STYLE);
|
||||
style = GetWindowLongPtr(ret, GWL_STYLE);
|
||||
style |= WS_CAPTION;
|
||||
SetWindowLongPtr(ret, GWL_STYLE, style);
|
||||
SetWindowPos(ret, NULL, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED);
|
||||
@@ -143,7 +143,7 @@ int mswin_menu_window_select_menu (HWND hWnd, int how, MENU_ITEM_P ** _selected,
|
||||
*_selected = NULL;
|
||||
ret_val = -1;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
/* force activate for certain menu types */
|
||||
if( data->type == MENU_TYPE_MENU &&
|
||||
@@ -254,7 +254,7 @@ LRESULT CALLBACK MenuWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPar
|
||||
TCHAR title[MAX_LOADSTRING];
|
||||
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch (message)
|
||||
{
|
||||
case WM_INITDIALOG:
|
||||
@@ -501,7 +501,7 @@ void onMSNHCommand(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
PNHMenuWindow data;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch( wParam ) {
|
||||
case MSNH_MSG_PUTSTR:
|
||||
{
|
||||
@@ -659,7 +659,7 @@ void LayoutMenu(HWND hWnd)
|
||||
POINT pt_elem, pt_ok, pt_cancel;
|
||||
SIZE sz_elem, sz_ok, sz_cancel;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
menu_ok = GetDlgItem(hWnd, IDOK);
|
||||
menu_cancel = GetDlgItem(hWnd, IDCANCEL);
|
||||
|
||||
@@ -729,7 +729,7 @@ void SetMenuType(HWND hWnd, int type)
|
||||
PNHMenuWindow data;
|
||||
HWND list, text;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
data->type = type;
|
||||
|
||||
@@ -764,7 +764,7 @@ void SetMenuListType(HWND hWnd, int how)
|
||||
LVCOLUMN lvcol;
|
||||
LRESULT fnt;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
if( data->type != MENU_TYPE_MENU ) return;
|
||||
|
||||
data->how = how;
|
||||
@@ -853,7 +853,7 @@ HWND GetMenuControl(HWND hWnd)
|
||||
{
|
||||
PNHMenuWindow data;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
if(data->type==MENU_TYPE_TEXT) {
|
||||
return GetDlgItem(hWnd, IDC_MENU_TEXT);
|
||||
@@ -873,7 +873,7 @@ BOOL onMeasureItem(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
int i;
|
||||
|
||||
lpmis = (LPMEASUREITEMSTRUCT) lParam;
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
GetClientRect(GetMenuControl(hWnd), &list_rect);
|
||||
|
||||
hdc = GetDC(GetMenuControl(hWnd));
|
||||
@@ -921,7 +921,7 @@ BOOL onDrawItem(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
/* If there are no list box items, skip this message. */
|
||||
if (lpdis->itemID == -1) return FALSE;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
item = &data->menu.items[lpdis->itemID];
|
||||
|
||||
@@ -1118,7 +1118,7 @@ BOOL onListChar(HWND hWnd, HWND hwndList, WORD ch)
|
||||
int curIndex, topIndex, pageSize;
|
||||
boolean is_accelerator = FALSE;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
switch( ch ) {
|
||||
case MENU_FIRST_PAGE:
|
||||
@@ -1435,7 +1435,7 @@ void mswin_menu_window_size (HWND hWnd, LPSIZE sz)
|
||||
RECT rt, wrt;
|
||||
int extra_cx;
|
||||
|
||||
data = (PNHMenuWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMenuWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
if(data) {
|
||||
control = GetMenuControl(hWnd);
|
||||
|
||||
|
||||
@@ -160,7 +160,7 @@ LRESULT CALLBACK NHMessageWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM
|
||||
case WM_DESTROY:
|
||||
{
|
||||
PNHMessageWindow data;
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
free(data);
|
||||
SetWindowLongPtr(hWnd, GWLP_USERDATA, (LONG)0);
|
||||
} break;
|
||||
@@ -173,7 +173,7 @@ LRESULT CALLBACK NHMessageWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM
|
||||
PNHMessageWindow data;
|
||||
RECT rt;
|
||||
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
xNewSize = LOWORD(lParam);
|
||||
yNewSize = HIWORD(lParam);
|
||||
@@ -238,7 +238,7 @@ void onMSNHCommand(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
PNHMessageWindow data;
|
||||
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch( wParam ) {
|
||||
case MSNH_MSG_PUTSTR:
|
||||
{
|
||||
@@ -382,7 +382,7 @@ void onMSNH_VScroll(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
int yInc;
|
||||
|
||||
/* get window data */
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
ZeroMemory(&si, sizeof(si));
|
||||
si.cbSize = sizeof(si);
|
||||
@@ -459,7 +459,7 @@ void onMSNH_HScroll(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
int xInc;
|
||||
|
||||
/* get window data */
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
ZeroMemory(&si, sizeof(si));
|
||||
si.cbSize = sizeof(si);
|
||||
@@ -570,7 +570,7 @@ void onPaint(HWND hWnd)
|
||||
OldBg = SetBkColor(hdc, message_bg_brush ? message_bg_color : (COLORREF)GetSysColor(DEFAULT_COLOR_BG_MSG));
|
||||
OldFg = setMsgTextColor(hdc, 0);
|
||||
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
GetClientRect(hWnd, &client_rt);
|
||||
|
||||
@@ -673,7 +673,7 @@ void mswin_message_window_size (HWND hWnd, LPSIZE sz)
|
||||
PNHMessageWindow data;
|
||||
RECT rt, client_rt;
|
||||
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
if( !data ) return;
|
||||
|
||||
/* -- Calculate the font size -- */
|
||||
@@ -714,7 +714,7 @@ BOOL can_append_text(HWND hWnd, int attr, const char* text )
|
||||
RECT draw_rt;
|
||||
BOOL retval = FALSE;
|
||||
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
/* cannot append if lines_not_seen is 0 (beginning of the new turn */
|
||||
if( data->lines_not_seen==0 ) return FALSE;
|
||||
@@ -765,7 +765,7 @@ BOOL more_prompt_check(HWND hWnd)
|
||||
int remaining_height;
|
||||
char tmptext[MAXWINDOWTEXT+1];
|
||||
|
||||
data = (PNHMessageWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHMessageWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
if( data->lines_not_seen==0 ) return FALSE; /* don't bother checking - nothig to "more" */
|
||||
if( data->lines_not_seen>=MSG_LINES ) return TRUE; /* history size exceeded - always more */
|
||||
|
||||
@@ -62,7 +62,7 @@ void mswin_display_RIP_window (HWND hWnd)
|
||||
HDC hdc;
|
||||
HFONT OldFont;
|
||||
|
||||
data = (PNHRIPWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHRIPWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
|
||||
GetNHApp()->hPopupWnd = hWnd;
|
||||
mapWnd = mswin_hwnd_from_winid(WIN_MAP);
|
||||
@@ -122,7 +122,7 @@ LRESULT CALLBACK NHRIPWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lPa
|
||||
HDC hdc;
|
||||
PNHRIPWindow data;
|
||||
|
||||
data = (PNHRIPWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHRIPWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch (message)
|
||||
{
|
||||
case WM_INITDIALOG:
|
||||
@@ -229,7 +229,7 @@ void onMSNHCommand(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
PNHRIPWindow data;
|
||||
static int InRipText = 1;
|
||||
data = (PNHRIPWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHRIPWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch( wParam ) {
|
||||
case MSNH_MSG_PUTSTR: {
|
||||
PMSNHMsgPutstr msg_data = (PMSNHMsgPutstr)lParam;
|
||||
|
||||
@@ -95,7 +95,7 @@ LRESULT CALLBACK StatusWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lP
|
||||
HDC hdc;
|
||||
PNHStatusWindow data;
|
||||
|
||||
data = (PNHStatusWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHStatusWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch (message)
|
||||
{
|
||||
case WM_MSNH_COMMAND: {
|
||||
@@ -197,7 +197,7 @@ void mswin_status_window_size (HWND hWnd, LPSIZE sz)
|
||||
sz->cx = rt.right - rt.left;
|
||||
sz->cy = rt.bottom - rt.top;
|
||||
|
||||
data = (PNHStatusWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHStatusWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
if(data) {
|
||||
hdc = GetDC(hWnd);
|
||||
saveFont = SelectObject(hdc, mswin_get_font(NHW_STATUS, ATR_NONE, hdc, FALSE));
|
||||
|
||||
@@ -53,7 +53,7 @@ HWND mswin_init_text_window () {
|
||||
SetWindowText(ret, "Text");
|
||||
if( !GetNHApp()->bWindowsLocked ) {
|
||||
DWORD style;
|
||||
style = GetWindowLong(ret, GWL_STYLE);
|
||||
style = GetWindowLongPtr(ret, GWL_STYLE);
|
||||
style |= WS_CAPTION;
|
||||
SetWindowLongPtr(ret, GWL_STYLE, style);
|
||||
SetWindowPos(ret, NULL, 0, 0, 0, 0, SWP_NOMOVE | SWP_NOSIZE | SWP_NOZORDER | SWP_FRAMECHANGED);
|
||||
@@ -71,7 +71,7 @@ void mswin_display_text_window (HWND hWnd)
|
||||
{
|
||||
PNHTextWindow data;
|
||||
|
||||
data = (PNHTextWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHTextWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
if( data && data->window_text ) {
|
||||
HWND control;
|
||||
control = GetDlgItem(hWnd, IDC_TEXT_CONTROL);
|
||||
@@ -90,7 +90,7 @@ LRESULT CALLBACK NHTextWndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lP
|
||||
PNHTextWindow data;
|
||||
TCHAR title[MAX_LOADSTRING];
|
||||
|
||||
data = (PNHTextWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHTextWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch (message)
|
||||
{
|
||||
case WM_INITDIALOG:
|
||||
@@ -191,7 +191,7 @@ void onMSNHCommand(HWND hWnd, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
PNHTextWindow data;
|
||||
|
||||
data = (PNHTextWindow)GetWindowLong(hWnd, GWLP_USERDATA);
|
||||
data = (PNHTextWindow)GetWindowLongPtr(hWnd, GWLP_USERDATA);
|
||||
switch( wParam ) {
|
||||
case MSNH_MSG_PUTSTR: {
|
||||
PMSNHMsgPutstr msg_data = (PMSNHMsgPutstr)lParam;
|
||||
|
||||
Reference in New Issue
Block a user