home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Large Pack of OldSkool DOS MOD Trackers
/
beaversweeper_v101.zip
/
src
/
ArpEditor.cpp
< prev
next >
Wrap
C/C++ Source or Header
|
2003-01-06
|
2KB
|
101 lines
// ArpEditor.cpp : implementation file
//
#include "stdafx.h"
#include "tracker.h"
#include "isInstrument.h"
#include "ArpEditor.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CArpEditor dialog
CArpEditor::CArpEditor(CWnd* pParent /*=NULL*/)
: CDialog(CArpEditor::IDD, pParent)
{
//{{AFX_DATA_INIT(CArpEditor)
m_ticksperrow = 0;
//}}AFX_DATA_INIT
m_aewindow = 0;
}
void CArpEditor::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CArpEditor)
DDX_Control(pDX, IDC_EDIT1, m_edit_ctrl);
DDX_Control(pDX, IDC_SPIN1, m_buddy);
DDX_Text(pDX, IDC_EDIT1, m_ticksperrow);
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CArpEditor, CDialog)
//{{AFX_MSG_MAP(CArpEditor)
ON_EN_CHANGE(IDC_EDIT1, OnChangeEdit1)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CArpEditor message handlers
BOOL CArpEditor::OnInitDialog()
{
CDialog::OnInitDialog();
// TODO: Add extra initiablization here
m_aewindow = new CAEWindow();
RECT r;
GetClientRect( &r );
r.top += 64; // G÷r utrymmer f÷r knappf
m_aewindow->m_instrument = m_instrument;
m_aewindow->Create( NULL, _T("AEWIND"), WS_VISIBLE | WS_TABSTOP, r, this, 0, 0 );
m_buddy.SetRange( 1, 255 );
m_buddy.SetBuddy( GetDlgItem( IDC_EDIT1 ) );
m_ticksperrow = m_instrument->arpeggiator.ticksPerRow;
UpdateData(FALSE);
GotoDlgCtrl( m_aewindow );
return FALSE; // return TRUE unless you set the focus to a control
// EXCEPTION: OCX Property Pages should return FALSE
}
BOOL CArpEditor::DestroyWindow()
{
// TODO: Add your specialized code here and/or call the base class
if (m_aewindow) {
delete m_aewindow;
m_aewindow = 0;
}
return CDialog::DestroyWindow();
}
void CArpEditor::OnChangeEdit1()
{
// TODO: If this is a RICHEDIT control, the control will not
// send this notification unless you override the CDialog::OnInitDialog()
// function and call CRichEditCtrl().SetEventMask()
// with the ENM_CHANGE flag ORed into the mask.
UpdateData(TRUE);
m_instrument->arpeggiator.ticksPerRow = m_ticksperrow;
// TODO: Add your control notification handler code here
}