diff -r c84cf270c54f -r 8871b09be73b phoneuis/BubbleManager/Src/BMTouchPaneButton.cpp --- a/phoneuis/BubbleManager/Src/BMTouchPaneButton.cpp Tue Feb 02 00:10:04 2010 +0200 +++ b/phoneuis/BubbleManager/Src/BMTouchPaneButton.cpp Fri Feb 19 22:50:26 2010 +0200 @@ -16,16 +16,17 @@ */ #include -#include +#include #include #include #include #include -#include +#include +#include -#include "bmtouchpanebutton.h" +#include "BMTouchPaneButton.h" #include "BMTouchPaneInterface.h" -#include "bmpanic.h" +#include "BMPanic.h" const TInt KBubbleButtonText = 255; @@ -97,9 +98,7 @@ CAknButton::ConstructFromResourceL( aReader ); - // function button text color - SetTextColorIds( KAknsIIDQsnTextColors, - EAknsCIQsnTextColorsCG65 ); + SelectTextColor(); // Customize icons if ( iIconProvider ) @@ -410,3 +409,25 @@ return KAknsIIDQsnFrButtonInactive; } } + +// ----------------------------------------------------------------------------- +// Selects the correct text color. +// ----------------------------------------------------------------------------- +// +void CBubbleTouchPaneButton::SelectTextColor() + { + TAknsQsnTextColorsIndex textColorIndex( EAknsCIQsnTextColorsCG65 ); + TInt command = CommandId( EFalse ); + + if ( command == EPhoneCallComingCmdAnswer ) + { + textColorIndex = EAknsCIQsnTextColorsCG82; + } + else if ( command == EPhoneCallComingCmdReject ) + { + textColorIndex = EAknsCIQsnTextColorsCG83; + } + + // function button text color + SetTextColorIds( KAknsIIDQsnTextColors, textColorIndex ); + }