sl@0: /* sl@0: * Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: * All rights reserved. sl@0: * This component and the accompanying materials are made available sl@0: * under the terms of the License "Eclipse Public License v1.0" sl@0: * which accompanies this distribution, and is available sl@0: * at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: * sl@0: * Initial Contributors: sl@0: * Nokia Corporation - initial contribution. sl@0: * sl@0: * Contributors: sl@0: * sl@0: * Description: sl@0: * sl@0: */ sl@0: sl@0: sl@0: #ifndef __T_DUMMYCONSOLE_H__ sl@0: #define __T_DUMMYCONSOLE_H__ sl@0: sl@0: #include sl@0: #include sl@0: sl@0: /** sl@0: * A console that discards all output. sl@0: */ sl@0: class CDummyConsole : public CConsoleBase sl@0: { sl@0: public: sl@0: CDummyConsole() {} sl@0: public: sl@0: // From CConsoleBase sl@0: virtual TInt Create(const TDesC& /*aTitle*/, TSize /*aSize*/) { return KErrNone; } sl@0: virtual void Read(TRequestStatus &aStatus) { TRequestStatus* status = &aStatus; User::RequestComplete(status, KErrNone); } sl@0: virtual void ReadCancel() {} sl@0: virtual void Write(const TDesC& /*aDes*/) {} sl@0: virtual TPoint CursorPos() const { return TPoint(); } sl@0: virtual void SetCursorPosAbs(const TPoint& /*aPoint*/) {} sl@0: virtual void SetCursorPosRel(const TPoint& /*aPoint*/) {} sl@0: virtual void SetCursorHeight(TInt /*aPercentage*/) {} sl@0: virtual void SetTitle(const TDesC& /*aTitle*/) {} sl@0: virtual void ClearScreen() {} sl@0: virtual void ClearToEndOfLine() {} sl@0: virtual TSize ScreenSize() const { return TSize(); } sl@0: virtual TKeyCode KeyCode() const { return TKeyCode(); } sl@0: virtual TUint KeyModifiers() const { return 0; } sl@0: }; sl@0: sl@0: #endif