正在进行中的功能---动态消息对话框(.h)

[入库:2005年8月18日] [更新:2007年3月24日]

本文简介:选择自 bigfanofcpp 的 blog

#if !defined(afx_informationtip_h__45e0dbbe_cb8f_43e6_8557_3214917f1036__included_)
#define afx_informationtip_h__45e0dbbe_cb8f_43e6_8557_3214917f1036__included_

#if _msc_ver > 1000
#pragma once
#endif // _msc_ver > 1000
// informationtip.h : header file
//
/////////////////////////////////////////////////////////////////////////////
// cinformationtip dialog
struct screenpos
{
 long m_screenx;
 long m_screeny;
 screenpos(long x = 0,long y = 0):m_screenx(x),m_screeny(y)
 {}
};

#define near_side 12

enum tipshowpos{e=1,w=9,n=8,s=2};

class cinformationtip : public cdialog
{
// construction
public:
 cinformationtip(cwnd* pparent = null);   // standard constructor
 void setshowtipatwhere(tipshowpos);
 void setshowtiptime(dword);
 void setkeepmovestep(dword);
 void setdlgbkcolor(colorref);
 void setdlglayoutcolor(int);
// dialog data
 //{{afx_data(cinformationtip)
 enum { idd = idd_informationtip_dialog };
 ccjflatbutton m_buttonctrl_tipinfo;
 //}}afx_data


// overrides
 // classwizard generated virtual function overrides
 //{{afx_virtual(cinformationtip)
 public:
 virtual bool pretranslatemessage(msg* pmsg);
 protected:
 virtual void dodataexchange(cdataexchange* pdx);    // ddx/ddv support
 //}}afx_virtual

// implementation
protected:

 // generated message map functions
 //{{afx_msg(cinformationtip)
 virtual bool oninitdialog();
 afx_msg void onsize(uint ntype, int cx, int cy);
 afx_msg void ontimer(uint nidevent);
 afx_msg void onkillfocus(cwnd* pnewwnd);
 afx_msg void onmousemove(uint nflags, cpoint point);
 afx_msg void onmove(int x, int y);
 afx_msg hbrush onctlcolor(cdc* pdc, cwnd* pwnd, uint nctlcolor);
 afx_msg void ondestroy();
 //}}afx_msg
 afx_msg void onok();
 afx_msg void cancel();
 afx_msg void onclose();
 declare_message_map()
private:
 screenpos m_screenpos;
 dword m_dwstep;
 dword m_dwtime;
 crect m_rect;
 cbrush m_dlkbkbrush;
 bool m_isalreadyshow;
 cfont m_tipinf_font;
 int m_irate;
 void showinformations(bool);
 void keepmovemovemove(bool);
 void initmemctrl();
 typedef bool(winapi *set_fill_clr)(hwnd,colorref,byte,dword);
 set_fill_clr m_ffill;
 hinstance m_huser32dll;
 //cimagelist m_tipinfoimage;
};

//{{afx_insert_location}}
// microsoft visual c++ will insert additional declarations immediately before the previous line.

#endif // !defined(afx_informationtip_h__45e0dbbe_cb8f_43e6_8557_3214917f1036__included_)

本文关键:正在进行中的功能---动态消息对话框(.h)
  相关方案
Google
 

本站最佳浏览方式为 分辨率 1024x768 IE 6.0(或更高版本的 IE浏览器)

go top