| 2441 | //----------------------------------------------------------------------------- |
| 2442 | |
| 2443 | void GuiControl::getCursor(GuiCursor *&cursor, bool &showCursor, const GuiEvent &lastGuiEvent) |
| 2444 | { |
| 2445 | #ifdef _XBOX |
| 2446 | return; |
| 2447 | #endif |
| 2448 | |
| 2449 | TORQUE_UNUSED(lastGuiEvent); |
| 2450 | |
| 2451 | if( !getRoot() ) |
| 2452 | return; |
| 2453 | |
| 2454 | if(getRoot()->mCursorChanged != -1 && !isMouseLocked()) |
| 2455 | { |
| 2456 | // We've already changed the cursor, |
| 2457 | // so set it back before we change it again. |
| 2458 | |
| 2459 | PlatformWindow *pWindow = static_cast<GuiCanvas*>(getRoot())->getPlatformWindow(); |
| 2460 | if (!pWindow) |
| 2461 | return; |
| 2462 | PlatformCursorController *pController = pWindow->getCursorController(); |
| 2463 | AssertFatal(pController != NULL,"PlatformWindow without an owned CursorController!"); |
| 2464 | |
| 2465 | pController->popCursor(); |
| 2466 | |
| 2467 | // We haven't changed it |
| 2468 | getRoot()->mCursorChanged = -1; |
| 2469 | } |
| 2470 | } |
| 2471 | |
| 2472 | //----------------------------------------------------------------------------- |
| 2473 |
no test coverage detected