• <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.

            ?

            无码任你躁久久久久久老妇| 久久被窝电影亚洲爽爽爽| 国产精品美女久久久久av爽| 久久无码人妻一区二区三区 | 国产精品久久婷婷六月丁香| 国产精品无码久久久久| 大香网伊人久久综合网2020| 情人伊人久久综合亚洲| 97久久久久人妻精品专区| 国产精品久久久亚洲| 久久久久一区二区三区| 国产亚州精品女人久久久久久 | 国产精品久久久久无码av| 国产精品久久久久9999| 久久精品一区二区| 精品久久久无码中文字幕天天| 国产成人无码精品久久久久免费 | 精品久久久久久久无码| 99久久777色| 91精品无码久久久久久五月天| 日韩精品国产自在久久现线拍| 国产免费久久精品99久久| 久久涩综合| 久久精品日日躁夜夜躁欧美| 亚洲狠狠婷婷综合久久蜜芽| 久久综合狠狠综合久久| 久久精品无码一区二区三区| 精品国产婷婷久久久| 激情综合色综合久久综合| 久久99精品免费一区二区| 欧美日韩精品久久久免费观看| 国产麻豆精品久久一二三| 久久精品水蜜桃av综合天堂| 久久久久久久99精品免费观看| 精品99久久aaa一级毛片| 亚洲国产成人精品无码久久久久久综合 | 久久精品国产秦先生| 久久九色综合九色99伊人| 久久无码AV中文出轨人妻| 久久无码人妻一区二区三区| 久久99精品久久久久久秒播|