91av视频/亚洲h视频/操亚洲美女/外国一级黄色毛片 - 国产三级三级三级三级

  • 大小: 734KB
    文件類型: .rar
    金幣: 2
    下載: 0 次
    發(fā)布日期: 2021-05-13
  • 語言: 其他
  • 標簽: RichEditCtrl??

資源簡介

最近開發(fā)一個類似qq的項目,需要用到CRichEditCtrl,網上搜索,在CSDN搜索到該c友的原創(chuàng),學習的過程中發(fā)現一個小錯誤,修改之后,共享給大家,順道賺點積分學習用~

資源截圖

代碼片段和文件信息

//?AnimationDlg.cpp?:?implementation?file
//

#include?“stdafx.h“
#include?“ChatClient.h“
#include?“AnimationDlg.h“
#include?“ChatDlg.h“

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

const?unsigned??THUMWIDTH=25;
const?unsigned??THUMHEIGHT=25;
/////////////////////////////////////////////////////////////////////////////
//?CAnimationDlg?dialog


CAnimationDlg::CAnimationDlg(CWnd*?pParent?/*=NULL*/)
:?CDialog(CAnimationDlg::IDD?pParent)
{
Create(IDDpParent);
//{{AFX_DATA_INIT(CAnimationDlg)
//}}AFX_DATA_INIT
}


void?CAnimationDlg::DoDataExchange(CDataExchange*?pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CAnimationDlg)
DDX_Control(pDX?IDC_ANILIST?m_AniList);
//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(CAnimationDlg?CDialog)
//{{AFX_MSG_MAP(CAnimationDlg)
ON_WM_LBUTTONDOWN()
//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
//?CAnimationDlg?message?handlers

BOOL?CAnimationDlg::OnInitDialog()?
{
CDialog::OnInitDialog();
InitAniList();
return?TRUE;??//?return?TRUE?unless?you?set?the?focus?to?a?control
??????????????//?EXCEPTION:?OCX?Property?Pages?should?return?FALSE
}

HBITMAP?CAnimationDlg::LoadPicture(CString?mFile)
{
//CString?轉?WCHAR
WCHAR?*pWPath;
pWPath=(WCHAR*)mFile.AllocSysString();

//從指定路徑加載圖片加載的是純圖片,不是縮略圖
????IPicture*?pPic;
????::OleLoadPicturePath(pWPathNULLNULLNULLIID_IPicture(LPVOID*)&pPic);
if?(pPic==NULL)return?NULL;
????HBITMAP?hPic=NULL;
????pPic->get_Handle((UINT*)&hPic);

long?nWidth=THUMWIDTH;?//目標圖片的寬
long?nHeight=THUMHEIGHT;//目標圖片的高

//創(chuàng)建一個新圖片并復制源圖片指定格式,創(chuàng)建后刪除源圖片
//LR_MONOCHROME創(chuàng)建一個黑白圖片;
HBITMAP?hPicRet=(HBITMAP)::CopyImage
(hPicIMAGE_BITMAPnWidthnHeightLR_COPYDELETEORG|LR_LOADTRANSPARENT);
????return?hPicRet;
}

