Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

69 lines
1.7 KiB

  1. /**************************************************/
  2. /* */
  3. /* */
  4. /* Associations Property */
  5. /* (Dialog) */
  6. /* */
  7. /* Copyright (c) 1997-1999 Microsoft Corporation. */
  8. /**************************************************/
  9. typedef struct _tagASSOCIATIONREG{
  10. TCHAR szFaceName[LF_FACESIZE];
  11. TCHAR szFileName[MAX_PATH];
  12. TCHAR szFileTitle[MAX_PATH];
  13. BOOL FontTypeFlg; // TRUE:TRUETYPE, FALSE:WIFE FONT
  14. BOOL UpdateFlg;
  15. } ASSOCIATIONREG;
  16. typedef ASSOCIATIONREG FAR *LPASSOCIATIONREG;
  17. class CRegistListBox : public CListBox
  18. {
  19. private:
  20. int ItemHeight;
  21. public:
  22. virtual void MeasureItem(LPMEASUREITEMSTRUCT lpMIS);
  23. virtual void DrawItem(LPDRAWITEMSTRUCT lpDIS);
  24. virtual int CompareItem(LPCOMPAREITEMSTRUCT lpCIS);
  25. };
  26. class CAssocDlg : public CDialog
  27. {
  28. public:
  29. CAssocDlg(CWnd* pParent = NULL);
  30. BOOL InitSystemFontAssoc();
  31. //{{AFX_DATA(CAssocDlg)
  32. enum { IDD = IDD_ASSOCIATION };
  33. //}}AFX_DATA
  34. private:
  35. BOOL SetAssociationFontType();
  36. BOOL HandleImportWin95(LPTSTR TTFPath, LPTSTR BMPPath, int Idx);
  37. CWnd * m_pParent;
  38. protected:
  39. CRegistListBox m_RegListBox;
  40. //{{AFX_VIRTUAL(CAssocDlg)
  41. protected:
  42. virtual BOOL OnInitDialog();
  43. virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
  44. //}}AFX_VIRTUAL
  45. protected:
  46. // Generated message map functions
  47. //{{AFX_MSG(CAssocDlg)
  48. afx_msg void OnDblclkRegistlist();
  49. virtual void OnOK();
  50. virtual void OnCancel();
  51. afx_msg void OnModify();
  52. afx_msg void OnRemove();
  53. afx_msg void OnRadioDbcs();
  54. afx_msg void OnRadioSystem();
  55. //}}AFX_MSG
  56. DECLARE_MESSAGE_MAP()
  57. };