当前位置: 首页>>代码示例>>C++>>正文


C++ GHOST_SystemWin32::dispatchEvents方法代码示例

本文整理汇总了C++中GHOST_SystemWin32::dispatchEvents方法的典型用法代码示例。如果您正苦于以下问题:C++ GHOST_SystemWin32::dispatchEvents方法的具体用法?C++ GHOST_SystemWin32::dispatchEvents怎么用?C++ GHOST_SystemWin32::dispatchEvents使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在GHOST_SystemWin32的用法示例。


在下文中一共展示了GHOST_SystemWin32::dispatchEvents方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: if


//.........这里部分代码省略.........
					 * makes a request to paint a portion of an application's window. The message is sent
					 * when the UpdateWindow or RedrawWindow function is called, or by the DispatchMessage 
					 * function when the application obtains a WM_PAINT message by using the GetMessage or 
					 * PeekMessage function. 
					 */
					if (!window->m_inLiveResize) {
						event = processWindowEvent(GHOST_kEventWindowUpdate, window);
						::ValidateRect(hwnd, NULL);
					}
					else {
						eventHandled = true;
					}
					break;
				case WM_GETMINMAXINFO:
					/* The WM_GETMINMAXINFO message is sent to a window when the size or 
					 * position of the window is about to change. An application can use 
					 * this message to override the window's default maximized size and 
					 * position, or its default minimum or maximum tracking size. 
					 */
					processMinMaxInfo((MINMAXINFO *) lParam);
					/* Let DefWindowProc handle it. */
					break;
				case WM_SIZING:
				case WM_SIZE:
					/* The WM_SIZE message is sent to a window after its size has changed.
					 * The WM_SIZE and WM_MOVE messages are not sent if an application handles the 
					 * WM_WINDOWPOSCHANGED message without calling DefWindowProc. It is more efficient
					 * to perform any move or size change processing during the WM_WINDOWPOSCHANGED 
					 * message without calling DefWindowProc.
					 */
					/* we get first WM_SIZE before we fully init. So, do not dispatch before we continiously resizng */
					if (window->m_inLiveResize) {
						system->pushEvent(processWindowEvent(GHOST_kEventWindowSize, window));
						system->dispatchEvents();
					}
					else {
						event = processWindowEvent(GHOST_kEventWindowSize, window);
					}
					break;
				case WM_CAPTURECHANGED:
					window->lostMouseCapture();
					break;
				case WM_MOVING:
					/* The WM_MOVING message is sent to a window that the user is moving. By processing
					 * this message, an application can monitor the size and position of the drag rectangle
					 * and, if needed, change its size or position.
					 */
				case WM_MOVE:
					/* The WM_SIZE and WM_MOVE messages are not sent if an application handles the 
					 * WM_WINDOWPOSCHANGED message without calling DefWindowProc. It is more efficient
					 * to perform any move or size change processing during the WM_WINDOWPOSCHANGED 
					 * message without calling DefWindowProc. 
					 */
					/* see WM_SIZE comment*/
					if (window->m_inLiveResize) {
						system->pushEvent(processWindowEvent(GHOST_kEventWindowMove, window));
						system->dispatchEvents();
					}
					else {
						event = processWindowEvent(GHOST_kEventWindowMove, window);
					}

					break;
				////////////////////////////////////////////////////////////////////////
				// Window events, ignored
				////////////////////////////////////////////////////////////////////////
开发者ID:denvrnaicker,项目名称:blender-git,代码行数:67,代码来源:GHOST_SystemWin32.cpp


注:本文中的GHOST_SystemWin32::dispatchEvents方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。