void?CAnimationDlg::InitAniList()
{
m_ImgLst.Create(THUMWIDTHTHUMHEIGHTILC_COLOR32105);
m_AniList.SetImageList(&m_ImgLstLVSIL_NORMAL);
m_AniList.SetIconSpacing(3535);

CString?strRoot=“gif\\*“;
CString?strFilePath;
CFileFind?cff;
if(cff.FindFile(strRoot))
{
BOOL?flag=TRUE;
while(flag)
{
flag=cff.FindNextFile();
if?(!cff.IsDirectory()&&!cff.IsDots())
{
strFilePath=cff.GetFilePath();
CString?strExtender;
int?pos=strFilePath.ReverseFind(‘.‘);
strExtender=strFilePath.Mid(pos+1);
if(strExtender.CompareNoCase(“gif“)==0)
{
HBITMAP?hbmp=LoadPicture(strFilePath);
if?(hbmp!=NULL)
{
CBitmap?bmp;bmp.Attach(hbmp);
m_ImgLst.Add(&bmpRGB(000));
CString?strName;
pos=strFilePath.ReverseFind(‘\\‘);
strName=“gif/“+strFilePath.Mid(pos+1);
m_strPath.AddTail(strName);
}
}
}
}
UINT?nImgCount=m_ImgLst.GetImageCount();
for?(UINT?i=0;i {
m_AniList.InsertItem(i““i);
}
}
}

void?CAnimationDlg::OnOK()?
{
//?TODO:?A

?屬性????????????大小?????日期????時間???名稱
-----------?---------??----------?-----??----

?????文件??????????0??2009-05-07?17:54??聊天程序\VA_C__Documents?and?Settings_Administrator_Local?Settings_Application?Data_VisualAssist_vc6_history_

?????文件???????1833??2007-07-01?08:52??聊天程序\ImageOle.tlh

?????文件?????295936??2016-03-31?15:22??聊天程序\我的聊天室.ncb

?????文件???????1649??2016-03-31?13:27??聊天程序\ChatServer\ChatServer.clw

?????文件??????22104??2016-03-31?10:47??聊天程序\ChatServer\ChatServer.aps

?????文件???????3651??2009-05-05?19:05??聊天程序\ChatServer\ReadMe.txt

?????文件???????1368??2009-05-05?19:05??聊天程序\ChatServer\ChatServer.h

?????文件???????1350??2009-05-09?13:15??聊天程序\ChatServer\Msg.h

?????文件???????5544??2009-05-06?17:47??聊天程序\ChatServer\ChatServer.rc

?????文件???????2136??2009-05-05?23:44??聊天程序\ChatServer\ChatServer.cpp

?????文件????????212??2009-05-05?19:05??聊天程序\ChatServer\StdAfx.cpp

?????文件???????1465??2009-05-09?13:14??聊天程序\ChatServer\Msg.cpp

?????文件????????917??2009-05-05?23:42??聊天程序\ChatServer\Resource.h

?????文件???????1119??2009-05-08?21:59??聊天程序\ChatServer\StdAfx.h

?????文件???????1657??2009-05-06?20:58??聊天程序\ChatServer\ChatServerDlg.h

?????文件???????1555??2009-05-09?13:06??聊天程序\ChatServer\ServerSocket.h

?????文件???????1298??2009-05-08?21:13??聊天程序\ChatServer\UserSocket.h

?????文件???????2033??2009-05-09?13:32??聊天程序\ChatServer\UserSocket.cpp

?????文件???????3544??2009-05-09?16:53??聊天程序\ChatServer\ServerSocket.cpp

?????文件???????5696??2009-05-09?13:06??聊天程序\ChatServer\ChatServerDlg.cpp

?????文件???????6349??2016-03-31?10:45??聊天程序\ChatServer\ChatServer.plg

?????文件????????402??2009-05-05?19:05??聊天程序\ChatServer\res\ChatServer.rc2

?????文件???????1078??2009-05-05?19:05??聊天程序\ChatServer\res\ChatServer.ico

?????文件????????766??2009-05-05?21:28??聊天程序\ChatServer\res\icon1.ico

?????文件???????4737??2016-03-31?10:45??聊天程序\ChatServer\ChatServer.dsp

?????文件???????4264??2016-03-31?14:13??聊天程序\ChatClient\ChatClient.clw

?????文件???????3651??2009-05-05?19:05??聊天程序\ChatClient\ReadMe.txt

?????文件???????1368??2009-05-05?19:05??聊天程序\ChatClient\ChatClient.h

?????文件???????1458??2009-05-09?19:17??聊天程序\ChatClient\Msg.h

?????文件???????2227??2009-05-09?19:31??聊天程序\ChatClient\Msg.cpp

............此處省略149個文件信息

評論

共有 條評論

相關資源