Mercurial > vba-linux
view src/win32/PaletteViewControl.h @ 2:3549bbe597ed
adding makefile.am
author | Robert McIntyre <rlm@mit.edu> |
---|---|
date | Sat, 03 Mar 2012 10:31:47 -0600 |
parents | f9f4f1b99eed |
children |
line wrap: on
line source
1 #if !defined(AFX_PALETTEVIEWCONTROL_H__31F600AE_B7E5_4F6C_80B6_55E4B61FBD57__INCLUDED_)2 #define AFX_PALETTEVIEWCONTROL_H__31F600AE_B7E5_4F6C_80B6_55E4B61FBD57__INCLUDED_4 #if _MSC_VER > 10005 #pragma once6 #endif // _MSC_VER > 10007 // PaletteViewControl.h : header file8 //9 #define WM_PALINFO WM_APP+111 /////////////////////////////////////////////////////////////////////////////12 // PaletteViewControl window14 class PaletteViewControl : public CWnd15 {16 int w;17 int h;18 int colors;19 u8 *data;20 BITMAPINFO bmpInfo;21 static bool isRegistered;22 int selected;23 protected:24 u16 palette[256];25 int paletteAddress;26 // Construction27 public:28 PaletteViewControl();30 virtual void updatePalette()=0;32 // Attributes33 public:35 // Operations36 public:38 // Overrides39 // ClassWizard generated virtual function overrides40 //{{AFX_VIRTUAL(PaletteViewControl)41 //}}AFX_VIRTUAL43 // Implementation44 public:45 void registerClass();46 void refresh();47 void render(u16 color, int x, int y);48 void setSelected(int s);49 void setPaletteAddress(int address);50 bool saveJASCPAL(const char *name);51 bool saveMSPAL(const char *name);52 bool saveAdobe(const char *name);53 void init(int c, int w, int h);54 virtual ~PaletteViewControl();56 // Generated message map functions57 protected:58 //{{AFX_MSG(PaletteViewControl)59 afx_msg void OnLButtonDown(UINT nFlags, CPoint point);60 afx_msg BOOL OnEraseBkgnd(CDC* pDC);61 afx_msg void OnPaint();62 //}}AFX_MSG63 DECLARE_MESSAGE_MAP()64 };66 /////////////////////////////////////////////////////////////////////////////68 //{{AFX_INSERT_LOCATION}}69 // Microsoft Visual C++ will insert additional declarations immediately before the previous line.71 #endif // !defined(AFX_PALETTEVIEWCONTROL_H__31F600AE_B7E5_4F6C_80B6_55E4B61FBD57__INCLUDED_)