{"action":"created","comment":{"url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/comments/69559384","id":69559384,"diff_hunk":"@@ -2477,3 +2477,32 @@ void window_update_textbox()\n \t\twindow_event_textinput_call(w, gCurrentTextBox.widget_index, gTextBoxInput);\n \t}\n }\n+\n+bool window_is_visible(rct_window* w)\n+{\n+\tif (w->viewport == NULL)\n+\t{\n+\t\t// default to previous behavior\n+\t\treturn true;\n+\t}\n+\n+\t// consider main window always visible\n+\tif (w->classification == WC_MAIN_WINDOW)\n+\t\treturn true;\n+\n+\tfor (rct_window *w_other = g_window_list; w < RCT2_NEW_WINDOW; w_other++)\n+\t{\n+\t\t// if covered by a higher window, no rendering needed\n+\t\tif (w_other > w\n+\t\t\t&& w_other->x <= w->x\n+\t\t\t&& w_other->y <= w->y\n+\t\t\t&& (w_other->x + w_other->width) >= (w->x + w->width)\n+\t\t\t&& (w_other->y + w_other->height) >= (w->y + w->height))\n+\t\t{\n+\t\t\treturn false;\n+\t\t}\n+\t}\n+\n+\t// default to previous behavior\n+\treturn true;\n+}","path":"src/interface/window.c","position":41,"original_position":41,"commit_id":"0e70c5fabd4aba010964e0eedabbb613f735b264","original_commit_id":"0e70c5fabd4aba010964e0eedabbb613f735b264","user":{"login":"IntelOrca","id":1482259,"avatar_url":"https://avatars.githubusercontent.com/u/1482259?v=3","gravatar_id":"","url":"https://api.github.com/users/IntelOrca","html_url":"https://github.com/IntelOrca","followers_url":"https://api.github.com/users/IntelOrca/followers","following_url":"https://api.github.com/users/IntelOrca/following{/other_user}","gists_url":"https://api.github.com/users/IntelOrca/gists{/gist_id}","starred_url":"https://api.github.com/users/IntelOrca/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/IntelOrca/subscriptions","organizations_url":"https://api.github.com/users/IntelOrca/orgs","repos_url":"https://api.github.com/users/IntelOrca/repos","events_url":"https://api.github.com/users/IntelOrca/events{/privacy}","received_events_url":"https://api.github.com/users/IntelOrca/received_events","type":"User","site_admin":false},"body":"VS won't automatically add a new line. So if you paste or type at the end of the document, it will be after the new line character.","created_at":"2016-07-05T13:10:19Z","updated_at":"2016-07-05T13:10:19Z","html_url":"https://github.com/OpenRCT2/OpenRCT2/pull/3985#discussion_r69559384","pull_request_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/3985","_links":{"self":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/comments/69559384"},"html":{"href":"https://github.com/OpenRCT2/OpenRCT2/pull/3985#discussion_r69559384"},"pull_request":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/3985"}}},"pull_request":{"url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/3985","id":76183375,"html_url":"https://github.com/OpenRCT2/OpenRCT2/pull/3985","diff_url":"https://github.com/OpenRCT2/OpenRCT2/pull/3985.diff","patch_url":"https://github.com/OpenRCT2/OpenRCT2/pull/3985.patch","issue_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/issues/3985","number":3985,"state":"open","locked":false,"title":"Skip drawing windows that are completely covered by another window.  …","user":{"login":"Rodbourn","id":2514328,"avatar_url":"https://avatars.githubusercontent.com/u/2514328?v=3","gravatar_id":"","url":"https://api.github.com/users/Rodbourn","html_url":"https://github.com/Rodbourn","followers_url":"https://api.github.com/users/Rodbourn/followers","following_url":"https://api.github.com/users/Rodbourn/following{/other_user}","gists_url":"https://api.github.com/users/Rodbourn/gists{/gist_id}","starred_url":"https://api.github.com/users/Rodbourn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Rodbourn/subscriptions","organizations_url":"https://api.github.com/users/Rodbourn/orgs","repos_url":"https://api.github.com/users/Rodbourn/repos","events_url":"https://api.github.com/users/Rodbourn/events{/privacy}","received_events_url":"https://api.github.com/users/Rodbourn/received_events","type":"User","site_admin":false},"body":"…This helps in preventing many windows from bringing the game to a crawl, such as viewing many staff at once on top of each other.\r\n\r\nYou can recreate the issue by opening many (dozen or so) staff at the same time that cover each other.  The frame rate will continue to drop with each additional window.  With this update the frame rate will hold when the windows are stacked over each other.  This should help in cases such as dropping many new handymen at once since the windows are opened at the same location.","created_at":"2016-07-04T16:12:23Z","updated_at":"2016-07-05T13:10:19Z","closed_at":null,"merged_at":null,"merge_commit_sha":"df6e67c0025dcf0a0bbf393b44effcd8c2e94e6a","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/3985/commits","review_comments_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/3985/comments","review_comment_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/comments{/number}","comments_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/issues/3985/comments","statuses_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/statuses/0e70c5fabd4aba010964e0eedabbb613f735b264","head":{"label":"Rodbourn:develop","ref":"develop","sha":"0e70c5fabd4aba010964e0eedabbb613f735b264","user":{"login":"Rodbourn","id":2514328,"avatar_url":"https://avatars.githubusercontent.com/u/2514328?v=3","gravatar_id":"","url":"https://api.github.com/users/Rodbourn","html_url":"https://github.com/Rodbourn","followers_url":"https://api.github.com/users/Rodbourn/followers","following_url":"https://api.github.com/users/Rodbourn/following{/other_user}","gists_url":"https://api.github.com/users/Rodbourn/gists{/gist_id}","starred_url":"https://api.github.com/users/Rodbourn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Rodbourn/subscriptions","organizations_url":"https://api.github.com/users/Rodbourn/orgs","repos_url":"https://api.github.com/users/Rodbourn/repos","events_url":"https://api.github.com/users/Rodbourn/events{/privacy}","received_events_url":"https://api.github.com/users/Rodbourn/received_events","type":"User","site_admin":false},"repo":{"id":61163838,"name":"OpenRCT2","full_name":"Rodbourn/OpenRCT2","owner":{"login":"Rodbourn","id":2514328,"avatar_url":"https://avatars.githubusercontent.com/u/2514328?v=3","gravatar_id":"","url":"https://api.github.com/users/Rodbourn","html_url":"https://github.com/Rodbourn","followers_url":"https://api.github.com/users/Rodbourn/followers","following_url":"https://api.github.com/users/Rodbourn/following{/other_user}","gists_url":"https://api.github.com/users/Rodbourn/gists{/gist_id}","starred_url":"https://api.github.com/users/Rodbourn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Rodbourn/subscriptions","organizations_url":"https://api.github.com/users/Rodbourn/orgs","repos_url":"https://api.github.com/users/Rodbourn/repos","events_url":"https://api.github.com/users/Rodbourn/events{/privacy}","received_events_url":"https://api.github.com/users/Rodbourn/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Rodbourn/OpenRCT2","description":"An open source re-implementation of Roller Coaster Tycoon 2.","fork":true,"url":"https://api.github.com/repos/Rodbourn/OpenRCT2","forks_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/forks","keys_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/teams","hooks_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/hooks","issue_events_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/issues/events{/number}","events_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/events","assignees_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/assignees{/user}","branches_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/branches{/branch}","tags_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/tags","blobs_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/git/refs{/sha}","trees_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/statuses/{sha}","languages_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/languages","stargazers_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/stargazers","contributors_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/contributors","subscribers_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/subscribers","subscription_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/subscription","commits_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/commits{/sha}","git_commits_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/git/commits{/sha}","comments_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/comments{/number}","issue_comment_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/issues/comments{/number}","contents_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/contents/{+path}","compare_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/merges","archive_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/downloads","issues_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/issues{/number}","pulls_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/pulls{/number}","milestones_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/milestones{/number}","notifications_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/labels{/name}","releases_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/releases{/id}","deployments_url":"https://api.github.com/repos/Rodbourn/OpenRCT2/deployments","created_at":"2016-06-14T23:53:47Z","updated_at":"2016-06-14T23:53:50Z","pushed_at":"2016-07-04T16:09:23Z","git_url":"git://github.com/Rodbourn/OpenRCT2.git","ssh_url":"git@github.com:Rodbourn/OpenRCT2.git","clone_url":"https://github.com/Rodbourn/OpenRCT2.git","svn_url":"https://github.com/Rodbourn/OpenRCT2","homepage":"http://openrct2.website","size":38275,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"develop"}},"base":{"label":"OpenRCT2:develop","ref":"develop","sha":"b4886d508832476086dca0199cc7e0bbac793c53","user":{"login":"OpenRCT2","id":8473908,"avatar_url":"https://avatars.githubusercontent.com/u/8473908?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenRCT2","html_url":"https://github.com/OpenRCT2","followers_url":"https://api.github.com/users/OpenRCT2/followers","following_url":"https://api.github.com/users/OpenRCT2/following{/other_user}","gists_url":"https://api.github.com/users/OpenRCT2/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenRCT2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenRCT2/subscriptions","organizations_url":"https://api.github.com/users/OpenRCT2/orgs","repos_url":"https://api.github.com/users/OpenRCT2/repos","events_url":"https://api.github.com/users/OpenRCT2/events{/privacy}","received_events_url":"https://api.github.com/users/OpenRCT2/received_events","type":"Organization","site_admin":false},"repo":{"id":18348651,"name":"OpenRCT2","full_name":"OpenRCT2/OpenRCT2","owner":{"login":"OpenRCT2","id":8473908,"avatar_url":"https://avatars.githubusercontent.com/u/8473908?v=3","gravatar_id":"","url":"https://api.github.com/users/OpenRCT2","html_url":"https://github.com/OpenRCT2","followers_url":"https://api.github.com/users/OpenRCT2/followers","following_url":"https://api.github.com/users/OpenRCT2/following{/other_user}","gists_url":"https://api.github.com/users/OpenRCT2/gists{/gist_id}","starred_url":"https://api.github.com/users/OpenRCT2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/OpenRCT2/subscriptions","organizations_url":"https://api.github.com/users/OpenRCT2/orgs","repos_url":"https://api.github.com/users/OpenRCT2/repos","events_url":"https://api.github.com/users/OpenRCT2/events{/privacy}","received_events_url":"https://api.github.com/users/OpenRCT2/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/OpenRCT2/OpenRCT2","description":"An open source re-implementation of RollerCoaster Tycoon 2.","fork":false,"url":"https://api.github.com/repos/OpenRCT2/OpenRCT2","forks_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/forks","keys_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/teams","hooks_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/hooks","issue_events_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/issues/events{/number}","events_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/events","assignees_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/assignees{/user}","branches_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/branches{/branch}","tags_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/tags","blobs_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/git/refs{/sha}","trees_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/statuses/{sha}","languages_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/languages","stargazers_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/stargazers","contributors_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/contributors","subscribers_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/subscribers","subscription_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/subscription","commits_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/commits{/sha}","git_commits_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/git/commits{/sha}","comments_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/comments{/number}","issue_comment_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/issues/comments{/number}","contents_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/contents/{+path}","compare_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/merges","archive_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/downloads","issues_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/issues{/number}","pulls_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls{/number}","milestones_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/milestones{/number}","notifications_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/labels{/name}","releases_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/releases{/id}","deployments_url":"https://api.github.com/repos/OpenRCT2/OpenRCT2/deployments","created_at":"2014-04-01T23:32:25Z","updated_at":"2016-07-04T23:45:19Z","pushed_at":"2016-07-05T10:13:31Z","git_url":"git://github.com/OpenRCT2/OpenRCT2.git","ssh_url":"git@github.com:OpenRCT2/OpenRCT2.git","clone_url":"https://github.com/OpenRCT2/OpenRCT2.git","svn_url":"https://github.com/OpenRCT2/OpenRCT2","homepage":"http://openrct2.website","size":66262,"stargazers_count":1919,"watchers_count":1919,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":361,"mirror_url":null,"open_issues_count":563,"forks":361,"open_issues":563,"watchers":1919,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/3985"},"html":{"href":"https://github.com/OpenRCT2/OpenRCT2/pull/3985"},"issue":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/issues/3985"},"comments":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/issues/3985/comments"},"review_comments":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/3985/comments"},"review_comment":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/pulls/3985/commits"},"statuses":{"href":"https://api.github.com/repos/OpenRCT2/OpenRCT2/statuses/0e70c5fabd4aba010964e0eedabbb613f735b264"}}}}
{"actor":{"display_login":"IntelOrca"}}