{"action":"created","issue":{"url":"https://api.github.com/repos/tgjones/gemini/issues/203","repository_url":"https://api.github.com/repos/tgjones/gemini","labels_url":"https://api.github.com/repos/tgjones/gemini/issues/203/labels{/name}","comments_url":"https://api.github.com/repos/tgjones/gemini/issues/203/comments","events_url":"https://api.github.com/repos/tgjones/gemini/issues/203/events","html_url":"https://github.com/tgjones/gemini/pull/203","id":162263797,"node_id":"MDExOlB1bGxSZXF1ZXN0NzUxOTYwMTI=","number":203,"title":"Undo Redo: Improve performance when undo / redo stack changes","user":{"login":"EchterAgo","id":922233,"node_id":"MDQ6VXNlcjkyMjIzMw==","avatar_url":"https://avatars1.githubusercontent.com/u/922233?v=4","gravatar_id":"","url":"https://api.github.com/users/EchterAgo","html_url":"https://github.com/EchterAgo","followers_url":"https://api.github.com/users/EchterAgo/followers","following_url":"https://api.github.com/users/EchterAgo/following{/other_user}","gists_url":"https://api.github.com/users/EchterAgo/gists{/gist_id}","starred_url":"https://api.github.com/users/EchterAgo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/EchterAgo/subscriptions","organizations_url":"https://api.github.com/users/EchterAgo/orgs","repos_url":"https://api.github.com/users/EchterAgo/repos","events_url":"https://api.github.com/users/EchterAgo/events{/privacy}","received_events_url":"https://api.github.com/users/EchterAgo/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-06-25T04:49:52Z","updated_at":"2018-11-08T10:05:18Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/tgjones/gemini/pulls/203","html_url":"https://github.com/tgjones/gemini/pull/203","diff_url":"https://github.com/tgjones/gemini/pull/203.diff","patch_url":"https://github.com/tgjones/gemini/pull/203.patch"},"body":"I noticed while profiling my code that 99% of the CPU time to change the\r\nundo redo stack is spent in Gemini instead of actually setting values.\r\n\r\nThis commit changes the undo / redo stack into a single stack with an\r\ninteger keeping track of what is undo and what is redo. This way we can\r\njust easily synchronize the HistoryViewModel from the CollectionChanged\r\nevent of the UndoRedoManager stack. The advantage is that we can use an\r\nitem index in HistoryViewModel that is derived from the UndoRedoManager's\r\nitem index.\r\n\r\nTo do an undo / redo, we only need do undo / execute the needed actions\r\nand update the UndoActions. The HistoryViewModel listens for UndoActions\r\nchanges and will update all the HistoryItemViewModel's ItemTypes. This has\r\nthe advantage of only refreshing the view once when all the actions have\r\nbeen completed.\r\n\r\nThis greatly improves performance for large undo / redo operations."},"comment":{"url":"https://api.github.com/repos/tgjones/gemini/issues/comments/436940538","html_url":"https://github.com/tgjones/gemini/pull/203#issuecomment-436940538","issue_url":"https://api.github.com/repos/tgjones/gemini/issues/203","id":436940538,"node_id":"MDEyOklzc3VlQ29tbWVudDQzNjk0MDUzOA==","user":{"login":"EchterAgo","id":922233,"node_id":"MDQ6VXNlcjkyMjIzMw==","avatar_url":"https://avatars1.githubusercontent.com/u/922233?v=4","gravatar_id":"","url":"https://api.github.com/users/EchterAgo","html_url":"https://github.com/EchterAgo","followers_url":"https://api.github.com/users/EchterAgo/followers","following_url":"https://api.github.com/users/EchterAgo/following{/other_user}","gists_url":"https://api.github.com/users/EchterAgo/gists{/gist_id}","starred_url":"https://api.github.com/users/EchterAgo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/EchterAgo/subscriptions","organizations_url":"https://api.github.com/users/EchterAgo/orgs","repos_url":"https://api.github.com/users/EchterAgo/repos","events_url":"https://api.github.com/users/EchterAgo/events{/privacy}","received_events_url":"https://api.github.com/users/EchterAgo/received_events","type":"User","site_admin":false},"created_at":"2018-11-08T10:05:18Z","updated_at":"2018-11-08T10:05:18Z","author_association":"CONTRIBUTOR","body":"Changed the name to Undo/RedoActionCount, rebased and restored the order of using directives."}}
{"actor":{"display_login":"EchterAgo"}}