TBool CMulScreensTestAppUi::ProcessCommandParametersL(CApaCommandLine& aCommandLine)
	{
	TPtrC8 tailEnd = aCommandLine.TailEnd();
	if(tailEnd.Compare(KScreenDevice) == 0)
		{
		RDebug::Print(_L("**** MultipleScreensAppTest - ScreenDevice: This should panic with ECoePanicInvalidScreenNumber"));
		CCoeEnv::Static()->ScreenDevice(KInvalidScreenNumber);	
		}
	else if(tailEnd.Compare(KWindowGroup) == 0)
		{
		RDebug::Print(_L("**** MultipleScreensAppTest - WindowGroup: This should panic with ECoePanicInvalidScreenNumber"));
		CCoeEnv::Static()->RootWin(KInvalidScreenNumber);	
		}
	else
		{
		RDebug::Print(_L("MultipleScreensAppTest - Bad arguments, failing test...."));
		RProcess().Terminate(KMulScreensAppTestFailed);				
		}
	
	return ETrue;
	}	
/**
 *	Processes the command line parameters
 *	@param aCommandLine - command to be passed based on the menu item
 *						selected by the user
 *
 *	This function leaks intentionally some memory and examines the value of the trailing data 
 *	in aCommandLine (expected to be either ETrue or EFalse). According to this value CCoeEnv::DisableExitChecks()
 *	is triggered in order to disable or not the exit checks at kernel resources.
 *	
 */
TBool CExampleAppUi::ProcessCommandParametersL(CApaCommandLine& aCommandLine)
	{
	CEikAppUi* aAppUI = new(ELeave) CExampleAppUi; //intentionally caused memory leak
	TPtrC8 tailEnd = aCommandLine.TailEnd();
	if(tailEnd.Compare(KETrue) == 0)
		{
		RDebug::Print(_L("Disable shutdown checks"));
		iEikonEnv->DisableExitChecks(ETrue);
		}
	else if(tailEnd.Compare(KEFalse) == 0)
		{
		RDebug::Print(_L("Enable shutdown checks"));
		iEikonEnv->DisableExitChecks(EFalse);
		}
	else
		{
		RDebug::Print(_L("Bad arguments, failing test...."));
		RProcess().Terminate(KTestFailed);				
		}
	Exit();
	return ETrue;
	}