GitHub PullRequestReviewCommentEvent at 2014-12-06 21:14:27
Repository: tiled
Actor: bjorn
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/bjorn/tiled/pulls/comments/21419173","id":21419173,"diff_hunk":"@@ -887,10 +947,29 @@ void PropertyBrowser::updateCustomProperties()\n                                                      it.key(),\n                                                      mCustomPropertiesGroup);\n         property->setValue(it.value());\n+        updatePropertyColor(property);\n     }\n \n     mUpdating = false;\n }\n \n+// If there are other objects selected check if their properties are equal. If not give them a gray color.\n+void PropertyBrowser::updatePropertyColor(QtProperty *property)\n+{\n+    const QList<Object*> &currentObjects = mMapDocument->currentObjects();\n+    if (currentObjects.size() > 1) {","path":"src/tiled/propertybrowser.cpp","position":189,"original_position":189,"commit_id":"d34cfe01bfcd0ae539f1edf529095b2c70dfba52","original_commit_id":"d34cfe01bfcd0ae539f1edf529095b2c70dfba52","user":{"login":"bjorn","id":531764,"avatar_url":"https://avatars.githubusercontent.com/u/531764?v=3","gravatar_id":"","url":"https://api.github.com/users/bjorn","html_url":"https://github.com/bjorn","followers_url":"https://api.github.com/users/bjorn/followers","following_url":"https://api.github.com/users/bjorn/following{/other_user}","gists_url":"https://api.github.com/users/bjorn/gists{/gist_id}","starred_url":"https://api.github.com/users/bjorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bjorn/subscriptions","organizations_url":"https://api.github.com/users/bjorn/orgs","repos_url":"https://api.github.com/users/bjorn/repos","events_url":"https://api.github.com/users/bjorn/events{/privacy}","received_events_url":"https://api.github.com/users/bjorn/received_events","type":"User","site_admin":false},"body":"This check should just be removed here too.","created_at":"2014-12-06T21:14:27Z","updated_at":"2014-12-06T21:14:27Z","html_url":"https://github.com/bjorn/tiled/pull/779#discussion_r21419173","pull_request_url":"https://api.github.com/repos/bjorn/tiled/pulls/779","_links":{"self":{"href":"https://api.github.com/repos/bjorn/tiled/pulls/comments/21419173"},"html":{"href":"https://github.com/bjorn/tiled/pull/779#discussion_r21419173"},"pull_request":{"href":"https://api.github.com/repos/bjorn/tiled/pulls/779"}}},"pull_request":{"url":"https://api.github.com/repos/bjorn/tiled/pulls/779","id":22044550,"html_url":"https://github.com/bjorn/tiled/pull/779","diff_url":"https://github.com/bjorn/tiled/pull/779.diff","patch_url":"https://github.com/bjorn/tiled/pull/779.patch","issue_url":"https://api.github.com/repos/bjorn/tiled/issues/779","number":779,"state":"open","locked":false,"title":"Visual feedback for multiple object properties","user":{"login":"parkm","id":1958968,"avatar_url":"https://avatars.githubusercontent.com/u/1958968?v=3","gravatar_id":"","url":"https://api.github.com/users/parkm","html_url":"https://github.com/parkm","followers_url":"https://api.github.com/users/parkm/followers","following_url":"https://api.github.com/users/parkm/following{/other_user}","gists_url":"https://api.github.com/users/parkm/gists{/gist_id}","starred_url":"https://api.github.com/users/parkm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/parkm/subscriptions","organizations_url":"https://api.github.com/users/parkm/orgs","repos_url":"https://api.github.com/users/parkm/repos","events_url":"https://api.github.com/users/parkm/events{/privacy}","received_events_url":"https://api.github.com/users/parkm/received_events","type":"User","site_admin":false},"body":"Here's my implementation for some visual feedback when manipulating multiple object properties.\r\n\r\n```\r\nobj1:\r\n    a = 1\r\n\r\nobj2:\r\n    a = 2\r\n```\r\n\r\nHaving both of these objects in your selection will result in having the current objects 'a' property being grayed out but still allowed to be changed.\r\n\r\n```\r\nobj1: <- current object\r\n    a = 0\r\nobj2:\r\n    b = 1\r\n```\r\n\r\nHaving both of these objects in your selection will create a 'fake' property 'b' in obj1. This fake property will be grayed out and will be removed after changing the selection if the fake property was not set.\r\n\r\nThis request is mostly for feedback regarding the implementation at the moment. In order to get this to work I had to modify the qtpropertybrowser code to support arbitrary colors. But I'm not sure if that is the best solution. I don't know how Qt handles things like color schemes if that even is an issue.\r\n","created_at":"2014-10-01T00:09:00Z","updated_at":"2014-12-06T21:14:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"17176fa9a2fbd3aabf54743cf4a31d3895a4364d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/bjorn/tiled/pulls/779/commits","review_comments_url":"https://api.github.com/repos/bjorn/tiled/pulls/779/comments","review_comment_url":"https://api.github.com/repos/bjorn/tiled/pulls/comments/{number}","comments_url":"https://api.github.com/repos/bjorn/tiled/issues/779/comments","statuses_url":"https://api.github.com/repos/bjorn/tiled/statuses/d34cfe01bfcd0ae539f1edf529095b2c70dfba52","head":{"label":"parkm:propertyVisuals","ref":"propertyVisuals","sha":"d34cfe01bfcd0ae539f1edf529095b2c70dfba52","user":{"login":"parkm","id":1958968,"avatar_url":"https://avatars.githubusercontent.com/u/1958968?v=3","gravatar_id":"","url":"https://api.github.com/users/parkm","html_url":"https://github.com/parkm","followers_url":"https://api.github.com/users/parkm/followers","following_url":"https://api.github.com/users/parkm/following{/other_user}","gists_url":"https://api.github.com/users/parkm/gists{/gist_id}","starred_url":"https://api.github.com/users/parkm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/parkm/subscriptions","organizations_url":"https://api.github.com/users/parkm/orgs","repos_url":"https://api.github.com/users/parkm/repos","events_url":"https://api.github.com/users/parkm/events{/privacy}","received_events_url":"https://api.github.com/users/parkm/received_events","type":"User","site_admin":false},"repo":{"id":15982870,"name":"tiled","full_name":"parkm/tiled","owner":{"login":"parkm","id":1958968,"avatar_url":"https://avatars.githubusercontent.com/u/1958968?v=3","gravatar_id":"","url":"https://api.github.com/users/parkm","html_url":"https://github.com/parkm","followers_url":"https://api.github.com/users/parkm/followers","following_url":"https://api.github.com/users/parkm/following{/other_user}","gists_url":"https://api.github.com/users/parkm/gists{/gist_id}","starred_url":"https://api.github.com/users/parkm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/parkm/subscriptions","organizations_url":"https://api.github.com/users/parkm/orgs","repos_url":"https://api.github.com/users/parkm/repos","events_url":"https://api.github.com/users/parkm/events{/privacy}","received_events_url":"https://api.github.com/users/parkm/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/parkm/tiled","description":"A generic tile map editor","fork":true,"url":"https://api.github.com/repos/parkm/tiled","forks_url":"https://api.github.com/repos/parkm/tiled/forks","keys_url":"https://api.github.com/repos/parkm/tiled/keys{/key_id}","collaborators_url":"https://api.github.com/repos/parkm/tiled/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/parkm/tiled/teams","hooks_url":"https://api.github.com/repos/parkm/tiled/hooks","issue_events_url":"https://api.github.com/repos/parkm/tiled/issues/events{/number}","events_url":"https://api.github.com/repos/parkm/tiled/events","assignees_url":"https://api.github.com/repos/parkm/tiled/assignees{/user}","branches_url":"https://api.github.com/repos/parkm/tiled/branches{/branch}","tags_url":"https://api.github.com/repos/parkm/tiled/tags","blobs_url":"https://api.github.com/repos/parkm/tiled/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/parkm/tiled/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/parkm/tiled/git/refs{/sha}","trees_url":"https://api.github.com/repos/parkm/tiled/git/trees{/sha}","statuses_url":"https://api.github.com/repos/parkm/tiled/statuses/{sha}","languages_url":"https://api.github.com/repos/parkm/tiled/languages","stargazers_url":"https://api.github.com/repos/parkm/tiled/stargazers","contributors_url":"https://api.github.com/repos/parkm/tiled/contributors","subscribers_url":"https://api.github.com/repos/parkm/tiled/subscribers","subscription_url":"https://api.github.com/repos/parkm/tiled/subscription","commits_url":"https://api.github.com/repos/parkm/tiled/commits{/sha}","git_commits_url":"https://api.github.com/repos/parkm/tiled/git/commits{/sha}","comments_url":"https://api.github.com/repos/parkm/tiled/comments{/number}","issue_comment_url":"https://api.github.com/repos/parkm/tiled/issues/comments/{number}","contents_url":"https://api.github.com/repos/parkm/tiled/contents/{+path}","compare_url":"https://api.github.com/repos/parkm/tiled/compare/{base}...{head}","merges_url":"https://api.github.com/repos/parkm/tiled/merges","archive_url":"https://api.github.com/repos/parkm/tiled/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/parkm/tiled/downloads","issues_url":"https://api.github.com/repos/parkm/tiled/issues{/number}","pulls_url":"https://api.github.com/repos/parkm/tiled/pulls{/number}","milestones_url":"https://api.github.com/repos/parkm/tiled/milestones{/number}","notifications_url":"https://api.github.com/repos/parkm/tiled/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/parkm/tiled/labels{/name}","releases_url":"https://api.github.com/repos/parkm/tiled/releases{/id}","created_at":"2014-01-16T22:23:39Z","updated_at":"2014-09-14T02:06:19Z","pushed_at":"2014-12-06T19:11:32Z","git_url":"git://github.com/parkm/tiled.git","ssh_url":"git@github.com:parkm/tiled.git","clone_url":"https://github.com/parkm/tiled.git","svn_url":"https://github.com/parkm/tiled","homepage":"http://mapeditor.org/","size":6828,"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":"master"}},"base":{"label":"bjorn:master","ref":"master","sha":"426c32b4cb95b67e40f19b12d3d9e4e0701cde8f","user":{"login":"bjorn","id":531764,"avatar_url":"https://avatars.githubusercontent.com/u/531764?v=3","gravatar_id":"","url":"https://api.github.com/users/bjorn","html_url":"https://github.com/bjorn","followers_url":"https://api.github.com/users/bjorn/followers","following_url":"https://api.github.com/users/bjorn/following{/other_user}","gists_url":"https://api.github.com/users/bjorn/gists{/gist_id}","starred_url":"https://api.github.com/users/bjorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bjorn/subscriptions","organizations_url":"https://api.github.com/users/bjorn/orgs","repos_url":"https://api.github.com/users/bjorn/repos","events_url":"https://api.github.com/users/bjorn/events{/privacy}","received_events_url":"https://api.github.com/users/bjorn/received_events","type":"User","site_admin":false},"repo":{"id":1418150,"name":"tiled","full_name":"bjorn/tiled","owner":{"login":"bjorn","id":531764,"avatar_url":"https://avatars.githubusercontent.com/u/531764?v=3","gravatar_id":"","url":"https://api.github.com/users/bjorn","html_url":"https://github.com/bjorn","followers_url":"https://api.github.com/users/bjorn/followers","following_url":"https://api.github.com/users/bjorn/following{/other_user}","gists_url":"https://api.github.com/users/bjorn/gists{/gist_id}","starred_url":"https://api.github.com/users/bjorn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bjorn/subscriptions","organizations_url":"https://api.github.com/users/bjorn/orgs","repos_url":"https://api.github.com/users/bjorn/repos","events_url":"https://api.github.com/users/bjorn/events{/privacy}","received_events_url":"https://api.github.com/users/bjorn/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bjorn/tiled","description":"A generic tile map editor","fork":false,"url":"https://api.github.com/repos/bjorn/tiled","forks_url":"https://api.github.com/repos/bjorn/tiled/forks","keys_url":"https://api.github.com/repos/bjorn/tiled/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bjorn/tiled/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bjorn/tiled/teams","hooks_url":"https://api.github.com/repos/bjorn/tiled/hooks","issue_events_url":"https://api.github.com/repos/bjorn/tiled/issues/events{/number}","events_url":"https://api.github.com/repos/bjorn/tiled/events","assignees_url":"https://api.github.com/repos/bjorn/tiled/assignees{/user}","branches_url":"https://api.github.com/repos/bjorn/tiled/branches{/branch}","tags_url":"https://api.github.com/repos/bjorn/tiled/tags","blobs_url":"https://api.github.com/repos/bjorn/tiled/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bjorn/tiled/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bjorn/tiled/git/refs{/sha}","trees_url":"https://api.github.com/repos/bjorn/tiled/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bjorn/tiled/statuses/{sha}","languages_url":"https://api.github.com/repos/bjorn/tiled/languages","stargazers_url":"https://api.github.com/repos/bjorn/tiled/stargazers","contributors_url":"https://api.github.com/repos/bjorn/tiled/contributors","subscribers_url":"https://api.github.com/repos/bjorn/tiled/subscribers","subscription_url":"https://api.github.com/repos/bjorn/tiled/subscription","commits_url":"https://api.github.com/repos/bjorn/tiled/commits{/sha}","git_commits_url":"https://api.github.com/repos/bjorn/tiled/git/commits{/sha}","comments_url":"https://api.github.com/repos/bjorn/tiled/comments{/number}","issue_comment_url":"https://api.github.com/repos/bjorn/tiled/issues/comments/{number}","contents_url":"https://api.github.com/repos/bjorn/tiled/contents/{+path}","compare_url":"https://api.github.com/repos/bjorn/tiled/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bjorn/tiled/merges","archive_url":"https://api.github.com/repos/bjorn/tiled/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bjorn/tiled/downloads","issues_url":"https://api.github.com/repos/bjorn/tiled/issues{/number}","pulls_url":"https://api.github.com/repos/bjorn/tiled/pulls{/number}","milestones_url":"https://api.github.com/repos/bjorn/tiled/milestones{/number}","notifications_url":"https://api.github.com/repos/bjorn/tiled/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bjorn/tiled/labels{/name}","releases_url":"https://api.github.com/repos/bjorn/tiled/releases{/id}","created_at":"2011-02-27T15:18:22Z","updated_at":"2014-12-06T20:20:32Z","pushed_at":"2014-12-06T14:20:38Z","git_url":"git://github.com/bjorn/tiled.git","ssh_url":"git@github.com:bjorn/tiled.git","clone_url":"https://github.com/bjorn/tiled.git","svn_url":"https://github.com/bjorn/tiled","homepage":"http://www.mapeditor.org/","size":20373,"stargazers_count":2573,"watchers_count":2573,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":558,"mirror_url":null,"open_issues_count":239,"forks":558,"open_issues":239,"watchers":2573,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/bjorn/tiled/pulls/779"},"html":{"href":"https://github.com/bjorn/tiled/pull/779"},"issue":{"href":"https://api.github.com/repos/bjorn/tiled/issues/779"},"comments":{"href":"https://api.github.com/repos/bjorn/tiled/issues/779/comments"},"review_comments":{"href":"https://api.github.com/repos/bjorn/tiled/pulls/779/comments"},"review_comment":{"href":"https://api.github.com/repos/bjorn/tiled/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/bjorn/tiled/pulls/779/commits"},"statuses":{"href":"https://api.github.com/repos/bjorn/tiled/statuses/d34cfe01bfcd0ae539f1edf529095b2c70dfba52"}}}}