Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
29e3c63a
Commit
29e3c63a
authored
Jan 10, 2005
by
Mike McCormack
Committed by
Alexandre Julliard
Jan 10, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add proxy authentication dialog.
parent
fd14bdeb
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
118 additions
and
2 deletions
+118
-2
mpr.rc
dlls/mpr/mpr.rc
+1
-0
mpr_En.rc
dlls/mpr/mpr_En.rc
+20
-0
mprres.h
dlls/mpr/mprres.h
+9
-0
nps.c
dlls/mpr/nps.c
+88
-2
No files found.
dlls/mpr/mpr.rc
View file @
29e3c63a
...
@@ -19,6 +19,7 @@
...
@@ -19,6 +19,7 @@
*/
*/
#include "windef.h"
#include "windef.h"
#include "winbase.h"
#include "winbase.h"
#include "winuser.h"
#include "mprres.h"
#include "mprres.h"
#include "version.rc"
#include "version.rc"
...
...
dlls/mpr/mpr_En.rc
View file @
29e3c63a
...
@@ -24,3 +24,23 @@ STRINGTABLE DISCARDABLE
...
@@ -24,3 +24,23 @@ STRINGTABLE DISCARDABLE
{
{
IDS_ENTIRENETWORK "Entire Network"
IDS_ENTIRENETWORK "Entire Network"
}
}
IDD_PROXYDLG DIALOG LOADONCALL MOVEABLE DISCARDABLE 36, 24, 250, 154
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
CAPTION "Enter Network Password"
FONT 8, "Helv"
{
LTEXT "Please enter your username and password:", IDC_EXPLAIN, 40, 6, 150, 15
LTEXT "Proxy", -1, 40, 26, 50, 10
/* LTEXT "Realm", -1, 40, 46, 50, 10 */
LTEXT "User", -1, 40, 66, 50, 10
LTEXT "Password", -1, 40, 86, 50, 10
LTEXT "" IDC_PROXY, 80, 26, 150, 14, 0
LTEXT "" IDC_REALM, 80, 46, 150, 14, 0
EDITTEXT IDC_USERNAME, 80, 66, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP
EDITTEXT IDC_PASSWORD, 80, 86, 150, 14, ES_AUTOHSCROLL | WS_BORDER | WS_TABSTOP | ES_PASSWORD
CHECKBOX "&Save this password (Insecure)", IDC_SAVEPASSWORD,
80, 106, 150, 12, BS_AUTOCHECKBOX | WS_GROUP | WS_TABSTOP
PUSHBUTTON "OK", IDOK, 98, 126, 56, 14, WS_GROUP | WS_TABSTOP | BS_DEFPUSHBUTTON
PUSHBUTTON "Cancel", IDCANCEL, 158, 126, 56, 14, WS_GROUP | WS_TABSTOP
}
dlls/mpr/mprres.h
View file @
29e3c63a
...
@@ -20,4 +20,13 @@
...
@@ -20,4 +20,13 @@
#define IDS_ENTIRENETWORK 1
#define IDS_ENTIRENETWORK 1
#define IDD_PROXYDLG 0x400
#define IDC_PROXY 0x401
#define IDC_REALM 0x402
#define IDC_USERNAME 0x403
#define IDC_PASSWORD 0x404
#define IDC_SAVEPASSWORD 0x405
#define IDC_EXPLAIN 0x406
#endif
/* ndef __WINE_MPRRES_H__ */
#endif
/* ndef __WINE_MPRRES_H__ */
dlls/mpr/nps.c
View file @
29e3c63a
...
@@ -2,6 +2,7 @@
...
@@ -2,6 +2,7 @@
* MPR Network Provider Services functions
* MPR Network Provider Services functions
*
*
* Copyright 1999 Ulrich Weigand
* Copyright 1999 Ulrich Weigand
* Copyright 2004 Mike McCormack for CodeWeavers Inc.
*
*
* This library is free software; you can redistribute it and/or
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* modify it under the terms of the GNU Lesser General Public
...
@@ -18,24 +19,109 @@
...
@@ -18,24 +19,109 @@
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
*/
#include "config.h"
#include <stdarg.h>
#include <stdarg.h>
#include "windef.h"
#include "windef.h"
#include "winbase.h"
#include "winbase.h"
#include "winuser.h"
#include "winnetwk.h"
#include "winnetwk.h"
#include "netspi.h"
#include "netspi.h"
#include "wine/debug.h"
#include "wine/debug.h"
#include "winerror.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
mpr
);
WINE_DEFAULT_DEBUG_CHANNEL
(
mpr
);
#include "wine/unicode.h"
#include "mprres.h"
/***********************************************************************
* NPS_ProxyPasswordDialog
*/
static
INT_PTR
WINAPI
NPS_ProxyPasswordDialog
(
HWND
hdlg
,
UINT
uMsg
,
WPARAM
wParam
,
LPARAM
lParam
)
{
HWND
hitem
;
LPAUTHDLGSTRUCTA
lpAuthDlgStruct
;
if
(
uMsg
==
WM_INITDIALOG
)
{
TRACE
(
"WM_INITDIALOG (%08lx)
\n
"
,
lParam
);
/* save the parameter list */
lpAuthDlgStruct
=
(
LPAUTHDLGSTRUCTA
)
lParam
;
SetWindowLongPtrW
(
hdlg
,
GWLP_USERDATA
,
lParam
);
if
(
lpAuthDlgStruct
->
lpExplainText
)
{
hitem
=
GetDlgItem
(
hdlg
,
IDC_EXPLAIN
);
SetWindowTextA
(
hitem
,
lpAuthDlgStruct
->
lpExplainText
);
}
/* extract the Realm from the proxy response and show it */
if
(
lpAuthDlgStruct
->
lpResource
)
{
hitem
=
GetDlgItem
(
hdlg
,
IDC_REALM
);
SetWindowTextA
(
hitem
,
lpAuthDlgStruct
->
lpResource
);
}
return
TRUE
;
}
lpAuthDlgStruct
=
(
LPAUTHDLGSTRUCTA
)
GetWindowLongPtrW
(
hdlg
,
GWLP_USERDATA
);
switch
(
uMsg
)
{
case
WM_COMMAND
:
if
(
wParam
==
IDOK
)
{
WCHAR
username
[
0x20
],
password
[
0x20
];
username
[
0
]
=
0
;
hitem
=
GetDlgItem
(
hdlg
,
IDC_USERNAME
);
if
(
hitem
)
GetWindowTextA
(
hitem
,
lpAuthDlgStruct
->
lpUsername
,
lpAuthDlgStruct
->
cbUsername
);
password
[
0
]
=
0
;
hitem
=
GetDlgItem
(
hdlg
,
IDC_PASSWORD
);
if
(
hitem
)
GetWindowTextA
(
hitem
,
lpAuthDlgStruct
->
lpPassword
,
lpAuthDlgStruct
->
cbPassword
);
EndDialog
(
hdlg
,
WN_SUCCESS
);
return
TRUE
;
}
if
(
wParam
==
IDCANCEL
)
{
EndDialog
(
hdlg
,
WN_CANCEL
);
return
TRUE
;
}
break
;
}
return
FALSE
;
}
/*****************************************************************
/*****************************************************************
* NPSAuthenticationDialogA [MPR.@]
* NPSAuthenticationDialogA [MPR.@]
*/
*/
DWORD
WINAPI
NPSAuthenticationDialogA
(
LPAUTHDLGSTRUCTA
lpAuthDlgStruct
)
DWORD
WINAPI
NPSAuthenticationDialogA
(
LPAUTHDLGSTRUCTA
lpAuthDlgStruct
)
{
{
FIXME
(
"(%p): stub
\n
"
,
lpAuthDlgStruct
);
HMODULE
hwininet
=
GetModuleHandleA
(
"mpr.dll"
);
return
WN_NOT_SUPPORTED
;
TRACE
(
"%p
\n
"
,
lpAuthDlgStruct
);
if
(
!
lpAuthDlgStruct
)
return
WN_BAD_POINTER
;
if
(
lpAuthDlgStruct
->
cbStructure
<
sizeof
*
lpAuthDlgStruct
)
return
WN_BAD_POINTER
;
TRACE
(
"%s %s %s
\n
"
,
lpAuthDlgStruct
->
lpResource
,
lpAuthDlgStruct
->
lpOUTitle
,
lpAuthDlgStruct
->
lpExplainText
);
return
DialogBoxParamW
(
hwininet
,
MAKEINTRESOURCEW
(
IDD_PROXYDLG
),
lpAuthDlgStruct
->
hwndOwner
,
NPS_ProxyPasswordDialog
,
(
LPARAM
)
lpAuthDlgStruct
);
}
}
/*****************************************************************
/*****************************************************************
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment