Skip to content

Commit 7bef157

Browse files
committed
[enh] Pushed version 1.4.0
1 parent 849dca6 commit 7bef157

File tree

10 files changed

+28
-11
lines changed

10 files changed

+28
-11
lines changed

Classes/MPFormatterUtils.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//
22
// MPFormatterUtils.h
33
//
4-
// Version 1.3.0
4+
// Version 1.4.0
55
//
66
// Created by Daniele Di Bernardo on 06/04/14.
77
// Copyright (c) 2017 marzapower. All rights reserved.

Classes/MPFormatterUtils.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//
22
// MPFormatterUtils.m
33
//
4-
// Version 1.3.0
4+
// Version 1.4.0
55
//
66
// Created by Daniele Di Bernardo on 06/04/14.
77
// Copyright (c) 2017 marzapower. All rights reserved.

Classes/MPNumericTextField.h

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//
22
// MPTextField.h
33
//
4-
// Version 1.3.0
4+
// Version 1.4.0
55
//
66
// Created by Daniele Di Bernardo on 05/04/14.
77
// Copyright (c) 2017 marzapower. All rights reserved.
@@ -32,6 +32,7 @@
3232
#import <UIKit/UIKit.h>
3333
#import "MPNumericTextFieldDelegate.h"
3434
#import "MPFormatterUtils.h"
35+
#import "MPTextField.h"
3536

3637
typedef NS_ENUM(NSUInteger, MPNumericTextFieldType) {
3738
MPNumericTextFieldDecimal = 0,
@@ -41,7 +42,7 @@ typedef NS_ENUM(NSUInteger, MPNumericTextFieldType) {
4142
};
4243

4344
IB_DESIGNABLE
44-
@interface MPNumericTextField : UITextField
45+
@interface MPNumericTextField : MPTextField
4546

4647
@property (nonatomic, copy) NSString *encodedValue;
4748
@property (nonatomic, assign) MPNumericTextFieldType type;

Classes/MPNumericTextField.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//
22
// MPTextField.m
33
//
4-
// Version 1.3.0
4+
// Version 1.4.0
55
//
66
// Created by Daniele Di Bernardo on 05/04/14.
77
// Copyright (c) 2017 marzapower. All rights reserved.

Classes/MPNumericTextFieldDelegate.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//
22
// MPNumericTextFieldDelegate.h
33
//
4-
// Version 1.3.0
4+
// Version 1.4.0
55
//
66
// Created by Daniele Di Bernardo on 06/04/14.
77
// Copyright (c) 2014 marzapower. All rights reserved.

Classes/MPNumericTextFieldDelegate.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
//
22
// MPNumericTextFieldDelegate.m
33
//
4-
// Version 1.3.0
4+
// Version 1.4.0
55
//
66
// Created by Daniele Di Bernardo on 06/04/14.
77
// Copyright (c) 2014 Charcoal Design. All rights reserved.

Examples/BasicExample/BasicExample.xcodeproj/project.pbxproj

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
8513504618F1874C00A12D4A /* MPFormatterUtils.m in Sources */ = {isa = PBXBuildFile; fileRef = 8513504118F1874C00A12D4A /* MPFormatterUtils.m */; };
2626
8513504718F1874C00A12D4A /* MPNumericTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = 8513504318F1874C00A12D4A /* MPNumericTextField.m */; };
2727
8513504818F1874C00A12D4A /* MPNumericTextFieldDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 8513504518F1874C00A12D4A /* MPNumericTextFieldDelegate.m */; };
28+
CFA3075B1E8FE18200B7A8ED /* MPTextField.m in Sources */ = {isa = PBXBuildFile; fileRef = CFA3075A1E8FE18200B7A8ED /* MPTextField.m */; };
2829
/* End PBXBuildFile section */
2930

3031
/* Begin PBXContainerItemProxy section */
@@ -64,6 +65,8 @@
6465
8513504318F1874C00A12D4A /* MPNumericTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPNumericTextField.m; sourceTree = "<group>"; };
6566
8513504418F1874C00A12D4A /* MPNumericTextFieldDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPNumericTextFieldDelegate.h; sourceTree = "<group>"; };
6667
8513504518F1874C00A12D4A /* MPNumericTextFieldDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPNumericTextFieldDelegate.m; sourceTree = "<group>"; };
68+
CFA307591E8FE18200B7A8ED /* MPTextField.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = MPTextField.h; sourceTree = "<group>"; };
69+
CFA3075A1E8FE18200B7A8ED /* MPTextField.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = MPTextField.m; sourceTree = "<group>"; };
6770
/* End PBXFileReference section */
6871

