/***************************************************************************
**
**    $Header:   D:/ECB2S/SRC/LOG/BLIBOPTI.CPP   1.2.1.5   17 Apr 1997 15:41:54   ZJRD  $
**
**    $Log:   D:/ECB2S/SRC/LOG/BLIBOPTI.CPP  $
** 
**    Rev 1.2.1.5   17 Apr 1997 15:41:54   ZJRD
** No change.
** 
**    Rev 1.2.1.4   16 Apr 1997 10:15:56   ZJRD
** No change.
** 
**    Rev 1.2.1.3   10 Apr 1997 15:27:52   ZJRD
** 2.09F
** 
**    Rev 1.2.1.1   03 Apr 1997 15:09:34   ZJRD
** No change.
** 
**    Rev 1.2.1.0   28 Mar 1997 10:14:32   ZJRD
** easy pack sld 2.09d
** 
**    Rev 1.1   19 Mar 1997 11:25:50   ZJRD
** No change.
** 
**    Rev 1.0   12 Mar 1997 14:44:38   ZJRD
** Initial revision.
** 
**    Rev 1.3.1.0.1.2   09 Dec 1996 10:14:08   ZJRD
** EasyPack/SLD Version 2.0P
** 
**    Rev 1.3.1.0.1.0   11 Nov 1996 12:57:24   ZJRD
** EasyPack/SLD Version 2.01
** 
**    Rev 1.3.1.4   09 Sep 1996 13:13:20   ZJRD
** No change.
** 
**    Rev 1.3.1.3   05 Sep 1996 11:24:52   ZJRD
** No change.
** 
**    Rev 1.3.1.2   02 Sep 1996 09:52:00   ZJRD
** No change.
** 
**    Rev 1.3.1.1   28 Aug 1996 15:43:40   ZJRD
** No change.
** 
**    Rev 1.3.1.0   12 Aug 1996 10:49:06   ZJRD
** EasyPack/SLD Version 1.98
** 
**    Rev 1.0   29 May 1996 09:35:32   ZJRD
** Initial revision.
** 
****************************************************************************/

/////////////////////////////////////////////////////////////////////////////
// aloption.cpp
//
// Roger Zhang
//                                                                           
// 5/2/96
//
/////////////////////////////////////////////////////////////////////////////

#include "stdafx.h"
#include "resource.h"

#include "toolopt.h"
#include "blib.h"
#include "blibopti.h"

#ifdef _DEBUG
#undef THIS_FILE
static char BASED_CODE THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// BLIBOption dialog


BLIBOption::BLIBOption(BLIBTool * pTool)
    : CPropertyPage(BLIBOption::IDD)
{                                
    ASSERT(pTool);
    
    m_pTool = pTool;               
    
    LoadData();
    
    //{{AFX_DATA_INIT(BLIBOption)
    
    //}}AFX_DATA_INIT
}

void BLIBOption::DoDataExchange(CDataExchange* pDX)
{
    CPropertyPage::DoDataExchange(pDX);
    //{{AFX_DATA_MAP(BLIBOption)
    DDX_CBIndex(pDX, IDC_BLIBOPT_MODEL, m_nMemoryModel);
    DDX_Text(pDX, IDC_BLIBOPT_MORE, m_strMore);
    DDX_Text(pDX, IDC_BLIBOPT_PATH_EDIT, m_strPath);
    //}}AFX_DATA_MAP
}

void BLIBOption::SaveData(void)
{
//  UpdateData(TRUE);
    m_strPath.TrimLeft();
    m_strPath.TrimRight();
    m_strMore.TrimLeft();
    m_strMore.TrimRight();
    m_pTool->m_nMemoryModel = m_nMemoryModel;
    m_pTool->m_strMore      = m_strMore;
    m_pTool->m_strPath      = m_strPath;
}

void BLIBOption::LoadData(void)
{
    m_nMemoryModel = m_pTool->m_nMemoryModel; 
    m_strMore      = m_pTool->m_strMore;
    m_strPath      = m_pTool->m_strPath;
 
}

BEGIN_MESSAGE_MAP(BLIBOption, CPropertyPage)
    //{{AFX_MSG_MAP(BLIBOption)
        // NOTE: the ClassWizard will add message map macros here
    //}}AFX_MSG_MAP
END_MESSAGE_MAP()


/////////////////////////////////////////////////////////////////////////////
// ALIBOption message handlers
