{"action":"created","comment":{"url":"https://api.github.com/repos/FAForever/client/pulls/comments/154302476","pull_request_review_id":80444552,"id":154302476,"diff_hunk":"@@ -273,43 +272,49 @@ def updatePlayer(self):\n         # Rating icon choice  (chr(0xB1) = +-)\n         formatting = (\"Global Rating: {} ({} Games) [{}\\xb1{}]\\n\"\n                       \"Ladder Rating: {} [{}\\xb1{}]\")\n-        self.rankItem.setToolTip(formatting.format(\n+        tooltip_str = formatting.format(\n             str(int(rating)),\n             str(player.number_of_games),\n             str(int(player.rating_mean)),\n             str(int(player.rating_deviation)),\n             str(int(ladder_rating)),\n             str(int(player.ladder_rating_mean)),\n-            str(int(player.ladder_rating_deviation))))\n+            str(int(player.ladder_rating_deviation)))\n \n         league = player.league\n         if league is not None:\n-            formatting = (\"Division : {}\\n\"\n-                          \"Global Rating: {}\")\n-            self.rankItem.setToolTip(formatting.format(\n-                league[\"division\"],\n-                str(int(rating))))\n-            self.rankItem.setIcon(util.THEME.icon(\"chat/rank/%s.png\" % league[\"league\"]))\n+            icon_str, tooltip_str = league[\"league\"], \"Division : \" + league[\"division\"] + \"\\n\" + tooltip_str\n         else:\n-            self.rankItem.setIcon(util.THEME.icon(\"chat/rank/newplayer.png\"))\n-\n-        self._verifySortOrder()\n+            icon_str = \"newplayer\"\n+        self.rankItem.setIcon(util.THEME.icon(\"chat/rank/%s.png\" % icon_str))\n+        self.rankItem.setToolTip(tooltip_str)\n \n     def updateGame(self):\n         # Status icon handling\n         game = self.user_game\n-        player = self.user_player\n         if game is not None and not game.closed():","path":"src/chat/chatter.py","position":83,"original_position":83,"commit_id":"e37a346efb8c1dd5a844e06cff923f80bf30251f","original_commit_id":"e37a346efb8c1dd5a844e06cff923f80bf30251f","user":{"login":"Wesmania","id":4634112,"avatar_url":"https://avatars0.githubusercontent.com/u/4634112?v=4","gravatar_id":"","url":"https://api.github.com/users/Wesmania","html_url":"https://github.com/Wesmania","followers_url":"https://api.github.com/users/Wesmania/followers","following_url":"https://api.github.com/users/Wesmania/following{/other_user}","gists_url":"https://api.github.com/users/Wesmania/gists{/gist_id}","starred_url":"https://api.github.com/users/Wesmania/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Wesmania/subscriptions","organizations_url":"https://api.github.com/users/Wesmania/orgs","repos_url":"https://api.github.com/users/Wesmania/repos","events_url":"https://api.github.com/users/Wesmania/events{/privacy}","received_events_url":"https://api.github.com/users/Wesmania/received_events","type":"User","site_admin":false},"body":"I'd still like to see icon_str moved into a separate method. I know it seems like repeating all these cases, but it will really make things more readable (and in the future we might just want to change the tooltip separately from the icon anyway)","created_at":"2017-12-01T09:36:12Z","updated_at":"2017-12-01T09:36:12Z","html_url":"https://github.com/FAForever/client/pull/892#discussion_r154302476","pull_request_url":"https://api.github.com/repos/FAForever/client/pulls/892","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/FAForever/client/pulls/comments/154302476"},"html":{"href":"https://github.com/FAForever/client/pull/892#discussion_r154302476"},"pull_request":{"href":"https://api.github.com/repos/FAForever/client/pulls/892"}}},"pull_request":{"url":"https://api.github.com/repos/FAForever/client/pulls/892","id":155514151,"html_url":"https://github.com/FAForever/client/pull/892","diff_url":"https://github.com/FAForever/client/pull/892.diff","patch_url":"https://github.com/FAForever/client/pull/892.patch","issue_url":"https://api.github.com/repos/FAForever/client/issues/892","number":892,"state":"open","locked":false,"title":"add host & live-game-delay to user status in Chat","user":{"login":"GrotheFAF","id":19195504,"avatar_url":"https://avatars0.githubusercontent.com/u/19195504?v=4","gravatar_id":"","url":"https://api.github.com/users/GrotheFAF","html_url":"https://github.com/GrotheFAF","followers_url":"https://api.github.com/users/GrotheFAF/followers","following_url":"https://api.github.com/users/GrotheFAF/following{/other_user}","gists_url":"https://api.github.com/users/GrotheFAF/gists{/gist_id}","starred_url":"https://api.github.com/users/GrotheFAF/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GrotheFAF/subscriptions","organizations_url":"https://api.github.com/users/GrotheFAF/orgs","repos_url":"https://api.github.com/users/GrotheFAF/repos","events_url":"https://api.github.com/users/GrotheFAF/events{/privacy}","received_events_url":"https://api.github.com/users/GrotheFAF/received_events","type":"User","site_admin":false},"body":"updatePlayer:\r\nrefactor tooltip_str, icon_str\r\nadd __.png for no country2ip\r\nremove set_color and verifySortOrder (updateUser is doing that just fine)\r\n\r\nupdateGame:\r\nrefactor gamestr, tooltip_str, icon_str\r\nuse other single sword (gold it) for host of hosted game\r\nadd title, mod, map and players info to user status tooltip (and remove url)\r\nadd playing5.png for live-game delay status icon\r\nadd liveReplayAvailable connection for updateGame\r\nadd unknown.png for user with unknown game.state (you never know...)\r\n\r\nfix QUrl for pyqt5","created_at":"2017-11-30T04:02:36Z","updated_at":"2017-12-01T09:36:12Z","closed_at":null,"merged_at":null,"merge_commit_sha":"4e690b71da8267fe132c62e5e6986b7b4976a941","assignee":null,"assignees":[],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/FAForever/client/pulls/892/commits","review_comments_url":"https://api.github.com/repos/FAForever/client/pulls/892/comments","review_comment_url":"https://api.github.com/repos/FAForever/client/pulls/comments{/number}","comments_url":"https://api.github.com/repos/FAForever/client/issues/892/comments","statuses_url":"https://api.github.com/repos/FAForever/client/statuses/e37a346efb8c1dd5a844e06cff923f80bf30251f","head":{"label":"GrotheFAF:upgrade-user-status-ChatLobby","ref":"upgrade-user-status-ChatLobby","sha":"e37a346efb8c1dd5a844e06cff923f80bf30251f","user":{"login":"GrotheFAF","id":19195504,"avatar_url":"https://avatars0.githubusercontent.com/u/19195504?v=4","gravatar_id":"","url":"https://api.github.com/users/GrotheFAF","html_url":"https://github.com/GrotheFAF","followers_url":"https://api.github.com/users/GrotheFAF/followers","following_url":"https://api.github.com/users/GrotheFAF/following{/other_user}","gists_url":"https://api.github.com/users/GrotheFAF/gists{/gist_id}","starred_url":"https://api.github.com/users/GrotheFAF/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GrotheFAF/subscriptions","organizations_url":"https://api.github.com/users/GrotheFAF/orgs","repos_url":"https://api.github.com/users/GrotheFAF/repos","events_url":"https://api.github.com/users/GrotheFAF/events{/privacy}","received_events_url":"https://api.github.com/users/GrotheFAF/received_events","type":"User","site_admin":false},"repo":{"id":67766235,"name":"client","full_name":"GrotheFAF/client","owner":{"login":"GrotheFAF","id":19195504,"avatar_url":"https://avatars0.githubusercontent.com/u/19195504?v=4","gravatar_id":"","url":"https://api.github.com/users/GrotheFAF","html_url":"https://github.com/GrotheFAF","followers_url":"https://api.github.com/users/GrotheFAF/followers","following_url":"https://api.github.com/users/GrotheFAF/following{/other_user}","gists_url":"https://api.github.com/users/GrotheFAF/gists{/gist_id}","starred_url":"https://api.github.com/users/GrotheFAF/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GrotheFAF/subscriptions","organizations_url":"https://api.github.com/users/GrotheFAF/orgs","repos_url":"https://api.github.com/users/GrotheFAF/repos","events_url":"https://api.github.com/users/GrotheFAF/events{/privacy}","received_events_url":"https://api.github.com/users/GrotheFAF/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/GrotheFAF/client","description":"FAF Python Client","fork":true,"url":"https://api.github.com/repos/GrotheFAF/client","forks_url":"https://api.github.com/repos/GrotheFAF/client/forks","keys_url":"https://api.github.com/repos/GrotheFAF/client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GrotheFAF/client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GrotheFAF/client/teams","hooks_url":"https://api.github.com/repos/GrotheFAF/client/hooks","issue_events_url":"https://api.github.com/repos/GrotheFAF/client/issues/events{/number}","events_url":"https://api.github.com/repos/GrotheFAF/client/events","assignees_url":"https://api.github.com/repos/GrotheFAF/client/assignees{/user}","branches_url":"https://api.github.com/repos/GrotheFAF/client/branches{/branch}","tags_url":"https://api.github.com/repos/GrotheFAF/client/tags","blobs_url":"https://api.github.com/repos/GrotheFAF/client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GrotheFAF/client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GrotheFAF/client/git/refs{/sha}","trees_url":"https://api.github.com/repos/GrotheFAF/client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GrotheFAF/client/statuses/{sha}","languages_url":"https://api.github.com/repos/GrotheFAF/client/languages","stargazers_url":"https://api.github.com/repos/GrotheFAF/client/stargazers","contributors_url":"https://api.github.com/repos/GrotheFAF/client/contributors","subscribers_url":"https://api.github.com/repos/GrotheFAF/client/subscribers","subscription_url":"https://api.github.com/repos/GrotheFAF/client/subscription","commits_url":"https://api.github.com/repos/GrotheFAF/client/commits{/sha}","git_commits_url":"https://api.github.com/repos/GrotheFAF/client/git/commits{/sha}","comments_url":"https://api.github.com/repos/GrotheFAF/client/comments{/number}","issue_comment_url":"https://api.github.com/repos/GrotheFAF/client/issues/comments{/number}","contents_url":"https://api.github.com/repos/GrotheFAF/client/contents/{+path}","compare_url":"https://api.github.com/repos/GrotheFAF/client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GrotheFAF/client/merges","archive_url":"https://api.github.com/repos/GrotheFAF/client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GrotheFAF/client/downloads","issues_url":"https://api.github.com/repos/GrotheFAF/client/issues{/number}","pulls_url":"https://api.github.com/repos/GrotheFAF/client/pulls{/number}","milestones_url":"https://api.github.com/repos/GrotheFAF/client/milestones{/number}","notifications_url":"https://api.github.com/repos/GrotheFAF/client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GrotheFAF/client/labels{/name}","releases_url":"https://api.github.com/repos/GrotheFAF/client/releases{/id}","deployments_url":"https://api.github.com/repos/GrotheFAF/client/deployments","created_at":"2016-09-09T04:40:49Z","updated_at":"2017-02-16T18:05:08Z","pushed_at":"2017-11-30T23:57:16Z","git_url":"git://github.com/GrotheFAF/client.git","ssh_url":"git@github.com:GrotheFAF/client.git","clone_url":"https://github.com/GrotheFAF/client.git","svn_url":"https://github.com/GrotheFAF/client","homepage":"","size":13522,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"FAForever:develop","ref":"develop","sha":"2b04328b240bbf807844037427d5fe3ea92b1224","user":{"login":"FAForever","id":8887184,"avatar_url":"https://avatars2.githubusercontent.com/u/8887184?v=4","gravatar_id":"","url":"https://api.github.com/users/FAForever","html_url":"https://github.com/FAForever","followers_url":"https://api.github.com/users/FAForever/followers","following_url":"https://api.github.com/users/FAForever/following{/other_user}","gists_url":"https://api.github.com/users/FAForever/gists{/gist_id}","starred_url":"https://api.github.com/users/FAForever/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FAForever/subscriptions","organizations_url":"https://api.github.com/users/FAForever/orgs","repos_url":"https://api.github.com/users/FAForever/repos","events_url":"https://api.github.com/users/FAForever/events{/privacy}","received_events_url":"https://api.github.com/users/FAForever/received_events","type":"Organization","site_admin":false},"repo":{"id":24400684,"name":"client","full_name":"FAForever/client","owner":{"login":"FAForever","id":8887184,"avatar_url":"https://avatars2.githubusercontent.com/u/8887184?v=4","gravatar_id":"","url":"https://api.github.com/users/FAForever","html_url":"https://github.com/FAForever","followers_url":"https://api.github.com/users/FAForever/followers","following_url":"https://api.github.com/users/FAForever/following{/other_user}","gists_url":"https://api.github.com/users/FAForever/gists{/gist_id}","starred_url":"https://api.github.com/users/FAForever/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/FAForever/subscriptions","organizations_url":"https://api.github.com/users/FAForever/orgs","repos_url":"https://api.github.com/users/FAForever/repos","events_url":"https://api.github.com/users/FAForever/events{/privacy}","received_events_url":"https://api.github.com/users/FAForever/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/FAForever/client","description":"FAF Python Client","fork":false,"url":"https://api.github.com/repos/FAForever/client","forks_url":"https://api.github.com/repos/FAForever/client/forks","keys_url":"https://api.github.com/repos/FAForever/client/keys{/key_id}","collaborators_url":"https://api.github.com/repos/FAForever/client/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/FAForever/client/teams","hooks_url":"https://api.github.com/repos/FAForever/client/hooks","issue_events_url":"https://api.github.com/repos/FAForever/client/issues/events{/number}","events_url":"https://api.github.com/repos/FAForever/client/events","assignees_url":"https://api.github.com/repos/FAForever/client/assignees{/user}","branches_url":"https://api.github.com/repos/FAForever/client/branches{/branch}","tags_url":"https://api.github.com/repos/FAForever/client/tags","blobs_url":"https://api.github.com/repos/FAForever/client/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/FAForever/client/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/FAForever/client/git/refs{/sha}","trees_url":"https://api.github.com/repos/FAForever/client/git/trees{/sha}","statuses_url":"https://api.github.com/repos/FAForever/client/statuses/{sha}","languages_url":"https://api.github.com/repos/FAForever/client/languages","stargazers_url":"https://api.github.com/repos/FAForever/client/stargazers","contributors_url":"https://api.github.com/repos/FAForever/client/contributors","subscribers_url":"https://api.github.com/repos/FAForever/client/subscribers","subscription_url":"https://api.github.com/repos/FAForever/client/subscription","commits_url":"https://api.github.com/repos/FAForever/client/commits{/sha}","git_commits_url":"https://api.github.com/repos/FAForever/client/git/commits{/sha}","comments_url":"https://api.github.com/repos/FAForever/client/comments{/number}","issue_comment_url":"https://api.github.com/repos/FAForever/client/issues/comments{/number}","contents_url":"https://api.github.com/repos/FAForever/client/contents/{+path}","compare_url":"https://api.github.com/repos/FAForever/client/compare/{base}...{head}","merges_url":"https://api.github.com/repos/FAForever/client/merges","archive_url":"https://api.github.com/repos/FAForever/client/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/FAForever/client/downloads","issues_url":"https://api.github.com/repos/FAForever/client/issues{/number}","pulls_url":"https://api.github.com/repos/FAForever/client/pulls{/number}","milestones_url":"https://api.github.com/repos/FAForever/client/milestones{/number}","notifications_url":"https://api.github.com/repos/FAForever/client/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/FAForever/client/labels{/name}","releases_url":"https://api.github.com/repos/FAForever/client/releases{/id}","deployments_url":"https://api.github.com/repos/FAForever/client/deployments","created_at":"2014-09-24T04:25:57Z","updated_at":"2017-11-15T09:34:21Z","pushed_at":"2017-11-30T23:57:18Z","git_url":"git://github.com/FAForever/client.git","ssh_url":"git@github.com:FAForever/client.git","clone_url":"https://github.com/FAForever/client.git","svn_url":"https://github.com/FAForever/client","homepage":"","size":14309,"stargazers_count":45,"watchers_count":45,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":86,"mirror_url":null,"archived":false,"open_issues_count":174,"license":{"key":"gpl-3.0","name":"GNU General Public License v3.0","spdx_id":"GPL-3.0","url":"https://api.github.com/licenses/gpl-3.0"},"forks":86,"open_issues":174,"watchers":45,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/FAForever/client/pulls/892"},"html":{"href":"https://github.com/FAForever/client/pull/892"},"issue":{"href":"https://api.github.com/repos/FAForever/client/issues/892"},"comments":{"href":"https://api.github.com/repos/FAForever/client/issues/892/comments"},"review_comments":{"href":"https://api.github.com/repos/FAForever/client/pulls/892/comments"},"review_comment":{"href":"https://api.github.com/repos/FAForever/client/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/FAForever/client/pulls/892/commits"},"statuses":{"href":"https://api.github.com/repos/FAForever/client/statuses/e37a346efb8c1dd5a844e06cff923f80bf30251f"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"Wesmania"}}