{"action":"created","issue":{"url":"https://api.github.com/repos/edubart/otclient/issues/677","labels_url":"https://api.github.com/repos/edubart/otclient/issues/677/labels{/name}","comments_url":"https://api.github.com/repos/edubart/otclient/issues/677/comments","events_url":"https://api.github.com/repos/edubart/otclient/issues/677/events","html_url":"https://github.com/edubart/otclient/pull/677","id":95582166,"number":677,"title":"Change when load and save occurs in gameinterface","user":{"login":"Quintinon","id":1514891,"avatar_url":"https://avatars.githubusercontent.com/u/1514891?v=3","gravatar_id":"","url":"https://api.github.com/users/Quintinon","html_url":"https://github.com/Quintinon","followers_url":"https://api.github.com/users/Quintinon/followers","following_url":"https://api.github.com/users/Quintinon/following{/other_user}","gists_url":"https://api.github.com/users/Quintinon/gists{/gist_id}","starred_url":"https://api.github.com/users/Quintinon/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Quintinon/subscriptions","organizations_url":"https://api.github.com/users/Quintinon/orgs","repos_url":"https://api.github.com/users/Quintinon/repos","events_url":"https://api.github.com/users/Quintinon/events{/privacy}","received_events_url":"https://api.github.com/users/Quintinon/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-17T04:17:44Z","updated_at":"2015-07-18T19:05:31Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/edubart/otclient/pulls/677","html_url":"https://github.com/edubart/otclient/pull/677","diff_url":"https://github.com/edubart/otclient/pull/677.diff","patch_url":"https://github.com/edubart/otclient/pull/677.patch"},"body":"Change when gameinterface calls load and save to prevent bottomSplitter from being put in the wrong location due to initial load resize events.\r\n\r\nWhat was occurring was:\r\ngameinterface module loaded and set bottomSplitter (between game window and chat) to the saved position.\r\nonGeometryChanged event was called 3 times (I could not find the root cause of startup calling this, but probably due to loading if the window should be fullscreen or not. My client was setup to load to fullscreen, while windowed mode was very small). The onGemoetryChanged event changed where the bottomSplitter was (probably due to the small windowed mode that the game may \"open\" with for a few milliseconds).\r\n\r\nNow what happens is:\r\ngameinterface module loads\r\ninitial onGeometryChanged events are called\r\nwhen g_app.onRun is called the splitter settings are loaded.\r\n\r\nI moved the save to occur on the g_app.onExit for symmetry."},"comment":{"url":"https://api.github.com/repos/edubart/otclient/issues/comments/122580790","html_url":"https://github.com/edubart/otclient/pull/677#issuecomment-122580790","issue_url":"https://api.github.com/repos/edubart/otclient/issues/677","id":122580790,"user":{"login":"BenDol","id":1935706,"avatar_url":"https://avatars.githubusercontent.com/u/1935706?v=3","gravatar_id":"","url":"https://api.github.com/users/BenDol","html_url":"https://github.com/BenDol","followers_url":"https://api.github.com/users/BenDol/followers","following_url":"https://api.github.com/users/BenDol/following{/other_user}","gists_url":"https://api.github.com/users/BenDol/gists{/gist_id}","starred_url":"https://api.github.com/users/BenDol/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/BenDol/subscriptions","organizations_url":"https://api.github.com/users/BenDol/orgs","repos_url":"https://api.github.com/users/BenDol/repos","events_url":"https://api.github.com/users/BenDol/events{/privacy}","received_events_url":"https://api.github.com/users/BenDol/received_events","type":"User","site_admin":false},"created_at":"2015-07-18T19:05:31Z","updated_at":"2015-07-18T19:05:31Z","body":"Have you had any load issues doing it this way? Race conditions etc."}}