• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            S.l.e!ep.¢%

            像打了激速一樣,以四倍的速度運轉,開心的工作
            簡單、開放、平等的公司文化;尊重個性、自由與個人價值;
            posts - 1098, comments - 335, trackbacks - 0, articles - 1
              C++博客 :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理

            MSDN 中的 MessageLoop

            Posted on 2009-05-01 22:00 S.l.e!ep.¢% 閱讀(322) 評論(0)  編輯 收藏 引用 所屬分類: MulThreads

            int MessageLoop (
            HANDLE* lphObjects, // handles that need to be waited on
            int cObjects // number of handles to wait on
            )
            {
            // The message loop lasts until we get a WM_QUIT message,
            // upon which we shall return from the function.
            while (TRUE)
            {
            // block-local variable
            DWORD result ;
            MSG msg ;

            // Read all of the messages in this next loop,
            // removing each message as we read it.
            while (PeekMessage(&msg, NULL, 0, 0, PM_REMOVE))
            {
            // If it is a quit message, exit.
            if (msg.message == WM_QUIT)
            return 1;
            // Otherwise, dispatch the message.
            DispatchMessage(&msg);
            } // End of PeekMessage while loop.

            // Wait for any message sent or posted to this queue
            // or for one of the passed handles be set to signaled.
            result = MsgWaitForMultipleObjects(cObjects, lphObjects,
            FALSE, INFINITE, QS_ALLINPUT);

            // The result tells us the type of event we have.
            if (result == (WAIT_OBJECT_0 cObjects))
            {
            // New messages have arrived.
            // Continue to the top of the always while loop to
            // dispatch them and resume waiting.
            continue;
            }
            else
            {
            // One of the handles became signaled.
            DoStuff (result - WAIT_OBJECT_0) ;
            } // End of else clause.
            } // End of the always while loop.
            } // End of function.

            ?

            久久99国产精品久久99| 7777久久久国产精品消防器材| 99久久人妻无码精品系列| 久久综合九色综合网站| 成人a毛片久久免费播放| 久久精品国产一区二区三区不卡 | 少妇人妻88久久中文字幕| 日韩精品久久无码人妻中文字幕 | 亚洲成色999久久网站| 久久久久亚洲AV无码专区首JN| 97超级碰碰碰久久久久| 99精品国产免费久久久久久下载| 国产美女久久久| 久久精品国产清高在天天线| 91久久精品无码一区二区毛片| 婷婷久久久亚洲欧洲日产国码AV | 色偷偷88欧美精品久久久| 色综合久久天天综合| av色综合久久天堂av色综合在| 性做久久久久久免费观看| 久久国产精品免费一区| 久久久久女人精品毛片| 久久人人爽人人爽人人片av麻烦 | 久久无码AV一区二区三区| 99久久www免费人成精品| 久久久久久久97| 国产精品久久久久久吹潮| 久久久久久久精品成人热色戒| 亚洲精品WWW久久久久久| 很黄很污的网站久久mimi色| 久久成人永久免费播放| 国产精品无码久久四虎| A级毛片无码久久精品免费| 久久国产精品免费一区二区三区| 久久精品二区| 久久这里只精品99re66| 色综合久久中文字幕综合网| 精品国产青草久久久久福利| 久久久精品人妻一区二区三区蜜桃 | 久久久久婷婷| 香蕉久久影院|