plugins/consoles/win32cons/src/console.cpp
changeset 30 35cb3fe43f60
parent 0 7f656887cf89
child 83 2a78c4ff2eab
--- a/plugins/consoles/win32cons/src/console.cpp	Wed Aug 11 12:57:25 2010 +0100
+++ b/plugins/consoles/win32cons/src/console.cpp	Thu Aug 12 16:38:42 2010 +0100
@@ -81,9 +81,10 @@
 	iWin32.Write(aDes.Ptr(), aDes.Length());
 	}
 	
-void CWin32Console::WriteStdErr(const TDesC& aDes)
+TInt CWin32Console::WriteStdErr(const TDesC& aDes)
 	{
 	iWin32.WriteStdErr(aDes.Ptr(), aDes.Length());
+	return KErrNone;
 	}
 
 TPoint CWin32Console::CursorPos() const
@@ -159,13 +160,7 @@
 
 TInt CWin32Console::Extension_(TUint aExtensionId, TAny*& a0, TAny* a1)
 	{
-	if (aExtensionId == ConsoleStdErr::KWriteStdErrConsoleExtension)
-		{
-		TDesC* des = (TDesC*)a1;
-		WriteStdErr(*des);
-		return KErrNone;
-		}
-	else if (aExtensionId == ConsoleAttributes::KSetConsoleAttributesExtension)
+	if (aExtensionId == ConsoleAttributes::KSetConsoleAttributesExtension)
 		{
 		ConsoleAttributes::TAttributes* attributes = (ConsoleAttributes::TAttributes*)a1;
 		int res = iWin32.SetAttributes(attributes->iAttributes, (TWin32Console::TColor)attributes->iForegroundColor, (TWin32Console::TColor)attributes->iBackgroundColor);
@@ -173,7 +168,12 @@
 		}
 	else
 		{
-		return CConsoleBase::Extension_(aExtensionId, a0, a1);
+		TInt ret = MIosrvConsoleHelper_Extension(aExtensionId, a0, a1);
+		if (ret == KErrExtensionNotSupported)
+			{
+			ret = CConsoleBase::Extension_(aExtensionId, a0, a1);
+			}
+		return ret;
 		}
 	
 	}