the game where you go into mines and start crafting! but for consoles (forked directly from smartcmd's github)
at main 68 lines 2.3 kB view raw
1#pragma once 2#include "../media/xuiscene_fullscreenprogress.h" 3#include "..\..\..\Minecraft.World\C4JThread.h" 4 5#define ERROR_FULLSCREENPROGRESS_ 6 7class CScene_FullscreenProgress : public CXuiSceneImpl 8{ 9private: 10 C4JThread* thread; 11 bool threadStarted; 12 UIFullscreenProgressCompletionData *m_CompletionData; 13 14 static const int TIMER_FULLSCREEN_PROGRESS = 0; 15 static const int TIMER_FULLSCREEN_TIPS = 1; 16 17 static const int TIMER_FULLSCREEN_PROGRESS_TIME = 500; 18 static const int TIMER_FULLSCREEN_TIPS_TIME = 7000; 19protected: 20 // Control and Element wrapper objects. 21 CXuiControl m_title, m_status, m_buttonConfirm, m_tip; 22 23 // Message map. Here we tie messages to message handlers. 24 XUI_BEGIN_MSG_MAP() 25 XUI_ON_XM_INIT( OnInit ) 26 XUI_ON_XM_DESTROY( OnDestroy ) 27 XUI_ON_XM_KEYDOWN(OnKeyDown) 28 XUI_ON_XM_NOTIFY_SELCHANGED( OnNotifySelChanged ) 29 XUI_ON_XM_NOTIFY_PRESS_EX(OnNotifyPressEx) 30 XUI_ON_XM_GET_SOURCE_TEXT(OnGetSourceDataText) 31 XUI_ON_XM_TRANSITION_START( OnTransitionStart ) 32 XUI_ON_XM_TIMER( OnTimer ) 33 XUI_END_MSG_MAP() 34 35 // Control mapping to objects 36 BEGIN_CONTROL_MAP() 37 MAP_CONTROL(IDC_Title, m_title) 38 MAP_CONTROL(IDC_Tip, m_tip) 39 MAP_CONTROL(IDC_Status, m_status) 40 MAP_CONTROL(IDC_ButtonConfirm, m_buttonConfirm) 41 END_CONTROL_MAP() 42 43 44 HRESULT OnInit( XUIMessageInit* pInitData, BOOL& bHandled ); 45 HRESULT OnDestroy(); 46 HRESULT OnKeyDown(XUIMessageInput* pInputData, BOOL& rfHandled); 47 HRESULT OnNotifySelChanged( HXUIOBJ hObjSource, XUINotifySelChanged* pNotifySelChangedData, BOOL& bHandled ); 48 HRESULT OnNotifyPressEx(HXUIOBJ hObjPressed, XUINotifyPress* pNotifyPressData,BOOL& rfHandled); 49 HRESULT OnGetSourceDataText(XUIMessageGetSourceText *pGetSourceTextData, BOOL& bHandled); 50 HRESULT OnTransitionStart( XUIMessageTransition *pTransition, BOOL& bHandled ); 51 HRESULT OnTimer( XUIMessageTimer *pTimer, BOOL& bHandled ); 52public: 53 54 // Define the class. The class name must match the ClassOverride property 55 // set for the scene in the UI Authoring tool. 56 XUI_IMPLEMENT_CLASS( CScene_FullscreenProgress, L"CScene_FullscreenProgress", XUI_CLASS_SCENE ) 57 58private: 59 bool m_threadCompleted; 60 int m_iPad; 61 void (*m_cancelFunc)(LPVOID param); 62 void (*m_completeFunc)(LPVOID param); 63 LPVOID m_cancelFuncParam; 64 LPVOID m_completeFuncParam; 65 D3DXVECTOR3 m_OriginalPosition; 66 bool m_bWasCancelled; 67 68};