{"action":"created","comment":{"url":"https://api.github.com/repos/gornostal/ulauncher/pulls/comments/25622669","id":25622669,"diff_hunk":"@@ -0,0 +1,115 @@\n+from threading import Thread\n+from ulauncher_lib.ulauncherconfig import get_data_file\n+from gi.repository import Gtk, Gio, GdkPixbuf\n+from ulauncher_lib.helpers.lru_cache import lru_cache\n+import logging\n+\n+\n+icon_theme = Gtk.IconTheme.get_default()\n+logger = logging.getLogger(__name__)\n+\n+\n+@lru_cache(maxsize=50)\n+def load_icon(src, size):\n+    \"\"\"\n+    Return Pixbuf instance\n+    \"\"\"\n+    return GdkPixbuf.Pixbuf.new_from_file_at_size(src, size, size)\n+\n+\n+class IconLoader(Thread):\n+    \"\"\"\n+    Loads icons asynchronously\n+\n+    Usage:\n+        iconLoader = IconLoader.load(src, lambda pixbuf: set_from_pixbuf(pixbuf))\n+        if not iconLoader.is_loaded:\n+            set_from_pixbuf(iconLoader.icon_loading)\n+\n+    \"\"\"\n+\n+    # public","path":"ulauncher/results/IconLoader.py","position":31,"original_position":31,"commit_id":"95314c0132766ba92b3a4b3437916c87b127a6fb","original_commit_id":"95314c0132766ba92b3a4b3437916c87b127a6fb","user":{"login":"yatsenko","id":877016,"avatar_url":"https://avatars.githubusercontent.com/u/877016?v=3","gravatar_id":"","url":"https://api.github.com/users/yatsenko","html_url":"https://github.com/yatsenko","followers_url":"https://api.github.com/users/yatsenko/followers","following_url":"https://api.github.com/users/yatsenko/following{/other_user}","gists_url":"https://api.github.com/users/yatsenko/gists{/gist_id}","starred_url":"https://api.github.com/users/yatsenko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yatsenko/subscriptions","organizations_url":"https://api.github.com/users/yatsenko/orgs","repos_url":"https://api.github.com/users/yatsenko/repos","events_url":"https://api.github.com/users/yatsenko/events{/privacy}","received_events_url":"https://api.github.com/users/yatsenko/received_events","type":"User","site_admin":false},"body":"Why did you add such comments as \"public\" and \"private\" properties and didn't use native python way of define private properties ( __private_property ).\r\nAnyway, it's not good practice to use public properties, better to use private properties + setters, getters. Does it make sence?","created_at":"2015-03-02T18:20:10Z","updated_at":"2015-03-02T18:20:10Z","html_url":"https://github.com/gornostal/ulauncher/pull/30#discussion_r25622669","pull_request_url":"https://api.github.com/repos/gornostal/ulauncher/pulls/30","_links":{"self":{"href":"https://api.github.com/repos/gornostal/ulauncher/pulls/comments/25622669"},"html":{"href":"https://github.com/gornostal/ulauncher/pull/30#discussion_r25622669"},"pull_request":{"href":"https://api.github.com/repos/gornostal/ulauncher/pulls/30"}}},"pull_request":{"url":"https://api.github.com/repos/gornostal/ulauncher/pulls/30","id":30246918,"html_url":"https://github.com/gornostal/ulauncher/pull/30","diff_url":"https://github.com/gornostal/ulauncher/pull/30.diff","patch_url":"https://github.com/gornostal/ulauncher/pull/30.patch","issue_url":"https://api.github.com/repos/gornostal/ulauncher/issues/30","number":30,"state":"open","locked":false,"title":"Fixed issue #1 - load images asynchronously","user":{"login":"gornostal","id":1202543,"avatar_url":"https://avatars.githubusercontent.com/u/1202543?v=3","gravatar_id":"","url":"https://api.github.com/users/gornostal","html_url":"https://github.com/gornostal","followers_url":"https://api.github.com/users/gornostal/followers","following_url":"https://api.github.com/users/gornostal/following{/other_user}","gists_url":"https://api.github.com/users/gornostal/gists{/gist_id}","starred_url":"https://api.github.com/users/gornostal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gornostal/subscriptions","organizations_url":"https://api.github.com/users/gornostal/orgs","repos_url":"https://api.github.com/users/gornostal/repos","events_url":"https://api.github.com/users/gornostal/events{/privacy}","received_events_url":"https://api.github.com/users/gornostal/received_events","type":"User","site_admin":false},"body":"#1 ","created_at":"2015-03-01T19:17:45Z","updated_at":"2015-03-02T18:20:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"bcc2ba2af186c618727659c04f5a516f07b55679","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/gornostal/ulauncher/pulls/30/commits","review_comments_url":"https://api.github.com/repos/gornostal/ulauncher/pulls/30/comments","review_comment_url":"https://api.github.com/repos/gornostal/ulauncher/pulls/comments{/number}","comments_url":"https://api.github.com/repos/gornostal/ulauncher/issues/30/comments","statuses_url":"https://api.github.com/repos/gornostal/ulauncher/statuses/95314c0132766ba92b3a4b3437916c87b127a6fb","head":{"label":"gornostal:issue-1","ref":"issue-1","sha":"95314c0132766ba92b3a4b3437916c87b127a6fb","user":{"login":"gornostal","id":1202543,"avatar_url":"https://avatars.githubusercontent.com/u/1202543?v=3","gravatar_id":"","url":"https://api.github.com/users/gornostal","html_url":"https://github.com/gornostal","followers_url":"https://api.github.com/users/gornostal/followers","following_url":"https://api.github.com/users/gornostal/following{/other_user}","gists_url":"https://api.github.com/users/gornostal/gists{/gist_id}","starred_url":"https://api.github.com/users/gornostal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gornostal/subscriptions","organizations_url":"https://api.github.com/users/gornostal/orgs","repos_url":"https://api.github.com/users/gornostal/repos","events_url":"https://api.github.com/users/gornostal/events{/privacy}","received_events_url":"https://api.github.com/users/gornostal/received_events","type":"User","site_admin":false},"repo":{"id":26630558,"name":"ulauncher","full_name":"gornostal/ulauncher","owner":{"login":"gornostal","id":1202543,"avatar_url":"https://avatars.githubusercontent.com/u/1202543?v=3","gravatar_id":"","url":"https://api.github.com/users/gornostal","html_url":"https://github.com/gornostal","followers_url":"https://api.github.com/users/gornostal/followers","following_url":"https://api.github.com/users/gornostal/following{/other_user}","gists_url":"https://api.github.com/users/gornostal/gists{/gist_id}","starred_url":"https://api.github.com/users/gornostal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gornostal/subscriptions","organizations_url":"https://api.github.com/users/gornostal/orgs","repos_url":"https://api.github.com/users/gornostal/repos","events_url":"https://api.github.com/users/gornostal/events{/privacy}","received_events_url":"https://api.github.com/users/gornostal/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/gornostal/ulauncher","description":"","fork":false,"url":"https://api.github.com/repos/gornostal/ulauncher","forks_url":"https://api.github.com/repos/gornostal/ulauncher/forks","keys_url":"https://api.github.com/repos/gornostal/ulauncher/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gornostal/ulauncher/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gornostal/ulauncher/teams","hooks_url":"https://api.github.com/repos/gornostal/ulauncher/hooks","issue_events_url":"https://api.github.com/repos/gornostal/ulauncher/issues/events{/number}","events_url":"https://api.github.com/repos/gornostal/ulauncher/events","assignees_url":"https://api.github.com/repos/gornostal/ulauncher/assignees{/user}","branches_url":"https://api.github.com/repos/gornostal/ulauncher/branches{/branch}","tags_url":"https://api.github.com/repos/gornostal/ulauncher/tags","blobs_url":"https://api.github.com/repos/gornostal/ulauncher/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gornostal/ulauncher/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gornostal/ulauncher/git/refs{/sha}","trees_url":"https://api.github.com/repos/gornostal/ulauncher/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gornostal/ulauncher/statuses/{sha}","languages_url":"https://api.github.com/repos/gornostal/ulauncher/languages","stargazers_url":"https://api.github.com/repos/gornostal/ulauncher/stargazers","contributors_url":"https://api.github.com/repos/gornostal/ulauncher/contributors","subscribers_url":"https://api.github.com/repos/gornostal/ulauncher/subscribers","subscription_url":"https://api.github.com/repos/gornostal/ulauncher/subscription","commits_url":"https://api.github.com/repos/gornostal/ulauncher/commits{/sha}","git_commits_url":"https://api.github.com/repos/gornostal/ulauncher/git/commits{/sha}","comments_url":"https://api.github.com/repos/gornostal/ulauncher/comments{/number}","issue_comment_url":"https://api.github.com/repos/gornostal/ulauncher/issues/comments{/number}","contents_url":"https://api.github.com/repos/gornostal/ulauncher/contents/{+path}","compare_url":"https://api.github.com/repos/gornostal/ulauncher/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gornostal/ulauncher/merges","archive_url":"https://api.github.com/repos/gornostal/ulauncher/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gornostal/ulauncher/downloads","issues_url":"https://api.github.com/repos/gornostal/ulauncher/issues{/number}","pulls_url":"https://api.github.com/repos/gornostal/ulauncher/pulls{/number}","milestones_url":"https://api.github.com/repos/gornostal/ulauncher/milestones{/number}","notifications_url":"https://api.github.com/repos/gornostal/ulauncher/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gornostal/ulauncher/labels{/name}","releases_url":"https://api.github.com/repos/gornostal/ulauncher/releases{/id}","created_at":"2014-11-14T09:02:19Z","updated_at":"2014-12-14T18:51:32Z","pushed_at":"2015-03-01T20:47:58Z","git_url":"git://github.com/gornostal/ulauncher.git","ssh_url":"git@github.com:gornostal/ulauncher.git","clone_url":"https://github.com/gornostal/ulauncher.git","svn_url":"https://github.com/gornostal/ulauncher","homepage":null,"size":528,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":18,"forks":0,"open_issues":18,"watchers":0,"default_branch":"master"}},"base":{"label":"gornostal:dev","ref":"dev","sha":"816e092221b6ef25ed2711a66d832108b3a9c8af","user":{"login":"gornostal","id":1202543,"avatar_url":"https://avatars.githubusercontent.com/u/1202543?v=3","gravatar_id":"","url":"https://api.github.com/users/gornostal","html_url":"https://github.com/gornostal","followers_url":"https://api.github.com/users/gornostal/followers","following_url":"https://api.github.com/users/gornostal/following{/other_user}","gists_url":"https://api.github.com/users/gornostal/gists{/gist_id}","starred_url":"https://api.github.com/users/gornostal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gornostal/subscriptions","organizations_url":"https://api.github.com/users/gornostal/orgs","repos_url":"https://api.github.com/users/gornostal/repos","events_url":"https://api.github.com/users/gornostal/events{/privacy}","received_events_url":"https://api.github.com/users/gornostal/received_events","type":"User","site_admin":false},"repo":{"id":26630558,"name":"ulauncher","full_name":"gornostal/ulauncher","owner":{"login":"gornostal","id":1202543,"avatar_url":"https://avatars.githubusercontent.com/u/1202543?v=3","gravatar_id":"","url":"https://api.github.com/users/gornostal","html_url":"https://github.com/gornostal","followers_url":"https://api.github.com/users/gornostal/followers","following_url":"https://api.github.com/users/gornostal/following{/other_user}","gists_url":"https://api.github.com/users/gornostal/gists{/gist_id}","starred_url":"https://api.github.com/users/gornostal/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gornostal/subscriptions","organizations_url":"https://api.github.com/users/gornostal/orgs","repos_url":"https://api.github.com/users/gornostal/repos","events_url":"https://api.github.com/users/gornostal/events{/privacy}","received_events_url":"https://api.github.com/users/gornostal/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/gornostal/ulauncher","description":"","fork":false,"url":"https://api.github.com/repos/gornostal/ulauncher","forks_url":"https://api.github.com/repos/gornostal/ulauncher/forks","keys_url":"https://api.github.com/repos/gornostal/ulauncher/keys{/key_id}","collaborators_url":"https://api.github.com/repos/gornostal/ulauncher/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/gornostal/ulauncher/teams","hooks_url":"https://api.github.com/repos/gornostal/ulauncher/hooks","issue_events_url":"https://api.github.com/repos/gornostal/ulauncher/issues/events{/number}","events_url":"https://api.github.com/repos/gornostal/ulauncher/events","assignees_url":"https://api.github.com/repos/gornostal/ulauncher/assignees{/user}","branches_url":"https://api.github.com/repos/gornostal/ulauncher/branches{/branch}","tags_url":"https://api.github.com/repos/gornostal/ulauncher/tags","blobs_url":"https://api.github.com/repos/gornostal/ulauncher/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/gornostal/ulauncher/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/gornostal/ulauncher/git/refs{/sha}","trees_url":"https://api.github.com/repos/gornostal/ulauncher/git/trees{/sha}","statuses_url":"https://api.github.com/repos/gornostal/ulauncher/statuses/{sha}","languages_url":"https://api.github.com/repos/gornostal/ulauncher/languages","stargazers_url":"https://api.github.com/repos/gornostal/ulauncher/stargazers","contributors_url":"https://api.github.com/repos/gornostal/ulauncher/contributors","subscribers_url":"https://api.github.com/repos/gornostal/ulauncher/subscribers","subscription_url":"https://api.github.com/repos/gornostal/ulauncher/subscription","commits_url":"https://api.github.com/repos/gornostal/ulauncher/commits{/sha}","git_commits_url":"https://api.github.com/repos/gornostal/ulauncher/git/commits{/sha}","comments_url":"https://api.github.com/repos/gornostal/ulauncher/comments{/number}","issue_comment_url":"https://api.github.com/repos/gornostal/ulauncher/issues/comments{/number}","contents_url":"https://api.github.com/repos/gornostal/ulauncher/contents/{+path}","compare_url":"https://api.github.com/repos/gornostal/ulauncher/compare/{base}...{head}","merges_url":"https://api.github.com/repos/gornostal/ulauncher/merges","archive_url":"https://api.github.com/repos/gornostal/ulauncher/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/gornostal/ulauncher/downloads","issues_url":"https://api.github.com/repos/gornostal/ulauncher/issues{/number}","pulls_url":"https://api.github.com/repos/gornostal/ulauncher/pulls{/number}","milestones_url":"https://api.github.com/repos/gornostal/ulauncher/milestones{/number}","notifications_url":"https://api.github.com/repos/gornostal/ulauncher/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/gornostal/ulauncher/labels{/name}","releases_url":"https://api.github.com/repos/gornostal/ulauncher/releases{/id}","created_at":"2014-11-14T09:02:19Z","updated_at":"2014-12-14T18:51:32Z","pushed_at":"2015-03-01T20:47:58Z","git_url":"git://github.com/gornostal/ulauncher.git","ssh_url":"git@github.com:gornostal/ulauncher.git","clone_url":"https://github.com/gornostal/ulauncher.git","svn_url":"https://github.com/gornostal/ulauncher","homepage":null,"size":528,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":18,"forks":0,"open_issues":18,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/gornostal/ulauncher/pulls/30"},"html":{"href":"https://github.com/gornostal/ulauncher/pull/30"},"issue":{"href":"https://api.github.com/repos/gornostal/ulauncher/issues/30"},"comments":{"href":"https://api.github.com/repos/gornostal/ulauncher/issues/30/comments"},"review_comments":{"href":"https://api.github.com/repos/gornostal/ulauncher/pulls/30/comments"},"review_comment":{"href":"https://api.github.com/repos/gornostal/ulauncher/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/gornostal/ulauncher/pulls/30/commits"},"statuses":{"href":"https://api.github.com/repos/gornostal/ulauncher/statuses/95314c0132766ba92b3a4b3437916c87b127a6fb"}}}}