OSDN Git Service

リッチエディット処理修正
authorqwerty2501 <riot313@gmail.com>
Tue, 31 Jan 2012 15:04:18 +0000 (00:04 +0900)
committerqwerty2501 <riot313@gmail.com>
Tue, 31 Jan 2012 15:04:18 +0000 (00:04 +0900)
nlite.suo
nlite/nlite_commentview.cpp
nlite/nlite_commentview.h
nlite/stdafx.h

index e8be646..79cc26e 100644 (file)
Binary files a/nlite.suo and b/nlite.suo differ
index 9c7b645..ce2f3f9 100644 (file)
@@ -96,8 +96,6 @@ namespace nlite{
        ///
        VOID CChatChildCtrlsList::ShowCntrls(){
 
-               timer_set(calc);
-               timer_set(move);
                std::deque<RECT> rcList;
                RECT headerRect;
                RECT tmpRect;
@@ -112,7 +110,7 @@ namespace nlite{
                auto chatDataEnd = m_hMaster.commentlist.end();
                INT_PTR heightSum =0;
 
-               timer_start(calc);
+
                {
                        CPaintDC commentListWindowDc(m_hMaster.m_commentListWindow);
                        for(;heightSum <listRect.bottom && chatDataBigin != chatDataEnd;++chatDataBigin){
@@ -125,28 +123,32 @@ namespace nlite{
                        
                        }
                }
-               timer_end(calc);
+
 
                auto ctrlsBegin = m_list.begin();
                auto ctrlsEnd = m_list.end();
                auto rcBigin = rcList.begin();
                auto rcEnd = rcList.end();
-               timer_start(move);
+
+               
                HDWP hdwp = ::BeginDeferWindowPos(CChatChildCtrls::GetCtrlCount() * rcList.size());
 
+
+               
                for(;rcBigin != rcEnd && chatDataBigin2 != chatDataEnd;++rcBigin,++ctrlsBegin,++chatDataBigin2){
+                       
+                       
                        if(ctrlsBegin == ctrlsEnd)ctrlsBegin = Extend();
                        ctrlsBegin->SetCtrl(*rcBigin,hdwp,*chatDataBigin2,m_hMaster.viewproperty.commentFoldingFlag);
 
                }
-
+               
                for(;ctrlsBegin != ctrlsEnd;++ctrlsBegin){
 
                        ctrlsBegin->Hide(hdwp);
                }
-
+               
                ::EndDeferWindowPos(hdwp);
-               timer_end(move);
                return;
        }
 
@@ -399,7 +401,7 @@ namespace nlite{
                if(vScrollInfo.nPos + static_cast<INT_PTR>(vScrollInfo.nPage) >= vScrollInfo.nMax - static_cast<INT_PTR>(vScrollInfo.nPage)&& TryEnterCriticalSection(&m_commentListWindow.m_sec) == TRUE){
                        m_commentListWindow.Invalidate();
 #ifdef USE_RICHEDIT
-                       chatChildCtrlsList.ShowCntrls();
+                       //chatChildCtrlsList.ShowCntrls();
 #endif
                        m_commentListWindow.Unlock();
                }
@@ -717,7 +719,7 @@ namespace nlite{
 
        VOID CCommentListWindow::OnPaint(HDC in_hdc){
 
-               
+
 
                RECT windowRect;
                RECT listRect = {0};
@@ -1115,6 +1117,10 @@ end:
 
        VOID CCommentListWindow::OnLButtonDblClk(UINT wParam, _WTYPES_NS::CPoint &point){
 
+
+#ifdef USE_RICHEDIT
+                       self.chatChildCtrlsList.ShowCntrls();
+#endif
                if(point.x > (INT_PTR)self.GetColumnHolSizeSum()) return;
                
 
index eae749d..de4f6c1 100644 (file)
@@ -76,11 +76,12 @@ namespace nlite{
                friend CCommentView;
                friend CCommentListWindow;
        private:
-               typedef CAtlList<CChatChildCtrls> InternalList;
+               typedef std::list<CChatChildCtrls> InternalList;
 
                InternalList m_list;
                CCommentView &m_hMaster;
 
+
        public:
                typedef InternalList::reference reference;
                typedef InternalList::iterator iterator;
index 961443f..ee5891c 100644 (file)
@@ -13,7 +13,7 @@
 #define  _CRT_NON_CONFORMING_SWPRINTFS 1       //vc++\82Ì\82¨\82¹\82Á\82©\82¢\82È\8cx\8d\90\82ð\8fÁ\82·
 #define USE_STUB                                                       //\83X\83^\83u\82ð\8eg\97p\82·\82é\8fê\8d\87\82Í\83R\83\81\83\93\83g\83A\83E\83g\82ð\89ð\8f\9c\82·\82é
 #define WINDEBUGER_NOPRINTING                          //\83f\83o\83b\83O\8fo\97Í\82ð\83R\83\93\83\\81[\83\8b\82É\95\\8e¦\82µ\82½\82­\82È\82¢\8fê\8d\87\92è\8b`\82·\82é
-//#define USE_RICHEDIT
+#define USE_RICHEDIT
 #define _WTL_NO_CSTRING
 
 // Windows \83w\83b\83_\81\83t\83@\83C\83\8b: