| 316 | } |
| 317 | |
| 318 | int UndoHistory::StartRedo() { |
| 319 | // Drop any leading startAction |
| 320 | if (actions[currentAction].at == startAction && currentAction < maxAction) |
| 321 | currentAction++; |
| 322 | |
| 323 | // Count the steps in this action |
| 324 | int act = currentAction; |
| 325 | while (actions[act].at != startAction && act < maxAction) { |
| 326 | act++; |
| 327 | } |
| 328 | return act - currentAction; |
| 329 | } |
| 330 | |
| 331 | const Action &UndoHistory::GetRedoStep() const { |
| 332 | return actions[currentAction]; |