1.1 --- a/epoc32/include/coemain.inl Tue Mar 16 16:12:26 2010 +0000
1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
1.3 @@ -1,186 +0,0 @@
1.4 -// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
1.5 -// All rights reserved.
1.6 -// This component and the accompanying materials are made available
1.7 -// under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
1.8 -// which accompanies this distribution, and is available
1.9 -// at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
1.10 -//
1.11 -// Initial Contributors:
1.12 -// Nokia Corporation - initial contribution.
1.13 -//
1.14 -// Contributors:
1.15 -//
1.16 -// Description:
1.17 -//
1.18 -
1.19 -
1.20 -
1.21 -/**
1.22 - Gets the most recent standard event that was received by the application.
1.23 -
1.24 - Note: standard events are all events except redraw events and priority key events.
1.25 -
1.26 - @return The last event.
1.27 -*/
1.28 -inline const TWsEvent& CCoeEnv::LastEvent() const
1.29 - { return(iLastEvent); }
1.30 -
1.31 -/** Gets the application UI owned by this application.
1.32 -
1.33 -@return Pointer to the app UI owned by the application. */
1.34 -inline CCoeAppUi* CCoeEnv::AppUi() const
1.35 - { return(iAppUi); }
1.36 -
1.37 -/** Gets the file server session owned by this CCoeEnv.
1.38 -
1.39 -This session is normally only used for accessing the application's resource
1.40 -file.
1.41 -
1.42 -@return The file server session owned by this CCoeEnv. */
1.43 -inline RFs& CCoeEnv::FsSession() const
1.44 - { return((RFs&)iFsSession); }
1.45 -
1.46 -/** Gets the window server session owned by the application.
1.47 -
1.48 -This provides access to window server functions not directly accessible via
1.49 -the UI control framework.
1.50 -
1.51 -@return The window server session opened by the application. */
1.52 -inline RWsSession& CCoeEnv::WsSession() const
1.53 - { return((RWsSession&)iWsSession); }
1.54 -
1.55 -/** Gets the application's window group.
1.56 -
1.57 -Note: a window group is an invisible window which acts as the parent window for
1.58 -all other windows in an application. Typically, each application has one window
1.59 -group. In the window server, window groups are also the unit of keyboard focus.
1.60 -
1.61 -@return The application's window group. */inline RWindowGroup& CCoeEnv::RootWin() const
1.62 - { return((RWindowGroup&)iRootWin); }
1.63 -
1.64 -/** Gets the system graphics context.
1.65 -
1.66 -This is the graphics context typically used for drawing controls, but an
1.67 -alternative graphics context can be created if required using CreateGcL().
1.68 -
1.69 -@return The system graphics context. */
1.70 -inline CWindowGc& CCoeEnv::SystemGc() const
1.71 - { return((CWindowGc&)*iSystemGc); }
1.72 -
1.73 -/** Gets the normal environment font.
1.74 -
1.75 -This is the font created during construction of the control environment.
1.76 -
1.77 -@return Pointer to the normal environment font.
1.78 -@see InitSystemFontsL() */
1.79 -inline const CFont* CCoeEnv::NormalFont() const
1.80 - { return(iNormalFont); }
1.81 -
1.82 -/** Gets the default screen device owned by this CCoeEnv.
1.83 -
1.84 -This is typically used as the standard screen device for the CCoeEnv's application.
1.85 -
1.86 -@return The default screen device owned by this CCoeEnv. */
1.87 -inline CWsScreenDevice* CCoeEnv::ScreenDevice() const
1.88 - { return(iScreen); }
1.89 -
1.90 -/** Gets the current error message text.
1.91 -
1.92 -@return The current error message text. */
1.93 -inline TDes& CCoeEnv::ErrorText()
1.94 - { return *iErrorText; }
1.95 -
1.96 -/** Gets the current error context text.
1.97 -
1.98 -@return The current error context text. */
1.99 -inline TDes& CCoeEnv::ErrorContextText()
1.100 - { return *iErrorContextText; }
1.101 -
1.102 -#if defined(_UNICODE)
1.103 -/** Reads a resource into a descriptor.
1.104 -
1.105 -The descriptor must be long enough to contain the entire resource. No memory
1.106 -is allocated by this function. If the read fails, the function sets an error
1.107 -condition and performs any cleanup required. The error condition causes the
1.108 -GUI to launch an alert window.
1.109 -
1.110 -Deprecated - Use CCoeEnv::ReadResourceL() instead.
1.111 -
1.112 -@deprecated
1.113 -@param aDes On return, contains the resource data.
1.114 -@param aResourceId The numeric ID of the resource to be read.
1.115 -@see RResourceFile::ReadL()
1.116 -@see KErrCoeFailedToReadFromProgDisk */
1.117 -inline void CCoeEnv::ReadResource(TDes& aDes,TInt aResourceId) const
1.118 - { ReadResourceAsDes16(aDes,aResourceId); }
1.119 -
1.120 -/** Reads a resource into a descriptor.
1.121 -
1.122 -The descriptor must be long enough to contain the entire resource.
1.123 -No memory is allocated by this function.
1.124 -
1.125 -@param aDes On return, contains the resource data.
1.126 -@param aResourceId The numeric ID of the resource to be read.
1.127 -@return Pointer to a heap descriptor containing the resource. */
1.128 -inline void CCoeEnv::ReadResourceL(TDes& aDes,TInt aResourceId) const
1.129 - { ReadResourceAsDes16L(aDes,aResourceId); }
1.130 -
1.131 -/** Reads a resource into a heap descriptor, allocating memory for it.
1.132 -
1.133 -Note: the calling program must destroy the heap descriptor when it is no longer
1.134 -needed.
1.135 -
1.136 -@param aResourceId The numeric ID of the resource to be read.
1.137 -@return Pointer to a heap descriptor containing the resource data.
1.138 -@see RResourceFile::AllocReadL() */
1.139 -inline HBufC* CCoeEnv::AllocReadResourceL(TInt aResourceId) const
1.140 - { return AllocReadResourceAsDes16L(aResourceId); }
1.141 -
1.142 -/** Reads a specified resource into a heap descriptor, allocating memory for it,
1.143 -and pushing the descriptor onto the cleanup stack.
1.144 -
1.145 -The calling program should pop and destroy the heap descriptor when it is
1.146 -no longer needed.
1.147 -
1.148 -@param aResourceId The numeric ID of the resource to be read.
1.149 -@return Pointer to a heap descriptor containing the resource data.
1.150 -@see RResourceFile::AllocReadLC() */
1.151 -inline HBufC* CCoeEnv::AllocReadResourceLC(TInt aResourceId) const
1.152 - { return AllocReadResourceAsDes16LC(aResourceId); }
1.153 -
1.154 -/** Reads a resource into a Unicode descriptor array.
1.155 -
1.156 -@param aResourceId The numeric ID of the resource to be read.
1.157 -@return A pointer to the descriptor array containing the resource data.
1.158 -@see TResourceReader::ReadDesCArrayL() */
1.159 -inline CDesCArrayFlat* CCoeEnv::ReadDesCArrayResourceL(TInt aResourceId)
1.160 - { return ReadDesC16ArrayResourceL(aResourceId); }
1.161 -#else // not UNICODE
1.162 -
1.163 -/** Deprecated - use CCoeEnv::ReadResourceL() instead.
1.164 -
1.165 -@deprecated */
1.166 -inline void CCoeEnv::ReadResource(TDes& aDes,TInt aResourceId) const
1.167 - { ReadResourceAsDes8(aDes,aResourceId); }
1.168 -
1.169 -inline void CCoeEnv::ReadResourceL(TDes& aDes,TInt aResourceId) const
1.170 - { ReadResourceAsDes8L(aDes,aResourceId); }
1.171 -inline HBufC* CCoeEnv::AllocReadResourceL(TInt aResourceId) const
1.172 - { return AllocReadResourceAsDes8L(aResourceId); }
1.173 -inline HBufC* CCoeEnv::AllocReadResourceLC(TInt aResourceId) const
1.174 - { return AllocReadResourceAsDes8LC(aResourceId); }
1.175 -inline CDesCArrayFlat* CCoeEnv::ReadDesCArrayResourceL(TInt aResourceId)
1.176 - { return ReadDesC8ArrayResourceL(aResourceId); }
1.177 -#endif // UNICODE
1.178 -
1.179 -//
1.180 -// Tests if the Active Scheduler is started in the CCoeEnv::ExecuteD
1.181 -//
1.182 -// @return "TBool"
1.183 -// <code>ETrue</code> if Active Scheduler is started in
1.184 -// CCoeEnv::ExecuteD()
1.185 -// <code>EFalse</code> if Active Scheduler is not started in
1.186 -// CCoeEnv::ExecuteD()
1.187 -//
1.188 -inline TBool CCoeEnv::IsSchedulerRunning() const
1.189 - {return iEnvFlags&ESchedulerIsRunning;}