Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Twitpic integration #167

Open
wants to merge 18 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
*.perspective
*.perspectivev3
*.mode1v3
*.xcworkspace
*xcuserdata
build
.DS_Store
Classes/ShareKit/SHKConfig.h
1 change: 1 addition & 0 deletions Classes/ShareKit/Core/SHKSharers.plist
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
<string>SHKReadItLater</string>
<string>SHKInstapaper</string>
<string>SHKTumblr</string>
<string>SHKTwitPic</string>
</array>
</dict>
</plist>
1 change: 1 addition & 0 deletions Classes/ShareKit/Localization/de.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"Create an account at %@" = "Erstelle einen Account auf %@";

"Send to Twitter" = "An Twitter senden";
"Send to TwitPic" = "An TwitPic senden";

"Message is too long" = "Nachricht zu lang";
"Twitter posts can only be 140 characters in length." = "Twitter Nachrichten können maximal 140 Zeichen lang sein.";
Expand Down
1 change: 1 addition & 0 deletions Classes/ShareKit/Localization/en.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"Create an account at %@" = "Create an account at %@";

"Send to Twitter" = "Send to Twitter";
"Send to TwitPic" = "Send to TwitPic";

"Message is too long" = "Message is too long";
"Twitter posts can only be 140 characters in length." = "Twitter posts can only be 140 characters in length.";
Expand Down
1 change: 1 addition & 0 deletions Classes/ShareKit/Localization/fr.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"Create an account at %@" = "Créer un compte sur %@";

"Send to Twitter" = "Envoyer sur Twitter";
"Send to TwitPic" = "Envoyer sur TwitPic";

"Message is too long" = "Message trop long";
"Twitter posts can only be 140 characters in length." = "Les messages Twitter ne peuvent dépasser 140 caractères.";
Expand Down
1 change: 1 addition & 0 deletions Classes/ShareKit/Localization/ko.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"Create an account at %@" = "%@ 계정 만들기";

"Send to Twitter" = "Twitter로 보내기";
"Send to TwitPic" = "TwitPic로 보내기";

"Message is too long" = "메시지가 너무 깁니다";
"Twitter posts can only be 140 characters in length." = "Twitter 메시지는 140자를 넘을 수 없습니다.";
Expand Down
1 change: 1 addition & 0 deletions Classes/ShareKit/Localization/nl.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"Create an account at %@" = "Maak een account op %@";

"Send to Twitter" = "Verzend naar Twitter";
"Send to TwitPic" = "Verzend naar TwitPic";

"Message is too long" = "Bericht is te lang";
"Twitter posts can only be 140 characters in length." = "Twitter bericht mag maar 140 karakters bevatten.";
Expand Down
Binary file modified Classes/ShareKit/Localization/vi.lproj/Localizable.strings
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@
"Create an account at %@" = "在 %@ 上创建一个账户";

"Send to Twitter" = "发送到 Twitter";
"Send to TwitPic" = "发送到 TwitPic";

"Message is too long" = "消息太长了";
"Twitter posts can only be 140 characters in length." = "Twitter 消息不能超过 140 个字符。";
Expand Down
9 changes: 8 additions & 1 deletion Classes/ShareKit/SHKConfig.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,13 +79,20 @@
#define SHKBitLyLogin @""
#define SHKBitLyKey @""

// Evernote http://www.evernote.com/about/developer/api/
#define SHKEvernoteConsumerKey @""
#define SHKEvernoteSecretKey @""
#define SHKEvernoteUserStoreURL @""
#define SHKEvernoteNetStoreURLBase @""

// ShareMenu Ordering
#define SHKShareMenuAlphabeticalOrder 1 // Setting this to 1 will show list in Alphabetical Order, setting to 0 will follow the order in SHKShares.plist

// Append 'Shared With 'Signature to Email (and related forms)
#define SHKSharedWithSignature 0


// TwitPic http://dev.twitpic.com/
#define SHKTwitPicAPIKey @""

/*
UI Configuration : Basic
Expand Down
44 changes: 44 additions & 0 deletions Classes/ShareKit/Sharers/Services/TwitPic/SHKTwitPic.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
//
// SHKTwitPic.h
// ShareKit
//
// Created by David Linsin on 2/5/11.
// Copyright 2011 furryfishApps.com. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "SHKOAuthSharer.h"
#import "SHKTwitPicForm.h"

@interface SHKTwitPic : SHKOAuthSharer {
NSString *twitPicAPIKey;
}

@property (nonatomic, retain) NSString *twitPicAPIKey;

#pragma mark -
#pragma mark UI Implementation

- (void)showTwitterForm;

#pragma mark -
#pragma mark Share API Methods

- (void)sendForm:(SHKTwitPicForm *)form;

- (void)sendImage;
- (void)sendImage:(OAServiceTicket *)ticket didFinishWithData:(NSData *)data;
- (void)sendImage:(OAServiceTicket *)ticket didFailWithError:(NSError*)error;

- (void)sendStatus:(NSString*)status;
- (void)sendStatusTicket:(OAServiceTicket *)ticket didFinishWithData:(NSData *)data;
- (void)sendStatusTicket:(OAServiceTicket *)ticket didFailWithError:(NSError*)error;

#pragma mark -
#pragma mark twitpic specific

- (BOOL)shareOnTwitter;
- (void)setShareOnTwitter:(BOOL)share;


@end
Loading