Add instruction move up/down buttons to GUI.

Has block and individual instruction move modes, depending on ctrl.
This commit is contained in:
Jonathan G Rennison
2017-02-26 23:52:15 +00:00
parent f10c32de53
commit 13f8de58c3
4 changed files with 122 additions and 1 deletions

View File

@@ -623,6 +623,7 @@ enum TraceRestrictDoCommandType {
TRDCT_MODIFY_DUAL_ITEM, ///< modify second item of dual-part instruction at offset field to given value
TRDCT_REMOVE_ITEM, ///< remove instruction at offset field
TRDCT_SHALLOW_REMOVE_ITEM, ///< shallow remove instruction at offset field, does not delete contents of block
TRDCT_MOVE_ITEM, ///< move instruction or block at offset field
TRDCT_PROG_COPY, ///< copy program operation. Do not re-order this with respect to other values
TRDCT_PROG_SHARE, ///< share program operation
@@ -647,6 +648,7 @@ CommandCost CmdProgramSignalTraceRestrict(TileIndex tile, DoCommandFlag flags, u
CommandCost CmdProgramSignalTraceRestrictProgMgmt(TileIndex tile, DoCommandFlag flags, uint32 p1, uint32 p2, const char *text);
CommandCost TraceRestrictProgramRemoveItemAt(std::vector<TraceRestrictItem> &items, uint32 offset, bool shallow_mode);
CommandCost TraceRestrictProgramMoveItemAt(std::vector<TraceRestrictItem> &items, uint32 &offset, bool up, bool shallow_mode);
void ShowTraceRestrictProgramWindow(TileIndex tile, Track track);