Skip to content

Commit

Permalink
Merging v4.6 branch for release
Browse files Browse the repository at this point in the history
  • Loading branch information
jeevatkm committed Sep 10, 2014
2 parents 4670407 + 8cbbbab commit fea5e16
Show file tree
Hide file tree
Showing 6 changed files with 322 additions and 201 deletions.
18 changes: 18 additions & 0 deletions ReplyWithHeader.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@
13E929FB1800CB1100AAE5CE /* MailHeader.m in Sources */ = {isa = PBXBuildFile; fileRef = 13E929FA1800CB1000AAE5CE /* MailHeader.m */; };
9C27AEB81932CF540007486F /* MHSignature.m in Sources */ = {isa = PBXBuildFile; fileRef = 9C27AEB71932CF540007486F /* MHSignature.m */; };
9C3230E619BD578200757AA4 /* Credits.rtf in Resources */ = {isa = PBXBuildFile; fileRef = 9C3230E519BD578200757AA4 /* Credits.rtf */; };
9CE4221D19BFAD3C005E7C07 /* MHDisplayNotes.m in Sources */ = {isa = PBXBuildFile; fileRef = 9CE4221B19BFAD3C005E7C07 /* MHDisplayNotes.m */; };
9CE4222419BFDFE1005E7C07 /* MHDisplayNotes.xib in Resources */ = {isa = PBXBuildFile; fileRef = 9CE4222219BFDFE1005E7C07 /* MHDisplayNotes.xib */; };
/* End PBXBuildFile section */

