Bug 133257

Summary: in keyboard mode squares left depressed from autoreveal
Product: [Applications] kmines Reporter: Jake Brownson <jbrownson>
Component: generalAssignee: Hadacek Nicolas <hadacek>
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Ubuntu   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: Patch that fixes the bug, but may not be the best solution

Description Jake Brownson 2006-08-30 10:35:52 UTC
Version:            (using KDE KDE 3.5.4)
Installed from:    Ubuntu Packages
Compiler:          gcc 
OS:                Linux

If you press enter in keyboard and very quickly move the cursor using the arrows some boxes are left depressed. I've attached (or will attach) a possible fix, though I'm not sure it's the best way.
Comment 1 Jake Brownson 2006-08-30 10:36:38 UTC
Created attachment 17565 [details]
Patch that fixes the bug, but may not be the best solution
Comment 2 Matt Rogers 2006-10-18 05:28:50 UTC
SVN commit 596638 by mattr:

Apply patch from bug #133257 to fix that bug for the reporter. 
No response from the assignee (who appears to be inactive for quite

Thanks for the patch!

BUG: 133257

 M  +4 -3      field.cpp  
 M  +1 -1      field.h  

--- branches/KDE/3.5/kdegames/kmines/field.cpp #596637:596638
@@ -231,14 +231,15 @@
 void Field::keyboardAutoReveal()
-	pressClearFunction(_cursor, true);
+	_cursor_back = _cursor;
+	pressClearFunction(_cursor_back, true);
 	QTimer::singleShot(50, this, SLOT(keyboardAutoRevealSlot()));
 void Field::keyboardAutoRevealSlot()
-	pressClearFunction(_cursor, false);
-	doAutoReveal(_cursor);
+	pressClearFunction(_cursor_back, false);
+	doAutoReveal(_cursor_back);
 void Field::doAutoReveal(const Coord &c)
--- branches/KDE/3.5/kdegames/kmines/field.h #596637:596638
@@ -86,7 +86,7 @@
 	GameState   _state;
 	bool              _reveal;
 	SolvingState _solvingState;
-	KGrid2D::Coord  _cursor, _advisedCoord;
+	KGrid2D::Coord  _cursor, _cursor_back, _advisedCoord;
 	double        _advisedProba;
 	int               _currentAction;
 	Level          _level;