From f087f20fa247ef780cb5172319064dec51f2cac5 Mon Sep 17 00:00:00 2001 From: Matthew Hoops Date: Wed, 11 Apr 2012 09:33:43 -0400 Subject: PEGASUS: Fix the pegasus biochip recall button highlight --- engines/pegasus/items/biochips/pegasuschip.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'engines/pegasus/items/biochips/pegasuschip.cpp') diff --git a/engines/pegasus/items/biochips/pegasuschip.cpp b/engines/pegasus/items/biochips/pegasuschip.cpp index 1e3e0d7a88..320662af06 100644 --- a/engines/pegasus/items/biochips/pegasuschip.cpp +++ b/engines/pegasus/items/biochips/pegasuschip.cpp @@ -155,7 +155,17 @@ void PegasusChip::clickInPegasusHotspot() { break; } - setItemState(hiliteState); + // WORKAROUND: The original called setItemState() here. However, + // since we're overriding select() to call setUpPegasusChip(), + // the highlighted frame is never displayed! So, we're manually + // setting the state and selecting the item. Also of note is that + // setItemState() for this class is effectively useless since it + // always gets overriden in the select() function. The only reason + // that this doesn't end in infinite recursion is because setItemState() + // has a check against the current state to make sure you don't call + // select() again. + _itemState = hiliteState; + BiochipItem::select(); uint32 time = g_system->getMillis(); while (g_system->getMillis() < time + 500) { -- cgit v1.2.3