Skip to content

Commit c15fcf7

Browse files
committed
Merge branch 'dev' of https://github.com/GPGTools/GPGMail into dev
2 parents bd2403a + 127ad2b commit c15fcf7

File tree

150 files changed

+277
-163
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

150 files changed

+277
-163
lines changed

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@
44
build/
55
*xcuserdata/
66
Dependencies/GPGTools_Core
7+
Dependencies/Libmacgpg

Dependencies/.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
#

Dependencies/Libmacgpg

Submodule Libmacgpg deleted from 4780c8b

Frameworks/Sparkle.framework/Versions/A/Headers/SUAppcast.h

+5-2
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,14 @@
1010
#define SUAPPCAST_H
1111

1212
@class SUAppcastItem;
13-
@interface SUAppcast : NSObject {
13+
@interface SUAppcast : NSObject
14+
{
15+
@private
1416
NSArray *items;
1517
NSString *userAgentString;
1618
id delegate;
17-
NSMutableData *incrementalData;
19+
NSString *downloadFilename;
20+
NSURLDownload *download;
1821
}
1922

2023
- (void)fetchAppcastFromURL:(NSURL *)url;

Frameworks/Sparkle.framework/Versions/A/Headers/SUAppcastItem.h

+18-12
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,9 @@
99
#ifndef SUAPPCASTITEM_H
1010
#define SUAPPCASTITEM_H
1111

12-
@interface SUAppcastItem : NSObject {
12+
@interface SUAppcastItem : NSObject
13+
{
14+
@private
1315
NSString *title;
1416
NSDate *date;
1517
NSString *itemDescription;
@@ -18,29 +20,33 @@
1820

1921
NSString *DSASignature;
2022
NSString *minimumSystemVersion;
23+
NSString *maximumSystemVersion;
2124

2225
NSURL *fileURL;
2326
NSString *versionString;
2427
NSString *displayVersionString;
25-
28+
29+
NSDictionary *deltaUpdates;
30+
2631
NSDictionary *propertiesDictionary;
32+
33+
NSURL *infoURL; // UK 2007-08-31
2734
}
2835

2936
// Initializes with data from a dictionary provided by the RSS class.
3037
- initWithDictionary:(NSDictionary *)dict;
38+
- initWithDictionary:(NSDictionary *)dict failureReason:(NSString**)error;
3139

32-
- (NSString *)title;
33-
- (NSString *)versionString;
34-
- (NSString *)displayVersionString;
35-
- (NSDate *)date;
36-
- (NSString *)itemDescription;
37-
- (NSURL *)releaseNotesURL;
38-
- (NSURL *)fileURL;
39-
- (NSString *)DSASignature;
40-
- (NSString *)minimumSystemVersion;
40+
@property (retain) NSString *title, *itemDescription, *DSASignature, *versionString, *displayVersionString, *minimumSystemVersion, *maximumSystemVersion;
41+
@property (retain) NSDate *date;
42+
@property (retain) NSURL *releaseNotesURL, *fileURL, *infoURL;
43+
@property (retain) NSDictionary *deltaUpdates;
4144

45+
@property (readonly) BOOL isDeltaUpdate;
4246
// Returns the dictionary provided in initWithDictionary; this might be useful later for extensions.
43-
- (NSDictionary *)propertiesDictionary;
47+
@property (readonly) NSDictionary *propertiesDictionary;
48+
49+
4450

4551
@end
4652

Frameworks/Sparkle.framework/Versions/A/Headers/SUUpdater.h

+67-10
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,30 @@
99
#ifndef SUUPDATER_H
1010
#define SUUPDATER_H
1111

12-
#import <Sparkle/SUVersionComparisonProtocol.h>
12+
#import "SUVersionComparisonProtocol.h"
13+
#import "SUVersionDisplayProtocol.h"
1314

14-
@class SUUpdateDriver, SUAppcastItem, SUHost, SUAppcast;
15-
@interface SUUpdater : NSObject {
15+
@class SUUpdateDriver, SUAppcastItem, SUHost, SUAppcast, SUUpdateAlert;
16+
17+
@interface SUUpdater : NSObject
18+
{
19+
@private
1620
NSTimer *checkTimer;
1721
SUUpdateDriver *driver;
18-
22+
23+
NSString *customUserAgentString;
1924
SUHost *host;
2025
IBOutlet id delegate;
2126
}
2227

2328
+ (SUUpdater *)sharedUpdater;
2429
+ (SUUpdater *)updaterForBundle:(NSBundle *)bundle;
30+
- (id)initForBundle:(NSBundle *)bundle;
31+
2532
- (NSBundle *)hostBundle;
2633

2734
- (void)setDelegate:(id)delegate;
28-
- delegate;
35+
- (id)delegate;
2936

3037
- (void)setAutomaticallyChecksForUpdates:(BOOL)automaticallyChecks;
3138
- (BOOL)automaticallyChecksForUpdates;
@@ -34,7 +41,10 @@
3441
- (NSTimeInterval)updateCheckInterval;
3542

3643
- (void)setFeedURL:(NSURL *)feedURL;
37-
- (NSURL *)feedURL;
44+
- (NSURL *)feedURL; // *** MUST BE CALLED ON MAIN THREAD ***
45+
46+
- (void)setUserAgentString:(NSString *)userAgent;
47+
- (NSString *)userAgentString;
3848

3949
- (void)setSendsSystemProfile:(BOOL)sendsSystemProfile;
4050
- (BOOL)sendsSystemProfile;
@@ -44,14 +54,14 @@
4454

4555
// This IBAction is meant for a main menu item. Hook up any menu item to this action,
4656
// and Sparkle will check for updates and report back its findings verbosely.
47-
- (IBAction)checkForUpdates:sender;
57+
- (IBAction)checkForUpdates:(id)sender;
4858

4959
// This kicks off an update meant to be programmatically initiated. That is, it will display no UI unless it actually finds an update,
5060
// in which case it proceeds as usual. If the fully automated updating is turned on, however, this will invoke that behavior, and if an
5161
// update is found, it will be downloaded and prepped for installation.
5262
- (void)checkForUpdatesInBackground;
5363

54-
// Date of last update check. Returns null if no check has been performed.
64+
// Date of last update check. Returns nil if no check has been performed.
5565
- (NSDate*)lastUpdateCheckDate;
5666

5767
// This begins a "probing" check for updates which will not actually offer to update to that version. The delegate methods, though,
@@ -62,12 +72,25 @@
6272
- (void)resetUpdateCycle;
6373

6474
- (BOOL)updateInProgress;
75+
6576
@end
6677

78+
79+
// -----------------------------------------------------------------------------
80+
// SUUpdater Delegate:
81+
// -----------------------------------------------------------------------------
82+
6783
@interface NSObject (SUUpdaterDelegateInformalProtocol)
84+
85+
// Use this to keep Sparkle from popping up e.g. while your setup assistant is showing:
86+
- (BOOL)updaterMayCheckForUpdates:(SUUpdater *)bundle;
87+
6888
// This method allows you to add extra parameters to the appcast URL, potentially based on whether or not Sparkle will also be sending along the system profile. This method should return an array of dictionaries with keys: "key", "value", "displayKey", "displayValue", the latter two being specifically for display to the user.
6989
- (NSArray *)feedParametersForUpdater:(SUUpdater *)updater sendingSystemProfile:(BOOL)sendingProfile;
7090

91+
// Override this to dynamically specify the entire URL.
92+
- (NSString*)feedURLStringForUpdater:(SUUpdater*)updater;
93+
7194
// Use this to override the default behavior for Sparkle prompting the user about automatic update checks.
7295
- (BOOL)updaterShouldPromptForPermissionToCheckForUpdates:(SUUpdater *)bundle;
7396

@@ -88,28 +111,62 @@
88111
- (void)updater:(SUUpdater *)updater willInstallUpdate:(SUAppcastItem *)update;
89112

90113
// Return YES to delay the relaunch until you do some processing; invoke the given NSInvocation to continue.
114+
// This is not called if the user didn't relaunch on the previous update, in that case it will immediately
115+
// restart.
91116
- (BOOL)updater:(SUUpdater *)updater shouldPostponeRelaunchForUpdate:(SUAppcastItem *)update untilInvoking:(NSInvocation *)invocation;
92117

118+
// Some apps *can not* be relaunched in certain circumstances. They can use this method
119+
// to prevent a relaunch "hard":
120+
- (BOOL)updaterShouldRelaunchApplication:(SUUpdater *)updater;
121+
93122
// Called immediately before relaunching.
94123
- (void)updaterWillRelaunchApplication:(SUUpdater *)updater;
95124

96125
// This method allows you to provide a custom version comparator.
97126
// If you don't implement this method or return nil, the standard version comparator will be used.
98127
- (id <SUVersionComparison>)versionComparatorForUpdater:(SUUpdater *)updater;
99128

129+
// This method allows you to provide a custom version comparator.
130+
// If you don't implement this method or return nil, the standard version displayer will be used.
131+
- (id <SUVersionDisplay>)versionDisplayerForUpdater:(SUUpdater *)updater;
132+
100133
// Returns the path which is used to relaunch the client after the update is installed. By default, the path of the host bundle.
101134
- (NSString *)pathToRelaunchForUpdater:(SUUpdater *)updater;
102135

136+
// Called before and after, respectively, an updater shows a modal alert window, to give the host
137+
// the opportunity to hide attached windows etc. that may get in the way:
138+
-(void) updaterWillShowModalAlert:(SUUpdater *)updater;
139+
-(void) updaterDidShowModalAlert:(SUUpdater *)updater;
140+
141+
// To resize the release notes view.
142+
- (void)updateAlert:(SUUpdateAlert *)updateAlert willShowReleaseNotesWithSize:(NSSize*)size;
143+
144+
@end
145+
146+
@protocol SUUserDefaults <NSObject>
147+
- (id)objectForKey:(NSString *)key;
148+
- (void)setObject:(id)value forKey:(NSString *)key;
149+
- (BOOL)boolForKey:(NSString *)key;
150+
- (void)setBool:(BOOL)value forKey:(NSString *)key;
151+
@end
152+
153+
@interface NSObject (SUUserDefaults)
154+
@property (readonly) id <SUUserDefaults> userDefaults;
103155
@end
104156

157+
158+
// -----------------------------------------------------------------------------
159+
// Constants:
160+
// -----------------------------------------------------------------------------
161+
105162
// Define some minimum intervals to avoid DOS-like checking attacks. These are in seconds.
106-
#ifdef DEBUG
163+
#if defined(DEBUG) && DEBUG && 0
107164
#define SU_MIN_CHECK_INTERVAL 60
108165
#else
109166
#define SU_MIN_CHECK_INTERVAL 60*60
110167
#endif
111168

112-
#ifdef DEBUG
169+
#if defined(DEBUG) && DEBUG && 0
113170
#define SU_DEFAULT_CHECK_INTERVAL 60
114171
#else
115172
#define SU_DEFAULT_CHECK_INTERVAL 60*60*24

Frameworks/Sparkle.framework/Versions/A/Headers/SUVersionComparisonProtocol.h

+3-1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99
#ifndef SUVERSIONCOMPARISONPROTOCOL_H
1010
#define SUVERSIONCOMPARISONPROTOCOL_H
1111

12+
#import <Cocoa/Cocoa.h>
13+
1214
/*!
1315
@protocol
1416
@abstract Implement this protocol to provide version comparison facilities for Sparkle.
@@ -20,7 +22,7 @@
2022
@abstract An abstract method to compare two version strings.
2123
@discussion Should return NSOrderedAscending if b > a, NSOrderedDescending if b < a, and NSOrderedSame if they are equivalent.
2224
*/
23-
- (NSComparisonResult)compareVersion:(NSString *)versionA toVersion:(NSString *)versionB;
25+
- (NSComparisonResult)compareVersion:(NSString *)versionA toVersion:(NSString *)versionB; // *** MAY BE CALLED ON NON-MAIN THREAD!
2426

2527
@end
2628

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
//
2+
// SUVersionDisplayProtocol.h
3+
// EyeTV
4+
//
5+
// Created by Uli Kusterer on 08.12.09.
6+
// Copyright 2009 Elgato Systems GmbH. All rights reserved.
7+
//
8+
9+
#import <Cocoa/Cocoa.h>
10+
11+
12+
/*!
13+
@protocol
14+
@abstract Implement this protocol to apply special formatting to the two
15+
version numbers.
16+
*/
17+
@protocol SUVersionDisplay
18+
19+
/*!
20+
@method
21+
@abstract An abstract method to format two version strings.
22+
@discussion You get both so you can display important distinguishing
23+
information, but leave out unnecessary/confusing parts.
24+
*/
25+
-(void) formatVersion: (NSString**)inOutVersionA andVersion: (NSString**)inOutVersionB;
26+
27+
@end

Frameworks/Sparkle.framework/Versions/A/Resources/Info.plist

+8-8
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<plist version="1.0">
44
<dict>
55
<key>BuildMachineOSBuild</key>
6-
<string>11D50</string>
6+
<string>12D78</string>
77
<key>CFBundleDevelopmentRegion</key>
88
<string>en</string>
99
<key>CFBundleExecutable</key>
@@ -17,24 +17,24 @@
1717
<key>CFBundlePackageType</key>
1818
<string>FMWK</string>
1919
<key>CFBundleShortVersionString</key>
20-
<string>1.5 Beta (bzr)</string>
20+
<string>1.5 Beta (git)</string>
2121
<key>CFBundleSignature</key>
2222
<string>????</string>
2323
<key>CFBundleVersion</key>
24-
<string>1.5</string>
24+
<string>9ea0745</string>
2525
<key>DTCompiler</key>
26-
<string></string>
26+
<string>com.apple.compilers.llvm.clang.1_0</string>
2727
<key>DTPlatformBuild</key>
28-
<string>4D5031b</string>
28+
<string>4H1003</string>
2929
<key>DTPlatformVersion</key>
3030
<string>GM</string>
3131
<key>DTSDKBuild</key>
32-
<string>11A476a</string>
32+
<string>11E52</string>
3333
<key>DTSDKName</key>
3434
<string>macosx10.7</string>
3535
<key>DTXcode</key>
36-
<string>0420</string>
36+
<string>0462</string>
3737
<key>DTXcodeBuild</key>
38-
<string>4D5031b</string>
38+
<string>4H1003</string>
3939
</dict>
4040
</plist>

Frameworks/Sparkle.framework/Versions/A/Resources/License.txt

+32-1
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,35 @@ Permission is hereby granted, free of charge, to any person obtaining a copy of
44

55
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
66

7-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
7+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
8+
9+
=================
10+
EXTERNAL LICENSES
11+
=================
12+
13+
License for bspatch.c and bsdiff.c, from bsdiff 4.3 (<http://www.daemonology.net/bsdiff/>:
14+
/*-
15+
* Copyright 2003-2005 Colin Percival
16+
* All rights reserved
17+
*
18+
* Redistribution and use in source and binary forms, with or without
19+
* modification, are permitted providing that the following conditions
20+
* are met:
21+
* 1. Redistributions of source code must retain the above copyright
22+
* notice, this list of conditions and the following disclaimer.
23+
* 2. Redistributions in binary form must reproduce the above copyright
24+
* notice, this list of conditions and the following disclaimer in the
25+
* documentation and/or other materials provided with the distribution.
26+
*
27+
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
28+
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
29+
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
30+
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
31+
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
32+
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
33+
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
34+
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
35+
* STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING
36+
* IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
37+
* POSSIBILITY OF SUCH DAMAGE.
38+
*/

0 commit comments

Comments
 (0)