• 大小: 205KB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2021-05-29
  • 语言: 其他
  • 标签:

资源简介

VC五子棋游戏设计,VC五子棋游戏设计VC五子棋游戏设计,VC五子棋游戏设计

资源截图

代码片段和文件信息

//   Modified by jingzhou xu Add background color support
//

#include “stdafx.h“
#include “BtnST.h“

#ifdef BTNST_USE_SOUND
#pragma comment(lib “winmm.lib“)
#include 
#endif

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

/////////////////////////////////////////////////////////////////////////////
// CButtonST

// Mask for control‘s type
#define BS_TYPEMASK SS_TYPEMASK

#ifndef TTM_SETtitle
#define TTM_SETtitleA           (WM_USER + 32)  // wParam = TTI_* lParam = char* sztitle
#define TTM_SETtitleW           (WM_USER + 33)  // wParam = TTI_* lParam = wchar* sztitle
#ifdef UNICODE
#define TTM_SETtitle            TTM_SETtitleW
#else
#define TTM_SETtitle            TTM_SETtitleA
#endif
#endif

CButtonST::CButtonST()
{
m_bIsPressed = FALSE;
m_bIsFocused = FALSE;
m_bIsDisabled = FALSE;
m_bMouseOnButton = FALSE;

FreeResources(FALSE);

// Default type is “flat“ button
m_bIsFlat = TRUE;
// Button will be tracked also if when the window is inactive (like Internet Explorer)
m_bAlwaysTrack = TRUE;
  
// By default draw border in “flat“ button 
m_bDrawBorder = TRUE; 
  
// By default icon is aligned horizontally
m_byAlign = ST_ALIGN_HORIZ; 

// By default use usual pressed style
SetPressedstyle(BTNST_PRESSED_LEFTRIGHT FALSE);
  
// By default for “flat“ button don‘t draw the focus rect
m_bDrawFlatFocus = FALSE;

// By default the button is not the default button
m_bIsDefault = FALSE;
// Invalid value since type still unknown
m_nTypestyle = BS_TYPEMASK;

// By default the button is not a checkbox
m_bIsCheckBox = FALSE;
m_nCheck = 0;

// Set default colors
SetDefaultColors(FALSE);

// No tooltip created
m_ToolTip.m_hWnd = NULL;
m_dwToolTipstyle = 0;

// Do not draw as a transparent button
m_bDrawTransparent = FALSE;
m_pbmpOldBk = NULL;

// No URL defined
SetURL(NULL);

// No cursor defined
m_hCursor = NULL;

// No associated menu
#ifndef BTNST_USE_BCMENU
m_hMenu = NULL;
#endif
m_hParentWndMenu = NULL;
m_bMenuDisplayed = FALSE;

m_bShowDisabledBitmap = TRUE;

m_ptImageOrg.x = 3;
m_ptImageOrg.y = 3;

// Initialize background color jingzhou xu
m_clrBkColor = m_crColors[BTNST_COLOR_BK_OUT];

// No defined callbacks
::ZeroMemory(&m_csCallbacks sizeof(m_csCallbacks));

#ifdef BTNST_USE_SOUND
// No defined sounds
::ZeroMemory(&m_csSounds sizeof(m_csSounds));
#endif
} // End of CButtonST

CButtonST::~CButtonST()
{
// Restore old bitmap (if any)
if (m_dcBk.m_hDC && m_pbmpOldBk)
{
m_dcBk.Selectobject(m_pbmpOldBk);
} // if

FreeResources();

// Destroy the cursor (if any)
if (m_hCursor) ::DestroyCursor(m_hCursor);

// Destroy the menu (if any)
#ifdef BTNST_USE_BCMENU
if (m_menuPopup.m_hMenu) m_menuPopup.DestroyMenu();
#else
if (m_hMenu) ::DestroyMenu(m_hMenu);
#endif
} // End of ~CButtonST

BEGIN_MESSAGE_

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

     目录          0  2004-12-04 21:58  Chat

     文件       6945  2004-06-28 15:53  Chat\Chat.vcproj

     文件        119  2004-06-02 14:36  Chat\My.h

     文件       2686  2004-06-02 09:55  Chat\ReadMe.txt

     文件        435  2004-06-02 09:55  Chat\Chat.h

     文件       1254  2004-06-02 12:40  Chat\Chat.cpp

     文件       2558  2004-06-26 14:01  Chat\ChatDlg.h

     文件      20676  2004-06-28 16:09  Chat\ChatDlg.cpp

     文件       1522  2004-06-03 15:45  Chat\stdafx.h

     文件        133  2004-06-02 09:55  Chat\stdafx.cpp

     文件      15524  2004-07-05 16:51  Chat\Chat.rc

     文件        159  2004-06-02 14:37  Chat\My.cpp

     文件       3625  2004-06-29 14:15  Chat\Resource.h

     文件        236  2004-06-02 16:20  Chat\MySocket.h

     文件        908  2004-06-02 09:55  Chat\Chat.sln

    ..A..H.     13312  2004-07-27 14:15  Chat\Chat.suo

     文件        478  2004-06-04 11:13  Chat\MySocket.cpp

     文件        424  2004-06-03 15:45  Chat\UserInfoDlg.htm

     文件        936  2004-06-05 11:12  Chat\UserInfoDlg.h

     文件       4761  2004-06-05 14:54  Chat\UserInfoDlg.cpp

     文件      59750  2004-06-04 14:18  Chat\BtnST.cpp

     文件       4934  2002-01-19 10:59  Chat\IconComboBox.cpp

     文件       1420  1998-08-27 14:41  Chat\IconComboBox.h

     文件       2744  2002-11-24 21:47  Chat\WinXPButtonST.cpp

     文件       1571  2002-12-20 15:23  Chat\WinXPButtonST.h

     文件       9972  2002-12-20 14:01  Chat\BtnST.h

     文件       2102  2004-06-02 12:58  Chat\1-1.bmp

     文件        593  2004-06-05 15:32  Chat\SendToAllDlg.h

     文件       1324  2004-06-05 15:33  Chat\SendToAllDlg.cpp

     文件        625  2004-06-07 13:13  Chat\InformDlg.h

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

评论

共有 条评论

相关资源