{"action":"created","comment":{"url":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/comments/178552747","pull_request_review_id":108625964,"id":178552747,"diff_hunk":"@@ -0,0 +1,190 @@\n+//\n+//  Copyright (c) 2018 Open Whisper Systems. All rights reserved.\n+//\n+\n+#import \"OWSBubbleView.h\"\n+#import \"OWSBubbleStrokeView.h\"\n+#import <SignalMessaging/UIView+OWS.h>\n+\n+NS_ASSUME_NONNULL_BEGIN\n+\n+// This approximates the curve of our message bubbles, which makes the animation feel a little smoother.\n+const CGFloat kOWSMessageCellCornerRadius = 17;\n+\n+const CGFloat kBubbleVRounding = kOWSMessageCellCornerRadius;\n+const CGFloat kBubbleHRounding = kOWSMessageCellCornerRadius;\n+const CGFloat kBubbleThornSideInset = 5.f;\n+const CGFloat kBubbleThornVInset = 0;\n+const CGFloat kBubbleTextHInset = 10.f;\n+const CGFloat kBubbleTextVInset = 10.f;\n+\n+@interface OWSBubbleView ()\n+\n+@property (nonatomic) CAShapeLayer *maskLayer;\n+@property (nonatomic) CAShapeLayer *shapeLayer;\n+\n+@end\n+\n+#pragma mark -\n+\n+@implementation OWSBubbleView\n+\n+- (void)setIsOutgoing:(BOOL)isOutgoing\n+{\n+    BOOL didChange = _isOutgoing != isOutgoing;\n+\n+    _isOutgoing = isOutgoing;\n+\n+    if (didChange || !self.shapeLayer) {\n+        [self updateLayers];\n+    }\n+}\n+\n+- (void)setHideTail:(BOOL)hideTail\n+{\n+    BOOL didChange = _hideTail != hideTail;\n+\n+    _hideTail = hideTail;\n+\n+    if (didChange || !self.shapeLayer) {\n+        [self updateLayers];\n+    }\n+}\n+\n+- (void)setIsTruncated:(BOOL)isTruncated\n+{\n+    BOOL didChange = _isTruncated != isTruncated;\n+\n+    _isTruncated = isTruncated;\n+\n+    if (didChange || !self.shapeLayer) {\n+        [self updateLayers];\n+    }\n+}\n+\n+- (void)setFrame:(CGRect)frame\n+{\n+    BOOL didChange = !CGSizeEqualToSize(self.frame.size, frame.size);\n+\n+    [super setFrame:frame];\n+\n+    if (didChange || !self.shapeLayer) {\n+        [self updateLayers];\n+    }\n+\n+    // We need to inform the \"bubble stroke view\" (if any) any time our frame changes.\n+    [self.bubbleStrokeView updateLayers];\n+}\n+\n+- (void)setBounds:(CGRect)bounds\n+{\n+    BOOL didChange = !CGSizeEqualToSize(self.bounds.size, bounds.size);","path":"Signal/src/ViewControllers/ConversationView/Cells/OWSBubbleView.m","position":81,"original_position":81,"commit_id":"f32746164e2224b0aaa9dcee37754ea2da37bd7b","original_commit_id":"f32746164e2224b0aaa9dcee37754ea2da37bd7b","user":{"login":"charlesmchen-signal","id":36971147,"avatar_url":"https://avatars0.githubusercontent.com/u/36971147?v=4","gravatar_id":"","url":"https://api.github.com/users/charlesmchen-signal","html_url":"https://github.com/charlesmchen-signal","followers_url":"https://api.github.com/users/charlesmchen-signal/followers","following_url":"https://api.github.com/users/charlesmchen-signal/following{/other_user}","gists_url":"https://api.github.com/users/charlesmchen-signal/gists{/gist_id}","starred_url":"https://api.github.com/users/charlesmchen-signal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/charlesmchen-signal/subscriptions","organizations_url":"https://api.github.com/users/charlesmchen-signal/orgs","repos_url":"https://api.github.com/users/charlesmchen-signal/repos","events_url":"https://api.github.com/users/charlesmchen-signal/events{/privacy}","received_events_url":"https://api.github.com/users/charlesmchen-signal/received_events","type":"User","site_admin":false},"body":"Ditto.","created_at":"2018-04-02T14:19:30Z","updated_at":"2018-04-02T14:19:30Z","html_url":"https://github.com/signalapp/Signal-iOS/pull/3206#discussion_r178552747","pull_request_url":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/3206","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/comments/178552747"},"html":{"href":"https://github.com/signalapp/Signal-iOS/pull/3206#discussion_r178552747"},"pull_request":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/3206"}},"in_reply_to_id":178306762},"pull_request":{"url":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/3206","id":178393331,"html_url":"https://github.com/signalapp/Signal-iOS/pull/3206","diff_url":"https://github.com/signalapp/Signal-iOS/pull/3206.diff","patch_url":"https://github.com/signalapp/Signal-iOS/pull/3206.patch","issue_url":"https://api.github.com/repos/signalapp/Signal-iOS/issues/3206","number":3206,"state":"open","locked":false,"title":"Charlesmchen/bubble collapse","user":{"login":"charlesmchen-signal","id":36971147,"avatar_url":"https://avatars0.githubusercontent.com/u/36971147?v=4","gravatar_id":"","url":"https://api.github.com/users/charlesmchen-signal","html_url":"https://github.com/charlesmchen-signal","followers_url":"https://api.github.com/users/charlesmchen-signal/followers","following_url":"https://api.github.com/users/charlesmchen-signal/following{/other_user}","gists_url":"https://api.github.com/users/charlesmchen-signal/gists{/gist_id}","starred_url":"https://api.github.com/users/charlesmchen-signal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/charlesmchen-signal/subscriptions","organizations_url":"https://api.github.com/users/charlesmchen-signal/orgs","repos_url":"https://api.github.com/users/charlesmchen-signal/repos","events_url":"https://api.github.com/users/charlesmchen-signal/events{/privacy}","received_events_url":"https://api.github.com/users/charlesmchen-signal/received_events","type":"User","site_admin":false},"body":"PTAL @michaelkirk ","created_at":"2018-03-29T17:32:30Z","updated_at":"2018-04-02T14:19:30Z","closed_at":null,"merged_at":null,"merge_commit_sha":"ae3106142211b1367182048ea3f3da721830db79","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/3206/commits","review_comments_url":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/3206/comments","review_comment_url":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/comments{/number}","comments_url":"https://api.github.com/repos/signalapp/Signal-iOS/issues/3206/comments","statuses_url":"https://api.github.com/repos/signalapp/Signal-iOS/statuses/f32746164e2224b0aaa9dcee37754ea2da37bd7b","head":{"label":"signalapp:charlesmchen/bubbleCollapse","ref":"charlesmchen/bubbleCollapse","sha":"f32746164e2224b0aaa9dcee37754ea2da37bd7b","user":{"login":"signalapp","id":702459,"avatar_url":"https://avatars2.githubusercontent.com/u/702459?v=4","gravatar_id":"","url":"https://api.github.com/users/signalapp","html_url":"https://github.com/signalapp","followers_url":"https://api.github.com/users/signalapp/followers","following_url":"https://api.github.com/users/signalapp/following{/other_user}","gists_url":"https://api.github.com/users/signalapp/gists{/gist_id}","starred_url":"https://api.github.com/users/signalapp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/signalapp/subscriptions","organizations_url":"https://api.github.com/users/signalapp/orgs","repos_url":"https://api.github.com/users/signalapp/repos","events_url":"https://api.github.com/users/signalapp/events{/privacy}","received_events_url":"https://api.github.com/users/signalapp/received_events","type":"Organization","site_admin":false},"repo":{"id":19429698,"name":"Signal-iOS","full_name":"signalapp/Signal-iOS","owner":{"login":"signalapp","id":702459,"avatar_url":"https://avatars2.githubusercontent.com/u/702459?v=4","gravatar_id":"","url":"https://api.github.com/users/signalapp","html_url":"https://github.com/signalapp","followers_url":"https://api.github.com/users/signalapp/followers","following_url":"https://api.github.com/users/signalapp/following{/other_user}","gists_url":"https://api.github.com/users/signalapp/gists{/gist_id}","starred_url":"https://api.github.com/users/signalapp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/signalapp/subscriptions","organizations_url":"https://api.github.com/users/signalapp/orgs","repos_url":"https://api.github.com/users/signalapp/repos","events_url":"https://api.github.com/users/signalapp/events{/privacy}","received_events_url":"https://api.github.com/users/signalapp/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/signalapp/Signal-iOS","description":"A private messenger for iOS.","fork":false,"url":"https://api.github.com/repos/signalapp/Signal-iOS","forks_url":"https://api.github.com/repos/signalapp/Signal-iOS/forks","keys_url":"https://api.github.com/repos/signalapp/Signal-iOS/keys{/key_id}","collaborators_url":"https://api.github.com/repos/signalapp/Signal-iOS/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/signalapp/Signal-iOS/teams","hooks_url":"https://api.github.com/repos/signalapp/Signal-iOS/hooks","issue_events_url":"https://api.github.com/repos/signalapp/Signal-iOS/issues/events{/number}","events_url":"https://api.github.com/repos/signalapp/Signal-iOS/events","assignees_url":"https://api.github.com/repos/signalapp/Signal-iOS/assignees{/user}","branches_url":"https://api.github.com/repos/signalapp/Signal-iOS/branches{/branch}","tags_url":"https://api.github.com/repos/signalapp/Signal-iOS/tags","blobs_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/refs{/sha}","trees_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/trees{/sha}","statuses_url":"https://api.github.com/repos/signalapp/Signal-iOS/statuses/{sha}","languages_url":"https://api.github.com/repos/signalapp/Signal-iOS/languages","stargazers_url":"https://api.github.com/repos/signalapp/Signal-iOS/stargazers","contributors_url":"https://api.github.com/repos/signalapp/Signal-iOS/contributors","subscribers_url":"https://api.github.com/repos/signalapp/Signal-iOS/subscribers","subscription_url":"https://api.github.com/repos/signalapp/Signal-iOS/subscription","commits_url":"https://api.github.com/repos/signalapp/Signal-iOS/commits{/sha}","git_commits_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/commits{/sha}","comments_url":"https://api.github.com/repos/signalapp/Signal-iOS/comments{/number}","issue_comment_url":"https://api.github.com/repos/signalapp/Signal-iOS/issues/comments{/number}","contents_url":"https://api.github.com/repos/signalapp/Signal-iOS/contents/{+path}","compare_url":"https://api.github.com/repos/signalapp/Signal-iOS/compare/{base}...{head}","merges_url":"https://api.github.com/repos/signalapp/Signal-iOS/merges","archive_url":"https://api.github.com/repos/signalapp/Signal-iOS/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/signalapp/Signal-iOS/downloads","issues_url":"https://api.github.com/repos/signalapp/Signal-iOS/issues{/number}","pulls_url":"https://api.github.com/repos/signalapp/Signal-iOS/pulls{/number}","milestones_url":"https://api.github.com/repos/signalapp/Signal-iOS/milestones{/number}","notifications_url":"https://api.github.com/repos/signalapp/Signal-iOS/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/signalapp/Signal-iOS/labels{/name}","releases_url":"https://api.github.com/repos/signalapp/Signal-iOS/releases{/id}","deployments_url":"https://api.github.com/repos/signalapp/Signal-iOS/deployments","created_at":"2014-05-04T15:42:40Z","updated_at":"2018-04-02T13:41:18Z","pushed_at":"2018-04-02T13:41:28Z","git_url":"git://github.com/signalapp/Signal-iOS.git","ssh_url":"git@github.com:signalapp/Signal-iOS.git","clone_url":"https://github.com/signalapp/Signal-iOS.git","svn_url":"https://github.com/signalapp/Signal-iOS","homepage":"https://signal.org","size":464162,"stargazers_count":3302,"watchers_count":3302,"language":"Objective-C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":780,"mirror_url":null,"archived":false,"open_issues_count":377,"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":780,"open_issues":377,"watchers":3302,"default_branch":"master"}},"base":{"label":"signalapp:master","ref":"master","sha":"e793aba047c36a510870065736e7f7c09b69445a","user":{"login":"signalapp","id":702459,"avatar_url":"https://avatars2.githubusercontent.com/u/702459?v=4","gravatar_id":"","url":"https://api.github.com/users/signalapp","html_url":"https://github.com/signalapp","followers_url":"https://api.github.com/users/signalapp/followers","following_url":"https://api.github.com/users/signalapp/following{/other_user}","gists_url":"https://api.github.com/users/signalapp/gists{/gist_id}","starred_url":"https://api.github.com/users/signalapp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/signalapp/subscriptions","organizations_url":"https://api.github.com/users/signalapp/orgs","repos_url":"https://api.github.com/users/signalapp/repos","events_url":"https://api.github.com/users/signalapp/events{/privacy}","received_events_url":"https://api.github.com/users/signalapp/received_events","type":"Organization","site_admin":false},"repo":{"id":19429698,"name":"Signal-iOS","full_name":"signalapp/Signal-iOS","owner":{"login":"signalapp","id":702459,"avatar_url":"https://avatars2.githubusercontent.com/u/702459?v=4","gravatar_id":"","url":"https://api.github.com/users/signalapp","html_url":"https://github.com/signalapp","followers_url":"https://api.github.com/users/signalapp/followers","following_url":"https://api.github.com/users/signalapp/following{/other_user}","gists_url":"https://api.github.com/users/signalapp/gists{/gist_id}","starred_url":"https://api.github.com/users/signalapp/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/signalapp/subscriptions","organizations_url":"https://api.github.com/users/signalapp/orgs","repos_url":"https://api.github.com/users/signalapp/repos","events_url":"https://api.github.com/users/signalapp/events{/privacy}","received_events_url":"https://api.github.com/users/signalapp/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/signalapp/Signal-iOS","description":"A private messenger for iOS.","fork":false,"url":"https://api.github.com/repos/signalapp/Signal-iOS","forks_url":"https://api.github.com/repos/signalapp/Signal-iOS/forks","keys_url":"https://api.github.com/repos/signalapp/Signal-iOS/keys{/key_id}","collaborators_url":"https://api.github.com/repos/signalapp/Signal-iOS/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/signalapp/Signal-iOS/teams","hooks_url":"https://api.github.com/repos/signalapp/Signal-iOS/hooks","issue_events_url":"https://api.github.com/repos/signalapp/Signal-iOS/issues/events{/number}","events_url":"https://api.github.com/repos/signalapp/Signal-iOS/events","assignees_url":"https://api.github.com/repos/signalapp/Signal-iOS/assignees{/user}","branches_url":"https://api.github.com/repos/signalapp/Signal-iOS/branches{/branch}","tags_url":"https://api.github.com/repos/signalapp/Signal-iOS/tags","blobs_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/refs{/sha}","trees_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/trees{/sha}","statuses_url":"https://api.github.com/repos/signalapp/Signal-iOS/statuses/{sha}","languages_url":"https://api.github.com/repos/signalapp/Signal-iOS/languages","stargazers_url":"https://api.github.com/repos/signalapp/Signal-iOS/stargazers","contributors_url":"https://api.github.com/repos/signalapp/Signal-iOS/contributors","subscribers_url":"https://api.github.com/repos/signalapp/Signal-iOS/subscribers","subscription_url":"https://api.github.com/repos/signalapp/Signal-iOS/subscription","commits_url":"https://api.github.com/repos/signalapp/Signal-iOS/commits{/sha}","git_commits_url":"https://api.github.com/repos/signalapp/Signal-iOS/git/commits{/sha}","comments_url":"https://api.github.com/repos/signalapp/Signal-iOS/comments{/number}","issue_comment_url":"https://api.github.com/repos/signalapp/Signal-iOS/issues/comments{/number}","contents_url":"https://api.github.com/repos/signalapp/Signal-iOS/contents/{+path}","compare_url":"https://api.github.com/repos/signalapp/Signal-iOS/compare/{base}...{head}","merges_url":"https://api.github.com/repos/signalapp/Signal-iOS/merges","archive_url":"https://api.github.com/repos/signalapp/Signal-iOS/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/signalapp/Signal-iOS/downloads","issues_url":"https://api.github.com/repos/signalapp/Signal-iOS/issues{/number}","pulls_url":"https://api.github.com/repos/signalapp/Signal-iOS/pulls{/number}","milestones_url":"https://api.github.com/repos/signalapp/Signal-iOS/milestones{/number}","notifications_url":"https://api.github.com/repos/signalapp/Signal-iOS/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/signalapp/Signal-iOS/labels{/name}","releases_url":"https://api.github.com/repos/signalapp/Signal-iOS/releases{/id}","deployments_url":"https://api.github.com/repos/signalapp/Signal-iOS/deployments","created_at":"2014-05-04T15:42:40Z","updated_at":"2018-04-02T13:41:18Z","pushed_at":"2018-04-02T13:41:28Z","git_url":"git://github.com/signalapp/Signal-iOS.git","ssh_url":"git@github.com:signalapp/Signal-iOS.git","clone_url":"https://github.com/signalapp/Signal-iOS.git","svn_url":"https://github.com/signalapp/Signal-iOS","homepage":"https://signal.org","size":464162,"stargazers_count":3302,"watchers_count":3302,"language":"Objective-C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":780,"mirror_url":null,"archived":false,"open_issues_count":377,"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":780,"open_issues":377,"watchers":3302,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/3206"},"html":{"href":"https://github.com/signalapp/Signal-iOS/pull/3206"},"issue":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/issues/3206"},"comments":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/issues/3206/comments"},"review_comments":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/3206/comments"},"review_comment":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/pulls/3206/commits"},"statuses":{"href":"https://api.github.com/repos/signalapp/Signal-iOS/statuses/f32746164e2224b0aaa9dcee37754ea2da37bd7b"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"charlesmchen-signal"}}