pushpin.h

来自「最经典的串口调试助手的源码(有注释)」· C头文件 代码 · 共 61 行

H
61
字号
/*
Module : PUSHPIN.H
Purpose: Interface of a push pin button 
         (as seen on X-Windows & property dialogs in VC 4)
Created: PJN / DATE/1 / 04-04-1996
History: None

Copyright (c) 1997 by PJ Naughter.  
All rights reserved.

*/

#ifndef __PUSHPIN_H__
#define __PUSHPIN_H__


////////////////////////////////// Includes ///////////////////////////////////


class CPushPinButton : public CButton
{
public:
	void ProcessClick();
//standard constructor
  CPushPinButton();

//accessors & mutators for the pinned state
  void SetPinned(BOOL bPinned);
  BOOL IsPinned() { return m_bPinned; };

//should be called in response to system color changes
  void ReloadBitmaps(); 

//Use an edged version of the bitmap
  void SetUseEdgeBitmap(BOOL bUseEdge);
  BOOL GetUseEdgeBitmap() const { return m_bUseEdge; };


protected:
  //{{AFX_MSG(CPushPinButton)
  //}}AFX_MSG

  //{{AFX_VIRTUAL(CPushPinButton)
	public:
  virtual void DrawItem(LPDRAWITEMSTRUCT lpDrawItemStruct);
	protected:
	virtual void PreSubclassWindow();
	//}}AFX_VIRTUAL

  void SizeToContent();
  void LoadBitmaps();

  DECLARE_MESSAGE_MAP()
  BOOL    m_bPinned;
  BOOL    m_bUseEdge;
  CBitmap m_PinnedBitmap;
  CBitmap m_UnPinnedBitmap;
  CRect   m_MaxRect;
};

#endif //__PUSHPIN_H__

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?