peer_ui: Move config_xml2blob and config_blob2xml upstream
Signed-off-by: Simon Rozman <simon@rozman.si>
This commit is contained in:
@@ -63,7 +63,7 @@ namespace eap
|
||||
_In_ DWORD dwFlags,
|
||||
_In_ IXMLDOMNode *pConfigRoot,
|
||||
_Out_ BYTE **pConnectionDataOut,
|
||||
_Out_ DWORD *pdwConnectionDataOutSize) = 0;
|
||||
_Out_ DWORD *pdwConnectionDataOutSize);
|
||||
|
||||
///
|
||||
/// Converts the configuration BLOB to XML.
|
||||
@@ -83,7 +83,7 @@ namespace eap
|
||||
_In_count_(dwConnectionDataSize) const BYTE *pConnectionData,
|
||||
_In_ DWORD dwConnectionDataSize,
|
||||
_In_ IXMLDOMDocument *pDoc,
|
||||
_In_ IXMLDOMNode *pConfigRoot) = 0;
|
||||
_In_ IXMLDOMNode *pConfigRoot);
|
||||
|
||||
///
|
||||
/// Raises the EAP method's specific connection configuration user interface dialog on the client.
|
||||
|
@@ -32,6 +32,42 @@ eap::peer_ui::peer_ui(_In_ eap_type_t eap_method) : module(eap_method)
|
||||
}
|
||||
|
||||
|
||||
void eap::peer_ui::config_xml2blob(
|
||||
_In_ DWORD dwFlags,
|
||||
_In_ IXMLDOMNode *pConfigRoot,
|
||||
_Out_ BYTE **pConnectionDataOut,
|
||||
_Out_ DWORD *pdwConnectionDataOutSize)
|
||||
{
|
||||
UNREFERENCED_PARAMETER(dwFlags);
|
||||
|
||||
// Load configuration from XML.
|
||||
config_connection cfg(*this);
|
||||
cfg.load(pConfigRoot);
|
||||
|
||||
// Pack configuration.
|
||||
pack(cfg, pConnectionDataOut, pdwConnectionDataOutSize);
|
||||
}
|
||||
|
||||
|
||||
void eap::peer_ui::config_blob2xml(
|
||||
_In_ DWORD dwFlags,
|
||||
_In_count_(dwConnectionDataSize) const BYTE *pConnectionData,
|
||||
_In_ DWORD dwConnectionDataSize,
|
||||
_In_ IXMLDOMDocument *pDoc,
|
||||
_In_ IXMLDOMNode *pConfigRoot)
|
||||
{
|
||||
UNREFERENCED_PARAMETER(dwFlags);
|
||||
|
||||
// Unpack configuration.
|
||||
config_connection cfg(*this);
|
||||
if (dwConnectionDataSize)
|
||||
unpack(cfg, pConnectionData, dwConnectionDataSize);
|
||||
|
||||
// Save configuration to XML.
|
||||
cfg.save(pDoc, pConfigRoot);
|
||||
}
|
||||
|
||||
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
// eap::monitor_ui
|
||||
//////////////////////////////////////////////////////////////////////
|
||||
|
Reference in New Issue
Block a user