-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathPreference.m
executable file
·34 lines (27 loc) · 1.18 KB
/
Preference.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#import <UIKit/UIKit.h>
#import <Preferences/Preferences.h>
__attribute__((visibility("hidden")))
@interface RemoteTweetListController: PSListController
- (id)specifiers;
@end
@implementation RemoteTweetListController
- (id)specifiers {
if(_specifiers == nil) {
_specifiers = [[self loadSpecifiersFromPlistName:@"RemoteTweet" target:self] retain];
}
return _specifiers;
}
- (void)openTwitter:(id)specifier {
if ([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"tweetbot://"]])
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tweetbot:///user_profile/wa_kinchan"]];
else [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"https://twitter.com/wa_kinchan/"]];
}
- (void)openBlog:(id)specifier {
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://kindadev.com/blog/"]];
}
- (void)openTwitterSorega4:(id)specifier {
if ([[UIApplication sharedApplication] canOpenURL:[NSURL URLWithString:@"tweetbot://"]])
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"tweetbot:///user_profile/sorega4"]];
else [[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"https://twitter.com/sorega4/"]];
}
@end