{"action":"created","issue":{"url":"https://api.github.com/repos/MvvmCross/MvvmCross/issues/1177","labels_url":"https://api.github.com/repos/MvvmCross/MvvmCross/issues/1177/labels{/name}","comments_url":"https://api.github.com/repos/MvvmCross/MvvmCross/issues/1177/comments","events_url":"https://api.github.com/repos/MvvmCross/MvvmCross/issues/1177/events","html_url":"https://github.com/MvvmCross/MvvmCross/issues/1177","id":117350096,"number":1177,"title":"ReloadFromBundle not called","user":{"login":"dazinator","id":3176632,"avatar_url":"https://avatars.githubusercontent.com/u/3176632?v=3","gravatar_id":"","url":"https://api.github.com/users/dazinator","html_url":"https://github.com/dazinator","followers_url":"https://api.github.com/users/dazinator/followers","following_url":"https://api.github.com/users/dazinator/following{/other_user}","gists_url":"https://api.github.com/users/dazinator/gists{/gist_id}","starred_url":"https://api.github.com/users/dazinator/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dazinator/subscriptions","organizations_url":"https://api.github.com/users/dazinator/orgs","repos_url":"https://api.github.com/users/dazinator/repos","events_url":"https://api.github.com/users/dazinator/events{/privacy}","received_events_url":"https://api.github.com/users/dazinator/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-17T13:00:43Z","updated_at":"2015-11-17T13:03:24Z","closed_at":null,"body":"I am having an issue on Android, with ReloadFromBundle() not being called on my view model when screen orientation is changed and android decides to re-create the view.\r\n\r\nThis is with latest stable release of MvvmCross (version 3.5.1)\r\n\r\nI have simple view:\r\n\r\n```csharp\r\n [Activity(Label = \"Sync Screen\")]\r\n    public class SyncView : MvxActivity<SyncViewModel>\r\n    {\r\n\r\n}\r\n```\r\n\r\nAnd a ViewModel\r\n\r\n```csharp\r\n       protected override void SaveStateToBundle(IMvxBundle bundle)\r\n        {\r\n            //base.SaveStateToBundle(bundle);\r\n            bundle.Data.Add(\"Something\", \"blah\");            \r\n        }\r\n\r\n       protected override void ReloadFromBundle(IMvxBundle state)\r\n        {\r\n           if (state.Data.ContainsKey(\"Something\"))\r\n            {\r\n                var data = state.Data[\"Something\"];               \r\n            }\r\n            base.ReloadFromBundle(state);\r\n        }\r\n```\r\n\r\nNow - when I change orientation of the screen, `SaveStateToBundle` get's invoked. \r\nThe screen is then recreated (i.e OnCreate() get's called on the Activity).\r\nOnStart() get's called on my ViewModel\r\nbut ReloadFromBundle() never get's called on my ViewModel..\r\n\r\nAny ideas?\r\n\r\n\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/MvvmCross/MvvmCross/issues/comments/157365075","html_url":"https://github.com/MvvmCross/MvvmCross/issues/1177#issuecomment-157365075","issue_url":"https://api.github.com/repos/MvvmCross/MvvmCross/issues/1177","id":157365075,"user":{"login":"martijn00","id":6221156,"avatar_url":"https://avatars.githubusercontent.com/u/6221156?v=3","gravatar_id":"","url":"https://api.github.com/users/martijn00","html_url":"https://github.com/martijn00","followers_url":"https://api.github.com/users/martijn00/followers","following_url":"https://api.github.com/users/martijn00/following{/other_user}","gists_url":"https://api.github.com/users/martijn00/gists{/gist_id}","starred_url":"https://api.github.com/users/martijn00/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/martijn00/subscriptions","organizations_url":"https://api.github.com/users/martijn00/orgs","repos_url":"https://api.github.com/users/martijn00/repos","events_url":"https://api.github.com/users/martijn00/events{/privacy}","received_events_url":"https://api.github.com/users/martijn00/received_events","type":"User","site_admin":false},"created_at":"2015-11-17T13:03:24Z","updated_at":"2015-11-17T13:03:24Z","body":"Use the MvxCachingFragmentActivity from MvvmCross 4.0"}}