{"id":27789126,"url":"https://github.com/jcs090218/unity.undoredosystem","last_synced_at":"2025-10-16T10:08:50.798Z","repository":{"id":97568389,"uuid":"146203051","full_name":"jcs090218/Unity.UndoRedoSystem","owner":"jcs090218","description":"Undo Redo system implementation in Unity uGUI system","archived":false,"fork":false,"pushed_at":"2025-02-26T06:27:58.000Z","size":445,"stargazers_count":36,"open_issues_count":0,"forks_count":8,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-07-04T08:39:54.534Z","etag":null,"topics":["tools","undo-redo","unity"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jcs090218.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"jcs090218","patreon":null,"open_collective":null,"ko_fi":null,"tidelift":null,"community_bridge":null,"liberapay":null,"issuehunt":null,"otechie":null,"custom":null}},"created_at":"2018-08-26T17:47:32.000Z","updated_at":"2025-06-03T07:36:31.000Z","dependencies_parsed_at":"2025-03-14T04:15:13.961Z","dependency_job_id":null,"html_url":"https://github.com/jcs090218/Unity.UndoRedoSystem","commit_stats":null,"previous_names":["jcs090218/unity.undoredosystem"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jcs090218/Unity.UndoRedoSystem","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcs090218%2FUnity.UndoRedoSystem","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcs090218%2FUnity.UndoRedoSystem/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcs090218%2FUnity.UndoRedoSystem/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcs090218%2FUnity.UndoRedoSystem/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jcs090218","download_url":"https://codeload.github.com/jcs090218/Unity.UndoRedoSystem/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcs090218%2FUnity.UndoRedoSystem/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264815653,"owners_count":23667984,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["tools","undo-redo","unity"],"created_at":"2025-04-30T17:41:53.031Z","updated_at":"2025-10-16T10:08:45.755Z","avatar_url":"https://github.com/jcs090218.png","language":"C#","funding_links":["https://github.com/sponsors/jcs090218"],"categories":[],"sub_categories":[],"readme":"[![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)\n[![Unity Engine](https://img.shields.io/badge/unity-2018.2+-black.svg?style=flat\u0026logo=unity)](https://unity3d.com/get-unity/download/archive)\n\n# Undo Redo System\n\n[![Build Status](https://travis-ci.com/jcs090218/Unity_UndoRedoSystem.svg?branch=master)](https://travis-ci.com/jcs090218/Unity_UndoRedoSystem)\n\n\u003cimg src=\"./screenshot/undo_redo_demo.gif\"/\u003e\n\nUndo Redo system implementation in Unity uGUI system.\n\n## Supported UI\n\n* Input Field\n* Dropdown\n* Toggle\n* Scrollbar\n* Slider\n\n## API\n\n### Undo Redo System\n\n```cs\nJCS_UndoRedoSystem urs = this.GetComponent\u003cJCS_UndoRedoSystem\u003e();\n\n// Do undo once from this system if any.\nurs.UndoComponent();\n\n// Do redo once from this system if any.\nurs.RedoComponent();\n\n// Stop recording undo/redo action to all the component control \n// by this undo/redo system.\nurs.StopRecrodingAll();\n\n// Start recording undo/redo action to all the component control \n// by this undo/redo system.\nurs.StartRecrodingAll();\n\n// Record initialize data once to all undo/redo component.\nurs.RecordPrevData();\n\n/* Clear history */\n{\n    // Clear all undo history.\n    urs.ClearUndoComp();\n\n    // Clear all redo history.\n    urs.ClearRedoComp();\n\n    // Clear all the undo redo history data.\n    urs.ClearAllUndoRedoHistory();\n}\n\n/* Check for undo redo action exists? */\n{\n    // Check if there is at least one undo history?\n    bool undoData = urs.ThereIsUndoHistory();\n\n    // Check if there is at least one redo history?\n    bool redoData = urs.ThereIsRedoHistory();\n\n    // Check if there is at least one undo/redo history?\n    bool undoRedoData = urs.ThereIsUndoOrRedoHistory();\n}\n```\n\n### Undo Redo Component\n\n```cs\nJCS_UndoRedoComponent urc = this.GetComponent\u003cJCS_UndoRedoComponent\u003e();\n\n// Do one undo to this component.\nurc.Undo();\n\n// Dp one redo to this component.\nurc.Redo();\n\n// Stop recording undo/redo action starting from this moment.\nurc.StopRecording();\n\n// Start recording undo/redo action starting from this moment.\nurc.StartRecording();\n\n// Is the current component recording undo/redo action now?\nbool isRecording = urc.IsRecording();\n\n// If the UI value have changed by script at initialize time \n// but the undo/redo component did not get the correct default \n// data from the UI call this manually will record down the UI \n// starting value.\nurc.RecordPrevData();\n\n/* Clear history */\n{\n    // Clear all undo history to this component.\n    urc.ClearAllUndo();\n    \n    // Clear all redo history to this component.\n    urc.ClearAllRedo();\n    \n    // Clear all undo and redo history to this component.\n    urc.ClearAllUndoRedoHistory();\n}\n```\n\n## 📌 Dependencies\n\n* [JCSUnity](https://github.com/jcs090218/JCSUnity) by [Jen-Chieh Shen](https://github.com/jcs090218)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjcs090218%2Funity.undoredosystem","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjcs090218%2Funity.undoredosystem","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjcs090218%2Funity.undoredosystem/lists"}