/* Begin PBXFileReference section */
Expand Down Expand Up @@ -123,6 +125,9 @@
9C27AEB61932CF540007486F /* MHSignature.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MHSignature.h; sourceTree = "<group>"; };
9C27AEB71932CF540007486F /* MHSignature.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MHSignature.m; sourceTree = "<group>"; };
9C3230E519BD578200757AA4 /* Credits.rtf */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.rtf; path = Credits.rtf; sourceTree = "<group>"; };
9CE4221A19BFAD3C005E7C07 /* MHDisplayNotes.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MHDisplayNotes.h; sourceTree = "<group>"; };
9CE4221B19BFAD3C005E7C07 /* MHDisplayNotes.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MHDisplayNotes.m; sourceTree = "<group>"; };
9CE4222319BFDFE1005E7C07 /* en */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = en; path = en.lproj/MHDisplayNotes.xib; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
Expand Down Expand Up @@ -209,13 +214,16 @@
13AD486C18018D4600473407 /* MHUpdater.m */,
9C27AEB61932CF540007486F /* MHSignature.h */,
9C27AEB71932CF540007486F /* MHSignature.m */,
9CE4221A19BFAD3C005E7C07 /* MHDisplayNotes.h */,
9CE4221B19BFAD3C005E7C07 /* MHDisplayNotes.m */,
);
name = Classes;
sourceTree = "<group>";
};
1371DD0117F864FE00320B54 /* Resources */ = {
isa = PBXGroup;
children = (
9CE4222219BFDFE1005E7C07 /* MHDisplayNotes.xib */,
132C66621827E23400CD7C1A /* language.png */,
138BAEBA1820218C00738ADB /* MHUpdateAlert.xib */,
13882A2F18073509004BCC6D /* LICENSE.txt */,
Expand Down Expand Up @@ -380,6 +388,7 @@
1371DD1817F864FE00320B54 /* ReplyWithHeader.icns in Resources */,
13A25F4717F9CE90002394DF /* Entitlements.plist in Resources */,
138BAEBC1820218C00738ADB /* MHUpdateAlert.xib in Resources */,
9CE4222419BFDFE1005E7C07 /* MHDisplayNotes.xib in Resources */,
1365843917FAC12700E8C57D /* MailHeader.strings in Resources */,
1372350F17FD8316007E7B71 /* MHPreferencesView.xib in Resources */,
132C66631827E23400CD7C1A /* language.png in Resources */,
Expand Down Expand Up @@ -430,6 +439,7 @@
13AD486D18018D4600473407 /* MHUpdater.m in Sources */,
9C27AEB81932CF540007486F /* MHSignature.m in Sources */,
13882A2B18072C7D004BCC6D /* MLog.m in Sources */,
9CE4221D19BFAD3C005E7C07 /* MHDisplayNotes.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -514,6 +524,14 @@
name = Config.plist;
sourceTree = "<group>";
};
9CE4222219BFDFE1005E7C07 /* MHDisplayNotes.xib */ = {
isa = PBXVariantGroup;
children = (
9CE4222319BFDFE1005E7C07 /* en */,
);
name = MHDisplayNotes.xib;
sourceTree = "<group>";
};
/* End PBXVariantGroup section */

/* Begin XCBuildConfiguration section */
Expand Down
42 changes: 42 additions & 0 deletions ReplyWithHeader/MHDisplayNotes.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
/*
* The MIT License (MIT)
*
* Copyright (c) 2013-2014 Jeevanandam M.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* 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.
*/

//
// MHDisplayNotes.h
// ReplyWithHeader
//
// Created by Jeevanandam M. on 9/9/14.
//
//

@interface MHDisplayNotes : NSWindowController {
__unsafe_unretained NSTextView *_notesView;
NSString *_rtfPath;
}

@property (unsafe_unretained) IBOutlet NSTextView *notesView;

- (id)initWithPath:(NSString *)rtfPath;

@end
76 changes: 76 additions & 0 deletions ReplyWithHeader/MHDisplayNotes.m
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
/*
* The MIT License (MIT)
*
* Copyright (c) 2013-2014 Jeevanandam M.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* 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.
*/

//
// MHDisplayNotes.m
// ReplyWithHeader
//
// Created by Jeevanandam M. on 9/9/14.
//
//

#import "MHDisplayNotes.h"

@interface MHDisplayNotes ()
- (IBAction)closeDisplayNotes:(id)sender;
@end

@implementation MHDisplayNotes

- (void)windowDidLoad
{
[super windowDidLoad];
}

- (NSString *)windowNibName {
return NSStringFromClass([MHDisplayNotes class]);
}

- (void)awakeFromNib
{
[[self window] setShowsResizeIndicator: NO];
[[self window] center];

[_notesView readRTFDFromFile:_rtfPath];
}

- (id)initWithPath:(NSString *)rtfPath
{
self = [super init];
if (self)
{
[self setShouldCascadeWindows:NO];

_rtfPath = [rtfPath copy];
}
return self;
}

- (IBAction)closeDisplayNotes:(id)sender
{
[NSApp stopModal];
[self close];
}

@end
9 changes: 9 additions & 0 deletions ReplyWithHeader/MHPreferences.m
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
#import "MHPreferences.h"
#import "MHSignature.h"
#import "Signature.h"
#import "MHDisplayNotes.h"

@interface MHPreferences (MHNoImplementation)
- (id)signatureAccounts;
Expand All @@ -44,6 +45,7 @@ - (IBAction)signatureMatrixPressed:(id)sender;
- (IBAction)openWebsite:(id)sender;
- (IBAction)openFeedback:(id)sender;
- (IBAction)openSupport:(id)sender;
- (IBAction)openCredits:(id)sender;
- (IBAction)notifyNewVersionPressed:(id)sender;
@end

Expand Down Expand Up @@ -175,6 +177,13 @@ - (IBAction)openSupport:(id)sender
[[NSWorkspace sharedWorkspace] openURL:[NSURL URLWithString:@"https://github.com/jeevatkm/ReplyWithHeader/issues"]];
}

- (IBAction)openCredits:(id)sender
{
NSString *filePath = [[MailHeader bundle] pathForResource:@"Credits" ofType:@"rtf"];
MHDisplayNotes *displayNotes = [[MHDisplayNotes alloc] initWithPath:filePath];
[NSApp runModalForWindow:[displayNotes window]];
}

- (IBAction)notifyNewVersionPressed:(id)sender
{
if (![sender state])
Expand Down
72 changes: 72 additions & 0 deletions ReplyWithHeader/Resources/en.lproj/MHDisplayNotes.xib
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="5056" systemVersion="13E28" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES">
<dependencies>
<deployment defaultVersion="1070" identifier="macosx"/>
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="5056"/>
</dependencies>
<objects>
<customObject id="-2" userLabel="File's Owner" customClass="MHDisplayNotes">
<connections>
<outlet property="notesView" destination="tKf-J3-YiI" id="iNy-dB-Uwm"/>
<outlet property="window" destination="F0z-JX-Cv5" id="gIp-Ho-8D9"/>
</connections>
</customObject>
<customObject id="-1" userLabel="First Responder" customClass="FirstResponder"/>
<customObject id="-3" userLabel="Application"/>
<window title="Window" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" oneShot="NO" showsToolbarButton="NO" animationBehavior="default" id="F0z-JX-Cv5">
<windowStyleMask key="styleMask" closable="YES"/>
<windowPositionMask key="initialPositionMask" leftStrut="YES" rightStrut="YES" topStrut="YES" bottomStrut="YES"/>
<rect key="contentRect" x="428" y="257" width="480" height="282"/>
<rect key="screenRect" x="0.0" y="0.0" width="1280" height="778"/>
<view key="contentView" id="se5-gp-TjO">
<rect key="frame" x="0.0" y="0.0" width="480" height="282"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<button verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="pOy-x6-tRX">
<rect key="frame" x="374" y="19" width="86" height="19"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
<buttonCell key="cell" type="roundRect" title="Close" bezelStyle="roundedRect" alignment="center" state="on" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="fq9-hS-aYS">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="cellTitle"/>
</buttonCell>
<connections>
<action selector="closeDisplayNotes:" target="-2" id="H57-6g-mGl"/>
</connections>
</button>
<scrollView fixedFrame="YES" borderType="groove" autohidesScrollers="YES" horizontalLineScroll="10" horizontalPageScroll="10" verticalLineScroll="10" verticalPageScroll="10" usesPredominantAxisScrolling="NO" translatesAutoresizingMaskIntoConstraints="NO" id="4zr-Zz-3xc">
<rect key="frame" x="20" y="46" width="440" height="216"/>
<autoresizingMask key="autoresizingMask"/>
<clipView key="contentView" ambiguous="YES" misplaced="YES" id="JHS-Ya-Pc6">
<rect key="frame" x="2" y="2" width="436" height="212"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<textView ambiguous="YES" editable="NO" selectable="NO" findStyle="panel" continuousSpellChecking="YES" usesRuler="YES" usesFontPanel="YES" verticallyResizable="YES" allowsNonContiguousLayout="YES" quoteSubstitution="YES" linkDetection="YES" dashSubstitution="YES" spellingCorrection="YES" id="tKf-J3-YiI">
<rect key="frame" x="0.0" y="0.0" width="436" height="212"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<size key="minSize" width="436" height="212"/>
<size key="maxSize" width="463" height="10000000"/>
<color key="insertionPointColor" white="0.0" alpha="1" colorSpace="calibratedWhite"/>
<size key="minSize" width="436" height="212"/>
<size key="maxSize" width="463" height="10000000"/>
</textView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
</clipView>
<scroller key="horizontalScroller" hidden="YES" verticalHuggingPriority="750" doubleValue="1" horizontal="YES" id="Nse-th-0gS">
<rect key="frame" x="2" y="186" width="436" height="16"/>
<autoresizingMask key="autoresizingMask"/>
</scroller>
<scroller key="verticalScroller" hidden="YES" verticalHuggingPriority="750" doubleValue="1" horizontal="NO" id="loP-kk-gXS">
<rect key="frame" x="422" y="2" width="16" height="200"/>
<autoresizingMask key="autoresizingMask"/>
</scroller>
</scrollView>
</subviews>
</view>
<connections>
<outlet property="delegate" destination="-2" id="0bl-1N-AYu"/>
</connections>
</window>
</objects>
</document>
Loading

0 comments on commit fea5e16

Please sign in to comment.