⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 appstatenewhighscore.h

📁 RGA: Biowaste Game Example This C++ application demonstrates how to create a 2D mobile game for S60
💻 H
字号:
/*
* ==============================================================================
*  Name        : AppStateNewHighScore.h
*  Part of     : RGA Game Example
*  Interface   :
*  Description : application new high score state, name entry
*  Version     : 1.0
*
*  Copyright (c) 2007-2008 Nokia Corporation.
*  This material, including documentation and any related
*  computer programs, is protected by copyright controlled by
*  Nokia Corporation.
* ==============================================================================
*/

#ifndef __APPSTATENEWHIGHSCORE_H__
#define __APPSTATENEWHIGHSCORE_H__

#include "AppState.h"
#include "HighScores.h"
#include "SymbolMatrixDrawer.h"

#include <textinput.h>          //ngi


class CAppStateNewHighScore :	public CAppState,
								public ITextInputObserver,
								public IPredictiveObserver
	{
	public:
		CAppStateNewHighScore(CExampleApplication& aApp);
		virtual ~CAppStateNewHighScore();

		/**
		 * Init
		 * Initialise the state
		 * @return KErrNone if successfull
		 */
		virtual TInt Init();
		
		/**
		 * Update
		 * Update application state
		 * @param aFrametime seconds elapsed since last frame
		 * @return state change value
		 */
		virtual EAppUpdateState Update(const TReal64& aFrametime);
		
		/**
		 * Draw
		 * Draw state graphics to given graphics context
		 * @param aContext graphics context to draw to.
		 */
		virtual void Draw(IGraphicsContext& aContext);
		
		/**
		 * KeyDown
		 * This handler is called by the main application object
		 * when any key is pressed
		 * @param aKeyCode RGA input key code of the pressed key
		 */
		virtual void KeyDown(TUint32 aKeyCode);
		
	private:	// from ITextInputObserver
        virtual void TextChanged( uint32 aCursorPosition,
                                  ReturnCode aError ) NO_THROW;
        virtual void CursorPositionChanged( uint32 aCursorPosition ) NO_THROW;
        virtual void TextInputFinished() NO_THROW;
        virtual void SymbolMatrixOpened() NO_THROW;
        virtual void SymbolMatrixEntrySelected( uint32 aEntryIndex,
                                                uint32 aRow,
                                                uint32 aColumn,
                                                const char16* aEntry ) NO_THROW;
        virtual void SymbolMatrixClosed() NO_THROW;
        virtual void TextInputModeChanged( TextInputMode aMode ) NO_THROW;
        virtual void TextInputCaseChanged( TextInputCase aCase ) NO_THROW;
	

	private:	// from IPredictiveObserver
        virtual void UnknownWordTypedIn() NO_THROW;
        virtual void SpellKeyStatus( KeyStatus aStatus ) NO_THROW;
        virtual void PreviousKeyStatus( KeyStatus aStatus ) NO_THROW;
        virtual void SpellCalled() NO_THROW;
        virtual void SpellClosed() NO_THROW;
        virtual void WordUnderlined( WordUnderlineStatus aStatus,
                                     uint32 aStartPosition,
                                     uint32 aEndPosition ) NO_THROW;
        
        
	private:
		EAppUpdateState			iNextState;
		
		THighScoreItem			iHighScoreItem;

	    // Pointer to the text input interface
	    ITextInput*				iTextInput;
		
	    // Pointer to the Text input control interface.
	    ITextInputControl*		iInputControl;

	    // Pointer to the predictive text input interface.
	    IPredictive*			iPredictive;
	    
        // Pointer to the Symbol matrix configuration.
	    ISymbolMatrix*			iSymbolMatrix;

	    
	    TextInputMode			iTextInputMode;
	    TextInputCase			iTextInputCase;
	    
	    CSymbolMatrixDrawer*	iSymbolMatrixDrawer;
	    
	};


#endif /* __APPSTATENEWHIGHSCORE_H__*/

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -