资源简介

一个MFC应用程序实例:一个漂亮的登录界面。用VC开发出来的界面很不好看。现在实现了窗口重画功能

资源截图

代码片段和文件信息

// OwnerEdit.cpp : implementation file
// download by http://www.codefans.net

#include “stdafx.h“
#include “OwnerEdit.h“

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// COwnerEdit

COwnerEdit::COwnerEdit()
{
m_BoundryBrush.CreateSolidBrush(RGB(187200143));
}

COwnerEdit::~COwnerEdit()
{
m_BoundryBrush.Deleteobject();
}


BEGIN_MESSAGE_MAP(COwnerEdit CEdit)
//{{AFX_MSG_MAP(COwnerEdit)
ON_WM_NCPAINT()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// COwnerEdit message handlers

void COwnerEdit::OnHoverEnter()
{
Redraw();
}

void COwnerEdit::OnHoverLeave()
{
Redraw();
}

void COwnerEdit::OnNcPaint() 
{
// TODO: Add your message handler code here
CWindowDC DC(this);
CRect Rect;
GetWindowRect(&Rect);

if (IsHover())
{
DC.Selectobject(&m_BoundryBrush);
DC.Rectangle(00Rect.Width()Rect.Height());
}
else
{
DC.DrawEdge(CRect(00Rect.Width()Rect.Height())EDGE_SUNKENBF_FLAT|BF_RECT);
}

// Do not call CEdit::OnNcPaint() for painting messages
}

void COwnerEdit::Redraw()
{
RedrawWindow(NULLNULLRDW_frame|RDW_INVALIDATE);
}












































 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件       1421  2010-04-23 09:13  C++登录界面\MyBusinessDlg\MyBusinessDlg\OwnerEdit.cpp

     文件       1270  2006-03-06 15:59  C++登录界面\MyBusinessDlg\MyBusinessDlg\OwnerEdit.h

     文件       3705  2006-02-20 10:44  C++登录界面\MyBusinessDlg\MyBusinessDlg\ReadMe.txt

     文件       1235  2006-04-09 13:45  C++登录界面\MyBusinessDlg\MyBusinessDlg\resource.h

     文件        215  2006-02-20 10:44  C++登录界面\MyBusinessDlg\MyBusinessDlg\StdAfx.cpp

     文件       1054  2006-02-20 10:44  C++登录界面\MyBusinessDlg\MyBusinessDlg\StdAfx.h

     文件      46480  2010-05-04 12:34  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.aps

     文件       1280  2010-05-04 12:37  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.clw

     文件       2197  2010-04-01 17:58  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.cpp

     文件       5292  2010-05-04 10:16  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.dsp

     文件        551  2006-02-20 10:44  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.dsw

     文件       1401  2006-02-20 10:44  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.h

     文件      82944  2010-05-04 12:37  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.ncb

     文件      50688  2010-05-04 12:37  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.opt

     文件       1249  2010-05-04 09:40  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.plg

     文件       5608  2010-05-04 12:34  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColor.rc

     文件      13545  2010-05-04 00:15  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColorDlg.cpp

     文件       2134  2006-04-11 13:20  C++登录界面\MyBusinessDlg\MyBusinessDlg\titleBarColorDlg.h

     文件        505  2010-04-01 17:59  C++登录界面\MyBusinessDlg\MyBusinessDlg\TrackControl.cpp

     文件       1568  2006-03-06 15:47  C++登录界面\MyBusinessDlg\MyBusinessDlg\TrackControl.h

     文件       7243  2010-04-01 17:59  C++登录界面\MyBusinessDlg\MyBusinessDlg\XPButton.cpp

     文件       2262  2006-03-03 15:04  C++登录界面\MyBusinessDlg\MyBusinessDlg\XPButton.h

     文件     172544  2010-04-11 23:31  C++登录界面\MyBusinessDlg\MyBusinessDlg\代码.doc

     文件       1684  2010-02-04 22:45  C++登录界面\MyBusinessDlg\MyBusinessDlg\建站源码网.txt

     文件        178  2008-09-27 22:33  C++登录界面\MyBusinessDlg\MyBusinessDlg\建站源码网.url

     文件       2607  2009-09-01 16:48  C++登录界面\MyBusinessDlg\MyBusinessDlg\说明.htm

     文件        776  2006-03-03 14:12  C++登录界面\MyBusinessDlg\MyBusinessDlg\res\exit_foc.bmp

     文件        776  2006-03-03 14:12  C++登录界面\MyBusinessDlg\MyBusinessDlg\res\exit_nor.bmp

     文件        776  2006-03-03 14:11  C++登录界面\MyBusinessDlg\MyBusinessDlg\res\hel_focu.bmp

     文件        776  2006-03-03 14:11  C++登录界面\MyBusinessDlg\MyBusinessDlg\res\hel_norm.bmp

............此处省略30个文件信息

评论

共有 条评论