Skip to content
Browse files

support user's uploaded avatar; relased 0.1

v0.1b only supported showing gravatar
  • Loading branch information...
1 parent 523fd0f commit 46621fcbee451c66e5706edc604586223a63f04c @ashchan committed Apr 3, 2012
View
11 CHANGELOG
@@ -0,0 +1,11 @@
+== 0.1
+
+2012-04-03
+
+* 增加对加载用户上传头像的支持(之前只支持显示gravatar头像)。
+
+== 0.1b
+
+2012-03-14
+
+原始预览版。
View
1 RubyChinaReader/RCRAppDelegate.m
@@ -67,6 +67,7 @@ - (void)mapObjects {
[userMapping mapAttributes:@"login", @"name", @"location", @"bio", @"tagline", @"website", nil];
[userMapping mapKeyPathsToAttributes:@"github_url", @"githubUrl",
@"gravatar_hash", @"gravatarHash",
+ @"avatar_url", @"avatarUrl",
nil];
[manager.mappingProvider addObjectMapping:userMapping];
View
1 RubyChinaReader/RCRUser.h
@@ -20,6 +20,7 @@ extern NSString *const RCRTopicPropertyNamedGravatar;
@property (strong) NSString *website;
@property (strong) NSString *githubUrl;
@property (strong) NSString *gravatarHash;
+@property (strong) NSString *avatarUrl;
@property (assign) BOOL loadingGravatar;
@property (strong) NSImage *gravatar;
View
5 RubyChinaReader/RCRUser.m
@@ -20,6 +20,7 @@ @implementation RCRUser
@synthesize website;
@synthesize githubUrl;
@synthesize gravatarHash;
+@synthesize avatarUrl;
@synthesize loadingGravatar;
@synthesize gravatar;
@@ -33,6 +34,10 @@ @implementation RCRUser
}
- (NSURL *)gravatarUrl {
+ if (avatarUrl.length > 0) {
+ return [NSURL URLWithString:avatarUrl];
+ }
+
return [NSURL URLWithString:[NSString stringWithFormat:@"http://gravatar.com/avatar/%@.png?s=48", gravatarHash]];
}
View
4 RubyChinaReader/RubyChinaReader-Info.plist
@@ -17,11 +17,11 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
- <string>0.1b</string>
+ <string>0.1</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
- <string>18</string>
+ <string>19</string>
<key>LSApplicationCategoryType</key>
<string>public.app-category.social-networking</string>
<key>LSHasLocalizedDisplayName</key>
View
18 update.xml
@@ -6,15 +6,21 @@
<description>Ruby China Reader Update Feed</description>
<language>en</language>
<item>
- <title>Version 0.1 Beta</title>
+ <title>Version 0.1</title>
<sparkle:minimumSystemVersion>10.7.0</sparkle:minimumSystemVersion>
- <pubDate>Wed, 14 Mar 00:27:00 +0900</pubDate>
- <enclosure url="https://github.com/downloads/ashchan/ruby-china-reader/RubyChina-0.1b.zip"
- sparkle:version="18"
- sparkle:shortVersionString="0.1b"
- length="1218254"
+ <pubDate>Tue, 3 Apr 00:15:00 +0900</pubDate>
+ <enclosure url="https://github.com/downloads/ashchan/ruby-china-reader/RubyChina-0.1.zip"
+ sparkle:version="19"
+ sparkle:shortVersionString="0.1"
+ length="1222369"
type="application/zip" />
<description><![CDATA[
+ <h2>0.1</h2>
+ <p>2012-04-03</p>
+ <ul>
+ <li>* 增加对加载用户上传头像的支持(之前只支持显示gravatar头像)。</li>
+ </ul>
+
<h2>0.1b</h2>
<p>2012-03-14</p>
<p>原始预览版。</p>

0 comments on commit 46621fc

Please sign in to comment.
Something went wrong with that request. Please try again.