File: DitherDialog.cpp

package info (click to toggle)
paintlib 2.6.2-14
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 7,920 kB
  • ctags: 3,874
  • sloc: cpp: 25,209; sh: 10,605; ansic: 1,891; makefile: 120
file content (62 lines) | stat: -rw-r--r-- 1,434 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
// DitherDialog.cpp: implementation of the CDitherDialog class.
//
//////////////////////////////////////////////////////////////////////

#include "stdafx.h"
#include "piclook.h"
#include "DitherDialog.h"

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

CDitherDialog::CDitherDialog(CWnd* pParent /*=NULL*/)
	: CDialog(CDitherDialog::IDD, pParent)
{

}

void CDitherDialog::DoDataExchange(CDataExchange* pDX)
{
    CDialog::DoDataExchange(pDX);
    //{{AFX_DATA_MAP(CCropFilterDlg)
	DDX_Control(pDX, IDC_DITHERTYPE, m_DitherTypeBox);
	DDX_Control(pDX, IDC_DITHERPALETTETYPE, m_DitherPaletteTypeBox);
    //}}AFX_DATA_MAP
}

//    DDX_Text(pDX, IDC_DITHERTYPE, m_iDitherType);
//    DDX_Text(pDX, IDC_DITHERPALETTETYPE, m_iDitherPaletteType);

BEGIN_MESSAGE_MAP(CDitherDialog, CDialog)
//{{AFX_MSG_MAP(CDitherDialog)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CCropFilterDlg message handlers

void CDitherDialog::OnOK()
{
	if (m_DitherPaletteTypeBox.GetCurSel() != CB_ERR)
	{
		m_iDitherPaletteType = m_DitherPaletteTypeBox.GetCurSel();
	}
	else
	{
		m_iDitherPaletteType = 0;
	}

	
	if (m_DitherTypeBox.GetCurSel() != CB_ERR)
	{
		m_iDitherType = m_DitherTypeBox.GetCurSel();
	}
	else
	{
		m_iDitherType = 0;
	}

    CDialog::OnOK();
}