6972
/* Begin PBXFrameworksBuildPhase section */
@@ -174,6 +177,8 @@
174177
8513504318F1874C00A12D4A /* MPNumericTextField.m */,
175178
8513504418F1874C00A12D4A /* MPNumericTextFieldDelegate.h */,
176179
8513504518F1874C00A12D4A /* MPNumericTextFieldDelegate.m */,
180+
CFA307591E8FE18200B7A8ED /* MPTextField.h */,
181+
CFA3075A1E8FE18200B7A8ED /* MPTextField.m */,
177182
);
178183
name = Classes;
179184
path = ../../Classes;
@@ -284,6 +289,7 @@
284289
8513501818F1873A00A12D4A /* MPAppDelegate.m in Sources */,
285290
8513504618F1874C00A12D4A /* MPFormatterUtils.m in Sources */,
286291
8513504818F1874C00A12D4A /* MPNumericTextFieldDelegate.m in Sources */,
292+
CFA3075B1E8FE18200B7A8ED /* MPTextField.m in Sources */,
287293
);
288294
runOnlyForDeploymentPostprocessing = 0;
289295
};
@@ -498,6 +504,7 @@
498504
8513503B18F1873A00A12D4A /* Release */,
499505
);
500506
defaultConfigurationIsVisible = 0;
507+
defaultConfigurationName = Release;
501508
};
502509
8513503C18F1873A00A12D4A /* Build configuration list for PBXNativeTarget "BasicExampleTests" */ = {
503510
isa = XCConfigurationList;
@@ -506,6 +513,7 @@
506513
8513503E18F1873A00A12D4A /* Release */,
507514
);
508515
defaultConfigurationIsVisible = 0;
516+
defaultConfigurationName = Release;
509517
};
510518
/* End XCConfigurationList section */
511519
};

Examples/BasicExample/BasicExample/Base.lproj/Main_iPhone.storyboard

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
<fontDescription key="fontDescription" type="system" pointSize="17"/>
6565
<nil key="highlightedColor"/>
6666
</label>
67-
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="TNM-7c-VIr" userLabel="currency" customClass="MPNumericTextField">
67+
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" textAlignment="center" minimumFontSize="17" translatesAutoresizingMaskIntoConstraints="NO" id="TNM-7c-VIr" userLabel="currency" customClass="MPNumericTextField">
6868
<rect key="frame" x="157" y="157" width="143" height="30"/>
6969
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
7070
<color key="backgroundColor" red="0.56970397949999996" green="0.69763851799999999" blue="1" alpha="0.050000000000000003" colorSpace="custom" customColorSpace="sRGB"/>

MPNumericTextField.podspec

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Pod::Spec.new do |s|
22
s.name = "MPNumericTextField"
3-
s.version = "1.3.0"
3+
s.version = "1.4.0"
44
s.summary = "A class that extends UITextField to input numbers, percentages and currencies."
55

66
s.description = <<-DESC
@@ -15,7 +15,7 @@ Pod::Spec.new do |s|
1515
s.social_media_url = "http://twitter.com/marzapower"
1616

1717
s.platform = :ios, "6.0"
18-
s.source = { :git => "https://github.com/marzapower/MPNumericTextField.git", :tag => "1.3.0" }
18+
s.source = { :git => "https://github.com/marzapower/MPNumericTextField.git", :tag => "1.4.0" }
1919
s.source_files = "Classes", "Classes/**/*.{h,m}"
2020
s.exclude_files = "Classes/Exclude"
2121
s.public_header_files = "Classes/**/*.h"

README.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Installation
1717
Just add the following line to the `Podfile` in your project:
1818

1919
```ruby
20-
pod "MPNumericTextField", '~> 1.3.0'
20+
pod "MPNumericTextField", '~> 1.4.0'
2121
```
2222

2323
### Manually
@@ -125,14 +125,22 @@ If you need further assistance, please contact me on Twitter: [@marzapower][twit
125125

126126
## Release notes
127127

128+
Version 1.4.0
129+
130+
- [new] The new `MPTextField` class opens the usage of `placeholderColor` outside of the handling of the numeric text field
131+
- [fix] No more default right alignement for the text field if loaded from a NIB file
132+
128133
Version 1.3.0
134+
129135
- [new] Custom currency codes for the text field
130136
- [new] Nullability modifiers for the utility methods in `MPFormatterUtils`
131137

132138
Version 1.2.1
139+
133140
- [fix] Doesn't use cached locale anymore when system locale changes
134141

135142
Version 1.2.0
143+
136144
- [New] Added support to integer-only numbers with `MPNumericTextFieldInteger`
137145
- [Enh] Better support for Swift integration
138146

0 commit comments

Comments
 (0)