{"action":"created","comment":{"url":"https://api.github.com/repos/infinitered/bluepotion/pulls/comments/31769491","id":31769491,"diff_hunk":"@@ -0,0 +1,42 @@\n+class PotionDialog\n+\n+  def initialize(options)\n+    # err if missing required options\n+    raise \"Requires an xml_layout!!\" unless options[:xml_layout]\n+    raise \"Cannot have width without height!!\" if options[:width] && !options[:height]\n+    raise \"Cannot have height without width!!\" if options[:height] && !options[:width]\n+    \n+    # Merging defaults    \n+    opts = { \n+      title: false, \n+      show: true\n+    }.merge(options)\n+\n+    built_dialog = build_dialog(opts)\n+\n+    built_dialog.show if opts[:show]\n+\n+    built_dialog\n+  end\n+\n+  def build_dialog(options)\n+    # create dialog\n+    dialog = Potion::Dialog.new(rmq.app.current_activity)\n+","path":"lib/project/potion_dialog/potion_dialog.rb","position":25,"original_position":25,"commit_id":"1ad1571fedb8d26c6386364aab49d7cc39b059bc","original_commit_id":"1ad1571fedb8d26c6386364aab49d7cc39b059bc","user":{"login":"twerth","id":8499,"avatar_url":"https://avatars.githubusercontent.com/u/8499?v=3","gravatar_id":"","url":"https://api.github.com/users/twerth","html_url":"https://github.com/twerth","followers_url":"https://api.github.com/users/twerth/followers","following_url":"https://api.github.com/users/twerth/following{/other_user}","gists_url":"https://api.github.com/users/twerth/gists{/gist_id}","starred_url":"https://api.github.com/users/twerth/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/twerth/subscriptions","organizations_url":"https://api.github.com/users/twerth/orgs","repos_url":"https://api.github.com/users/twerth/repos","events_url":"https://api.github.com/users/twerth/events{/privacy}","received_events_url":"https://api.github.com/users/twerth/received_events","type":"User","site_admin":false},"body":"You can use `find.activity` instead of rmq.app.current_activity","created_at":"2015-06-04T21:49:53Z","updated_at":"2015-06-04T21:49:53Z","html_url":"https://github.com/infinitered/bluepotion/pull/11#discussion_r31769491","pull_request_url":"https://api.github.com/repos/infinitered/bluepotion/pulls/11","_links":{"self":{"href":"https://api.github.com/repos/infinitered/bluepotion/pulls/comments/31769491"},"html":{"href":"https://github.com/infinitered/bluepotion/pull/11#discussion_r31769491"},"pull_request":{"href":"https://api.github.com/repos/infinitered/bluepotion/pulls/11"}}},"pull_request":{"url":"https://api.github.com/repos/infinitered/bluepotion/pulls/11","id":36972703,"html_url":"https://github.com/infinitered/bluepotion/pull/11","diff_url":"https://github.com/infinitered/bluepotion/pull/11.diff","patch_url":"https://github.com/infinitered/bluepotion/pull/11.patch","issue_url":"https://api.github.com/repos/infinitered/bluepotion/issues/11","number":11,"state":"open","locked":false,"title":"Added Potion dialog wrapper","user":{"login":"fvonhoven","id":10098988,"avatar_url":"https://avatars.githubusercontent.com/u/10098988?v=3","gravatar_id":"","url":"https://api.github.com/users/fvonhoven","html_url":"https://github.com/fvonhoven","followers_url":"https://api.github.com/users/fvonhoven/followers","following_url":"https://api.github.com/users/fvonhoven/following{/other_user}","gists_url":"https://api.github.com/users/fvonhoven/gists{/gist_id}","starred_url":"https://api.github.com/users/fvonhoven/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fvonhoven/subscriptions","organizations_url":"https://api.github.com/users/fvonhoven/orgs","repos_url":"https://api.github.com/users/fvonhoven/repos","events_url":"https://api.github.com/users/fvonhoven/events{/privacy}","received_events_url":"https://api.github.com/users/fvonhoven/received_events","type":"User","site_admin":false},"body":"Hey guys this is what we'll need for an existing client. This adds the ability to implement a customized modal in BP!\r\n\r\n![screen shot 2015-06-04 at 3 04 18 pm](https://cloud.githubusercontent.com/assets/10098988/7993339/19b3c358-0acb-11e5-9c1b-464971006fcc.png)\r\n\r\n\r\nMany thanks @GantMan !!!\r\n\r\n@jamonholmgren @skellock @darinwilson this is necessary for many screens in FP.\r\n","created_at":"2015-06-04T20:06:41Z","updated_at":"2015-06-04T21:49:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5f51688e519e7e92258f8e726f0e5cfca8770abe","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/infinitered/bluepotion/pulls/11/commits","review_comments_url":"https://api.github.com/repos/infinitered/bluepotion/pulls/11/comments","review_comment_url":"https://api.github.com/repos/infinitered/bluepotion/pulls/comments{/number}","comments_url":"https://api.github.com/repos/infinitered/bluepotion/issues/11/comments","statuses_url":"https://api.github.com/repos/infinitered/bluepotion/statuses/1ad1571fedb8d26c6386364aab49d7cc39b059bc","head":{"label":"infinitered:potion_dialog","ref":"potion_dialog","sha":"1ad1571fedb8d26c6386364aab49d7cc39b059bc","user":{"login":"infinitered","id":3902527,"avatar_url":"https://avatars.githubusercontent.com/u/3902527?v=3","gravatar_id":"","url":"https://api.github.com/users/infinitered","html_url":"https://github.com/infinitered","followers_url":"https://api.github.com/users/infinitered/followers","following_url":"https://api.github.com/users/infinitered/following{/other_user}","gists_url":"https://api.github.com/users/infinitered/gists{/gist_id}","starred_url":"https://api.github.com/users/infinitered/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/infinitered/subscriptions","organizations_url":"https://api.github.com/users/infinitered/orgs","repos_url":"https://api.github.com/users/infinitered/repos","events_url":"https://api.github.com/users/infinitered/events{/privacy}","received_events_url":"https://api.github.com/users/infinitered/received_events","type":"Organization","site_admin":false},"repo":{"id":34918811,"name":"bluepotion","full_name":"infinitered/bluepotion","owner":{"login":"infinitered","id":3902527,"avatar_url":"https://avatars.githubusercontent.com/u/3902527?v=3","gravatar_id":"","url":"https://api.github.com/users/infinitered","html_url":"https://github.com/infinitered","followers_url":"https://api.github.com/users/infinitered/followers","following_url":"https://api.github.com/users/infinitered/following{/other_user}","gists_url":"https://api.github.com/users/infinitered/gists{/gist_id}","starred_url":"https://api.github.com/users/infinitered/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/infinitered/subscriptions","organizations_url":"https://api.github.com/users/infinitered/orgs","repos_url":"https://api.github.com/users/infinitered/repos","events_url":"https://api.github.com/users/infinitered/events{/privacy}","received_events_url":"https://api.github.com/users/infinitered/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/infinitered/bluepotion","description":"Like RedPotion, but for Android","fork":false,"url":"https://api.github.com/repos/infinitered/bluepotion","forks_url":"https://api.github.com/repos/infinitered/bluepotion/forks","keys_url":"https://api.github.com/repos/infinitered/bluepotion/keys{/key_id}","collaborators_url":"https://api.github.com/repos/infinitered/bluepotion/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/infinitered/bluepotion/teams","hooks_url":"https://api.github.com/repos/infinitered/bluepotion/hooks","issue_events_url":"https://api.github.com/repos/infinitered/bluepotion/issues/events{/number}","events_url":"https://api.github.com/repos/infinitered/bluepotion/events","assignees_url":"https://api.github.com/repos/infinitered/bluepotion/assignees{/user}","branches_url":"https://api.github.com/repos/infinitered/bluepotion/branches{/branch}","tags_url":"https://api.github.com/repos/infinitered/bluepotion/tags","blobs_url":"https://api.github.com/repos/infinitered/bluepotion/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/infinitered/bluepotion/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/infinitered/bluepotion/git/refs{/sha}","trees_url":"https://api.github.com/repos/infinitered/bluepotion/git/trees{/sha}","statuses_url":"https://api.github.com/repos/infinitered/bluepotion/statuses/{sha}","languages_url":"https://api.github.com/repos/infinitered/bluepotion/languages","stargazers_url":"https://api.github.com/repos/infinitered/bluepotion/stargazers","contributors_url":"https://api.github.com/repos/infinitered/bluepotion/contributors","subscribers_url":"https://api.github.com/repos/infinitered/bluepotion/subscribers","subscription_url":"https://api.github.com/repos/infinitered/bluepotion/subscription","commits_url":"https://api.github.com/repos/infinitered/bluepotion/commits{/sha}","git_commits_url":"https://api.github.com/repos/infinitered/bluepotion/git/commits{/sha}","comments_url":"https://api.github.com/repos/infinitered/bluepotion/comments{/number}","issue_comment_url":"https://api.github.com/repos/infinitered/bluepotion/issues/comments{/number}","contents_url":"https://api.github.com/repos/infinitered/bluepotion/contents/{+path}","compare_url":"https://api.github.com/repos/infinitered/bluepotion/compare/{base}...{head}","merges_url":"https://api.github.com/repos/infinitered/bluepotion/merges","archive_url":"https://api.github.com/repos/infinitered/bluepotion/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/infinitered/bluepotion/downloads","issues_url":"https://api.github.com/repos/infinitered/bluepotion/issues{/number}","pulls_url":"https://api.github.com/repos/infinitered/bluepotion/pulls{/number}","milestones_url":"https://api.github.com/repos/infinitered/bluepotion/milestones{/number}","notifications_url":"https://api.github.com/repos/infinitered/bluepotion/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/infinitered/bluepotion/labels{/name}","releases_url":"https://api.github.com/repos/infinitered/bluepotion/releases{/id}","created_at":"2015-05-01T19:02:32Z","updated_at":"2015-06-04T07:11:28Z","pushed_at":"2015-06-04T21:44:51Z","git_url":"git://github.com/infinitered/bluepotion.git","ssh_url":"git@github.com:infinitered/bluepotion.git","clone_url":"https://github.com/infinitered/bluepotion.git","svn_url":"https://github.com/infinitered/bluepotion","homepage":"","size":700,"stargazers_count":21,"watchers_count":21,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":21,"default_branch":"master"}},"base":{"label":"infinitered:master","ref":"master","sha":"c9992ab99e02e42266fe0de43b78f80f89f3b0da","user":{"login":"infinitered","id":3902527,"avatar_url":"https://avatars.githubusercontent.com/u/3902527?v=3","gravatar_id":"","url":"https://api.github.com/users/infinitered","html_url":"https://github.com/infinitered","followers_url":"https://api.github.com/users/infinitered/followers","following_url":"https://api.github.com/users/infinitered/following{/other_user}","gists_url":"https://api.github.com/users/infinitered/gists{/gist_id}","starred_url":"https://api.github.com/users/infinitered/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/infinitered/subscriptions","organizations_url":"https://api.github.com/users/infinitered/orgs","repos_url":"https://api.github.com/users/infinitered/repos","events_url":"https://api.github.com/users/infinitered/events{/privacy}","received_events_url":"https://api.github.com/users/infinitered/received_events","type":"Organization","site_admin":false},"repo":{"id":34918811,"name":"bluepotion","full_name":"infinitered/bluepotion","owner":{"login":"infinitered","id":3902527,"avatar_url":"https://avatars.githubusercontent.com/u/3902527?v=3","gravatar_id":"","url":"https://api.github.com/users/infinitered","html_url":"https://github.com/infinitered","followers_url":"https://api.github.com/users/infinitered/followers","following_url":"https://api.github.com/users/infinitered/following{/other_user}","gists_url":"https://api.github.com/users/infinitered/gists{/gist_id}","starred_url":"https://api.github.com/users/infinitered/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/infinitered/subscriptions","organizations_url":"https://api.github.com/users/infinitered/orgs","repos_url":"https://api.github.com/users/infinitered/repos","events_url":"https://api.github.com/users/infinitered/events{/privacy}","received_events_url":"https://api.github.com/users/infinitered/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/infinitered/bluepotion","description":"Like RedPotion, but for Android","fork":false,"url":"https://api.github.com/repos/infinitered/bluepotion","forks_url":"https://api.github.com/repos/infinitered/bluepotion/forks","keys_url":"https://api.github.com/repos/infinitered/bluepotion/keys{/key_id}","collaborators_url":"https://api.github.com/repos/infinitered/bluepotion/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/infinitered/bluepotion/teams","hooks_url":"https://api.github.com/repos/infinitered/bluepotion/hooks","issue_events_url":"https://api.github.com/repos/infinitered/bluepotion/issues/events{/number}","events_url":"https://api.github.com/repos/infinitered/bluepotion/events","assignees_url":"https://api.github.com/repos/infinitered/bluepotion/assignees{/user}","branches_url":"https://api.github.com/repos/infinitered/bluepotion/branches{/branch}","tags_url":"https://api.github.com/repos/infinitered/bluepotion/tags","blobs_url":"https://api.github.com/repos/infinitered/bluepotion/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/infinitered/bluepotion/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/infinitered/bluepotion/git/refs{/sha}","trees_url":"https://api.github.com/repos/infinitered/bluepotion/git/trees{/sha}","statuses_url":"https://api.github.com/repos/infinitered/bluepotion/statuses/{sha}","languages_url":"https://api.github.com/repos/infinitered/bluepotion/languages","stargazers_url":"https://api.github.com/repos/infinitered/bluepotion/stargazers","contributors_url":"https://api.github.com/repos/infinitered/bluepotion/contributors","subscribers_url":"https://api.github.com/repos/infinitered/bluepotion/subscribers","subscription_url":"https://api.github.com/repos/infinitered/bluepotion/subscription","commits_url":"https://api.github.com/repos/infinitered/bluepotion/commits{/sha}","git_commits_url":"https://api.github.com/repos/infinitered/bluepotion/git/commits{/sha}","comments_url":"https://api.github.com/repos/infinitered/bluepotion/comments{/number}","issue_comment_url":"https://api.github.com/repos/infinitered/bluepotion/issues/comments{/number}","contents_url":"https://api.github.com/repos/infinitered/bluepotion/contents/{+path}","compare_url":"https://api.github.com/repos/infinitered/bluepotion/compare/{base}...{head}","merges_url":"https://api.github.com/repos/infinitered/bluepotion/merges","archive_url":"https://api.github.com/repos/infinitered/bluepotion/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/infinitered/bluepotion/downloads","issues_url":"https://api.github.com/repos/infinitered/bluepotion/issues{/number}","pulls_url":"https://api.github.com/repos/infinitered/bluepotion/pulls{/number}","milestones_url":"https://api.github.com/repos/infinitered/bluepotion/milestones{/number}","notifications_url":"https://api.github.com/repos/infinitered/bluepotion/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/infinitered/bluepotion/labels{/name}","releases_url":"https://api.github.com/repos/infinitered/bluepotion/releases{/id}","created_at":"2015-05-01T19:02:32Z","updated_at":"2015-06-04T07:11:28Z","pushed_at":"2015-06-04T21:44:51Z","git_url":"git://github.com/infinitered/bluepotion.git","ssh_url":"git@github.com:infinitered/bluepotion.git","clone_url":"https://github.com/infinitered/bluepotion.git","svn_url":"https://github.com/infinitered/bluepotion","homepage":"","size":700,"stargazers_count":21,"watchers_count":21,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":2,"forks":0,"open_issues":2,"watchers":21,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/infinitered/bluepotion/pulls/11"},"html":{"href":"https://github.com/infinitered/bluepotion/pull/11"},"issue":{"href":"https://api.github.com/repos/infinitered/bluepotion/issues/11"},"comments":{"href":"https://api.github.com/repos/infinitered/bluepotion/issues/11/comments"},"review_comments":{"href":"https://api.github.com/repos/infinitered/bluepotion/pulls/11/comments"},"review_comment":{"href":"https://api.github.com/repos/infinitered/bluepotion/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/infinitered/bluepotion/pulls/11/commits"},"statuses":{"href":"https://api.github.com/repos/infinitered/bluepotion/statuses/1ad1571fedb8d26c6386364aab49d7cc39b059bc"}}}}