Skip to content

Commit

Permalink
Fix incorrect call in mmm_imageFromPDFNamed:tintColor:
Browse files Browse the repository at this point in the history
  • Loading branch information
aleh committed Aug 13, 2024
1 parent 30ac40f commit 6f84dcf
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion MMMCommonUI.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Pod::Spec.new do |s|

s.name = "MMMCommonUI"
s.version = "3.12.1"
s.version = "3.12.2"
s.summary = "Small UI-related pieces reused in many components from MMMTemple"
s.description = "#{s.summary}."
s.homepage = "https://github.com/mediamonks/#{s.name}"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ private class MMMNavigationStackHelper: NSObject, MMMNavigationStackItemDelegate
// The record is already removed as part of the pop request, nothing to do here.
return
} else {
MMMLogError(self, "Trying to remove a record for a \(MMMTypeName(viewController)) while popping a different instance (\(MMMTypeName(recordPoppingNow.viewController)))")
MMMLogError(self, "Trying to remove a record for a \(MMMTypeName(viewController)) while popping a different instance (\(MMMTypeName(recordPoppingNow.viewController as Any)))")
assertionFailure()
// It would be a weird case, but let it continue in production.
}
Expand Down
4 changes: 2 additions & 2 deletions Sources/MMMCommonUIObjC/MMMCommonUIMisc.h
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ extern NSAttributedStringKey const MMMCaseTransformAttributeName NS_SWIFT_NAME(c
* specified view. It's always greater than or equal to zero.
* It can be used to manually adjust the insets of a scroll view which is covered by the status bar.
*/
extern CGFloat MMMHeightOfAreaCoveredByStatusBar(UIView *view, CGRect rect);
extern CGFloat MMMHeightOfAreaCoveredByStatusBar(UIView *view, CGRect rect) DEPRECATED_ATTRIBUTE;

//
//
Expand Down Expand Up @@ -349,7 +349,7 @@ extern CGFloat MMMPhaseForDashedPattern(CGFloat lineLength, CGFloat dashLength,
extern void MMMAddDashedCircle(CGPoint center, CGFloat radius, CGFloat dashLength, CGFloat skipLength);

/** YES, if running under Fastlane's Snapshot tool. */
static inline BOOL MMMIsRunningUnderFastlane() {
static inline BOOL MMMIsRunningUnderFastlane(void) {

#if DEBUG

Expand Down
6 changes: 3 additions & 3 deletions Sources/MMMCommonUIObjC/MMMCommonUIMisc.m
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ void MMMDrawBorder(CGRect r, UIRectEdge edge, UIColor *color, CGFloat width) {
CGContextStrokePath(c);
}

CGFloat MMMPixelScale() {
CGFloat MMMPixelScale(void) {
static CGFloat scale = 1;
static dispatch_once_t onceToken;
dispatch_once(&onceToken, ^{
Expand Down Expand Up @@ -338,7 +338,7 @@ CGFloat MMMHeightOfAreaCoveredByStatusBar(UIView *view, CGRect rect) {
// This is to work around the problem with UI rotations: it is possible that the status bar is still portrait
// while the view is already landscape, and it can also be hidden (zero height);
// in this case the height calculated as below will be large and will cause layout issues.
// Returning 0 now assumming that the view using this function will eventually recalculate the status bar height
// Returning 0 now assuming that the view using this function will eventually recalculate the status bar height
// in response to UIApplicationDidChangeStatusBarFrameNotification.
if (CGRectGetHeight(statusBarRect) <= 0 || CGRectGetHeight(statusBarRect) > CGRectGetWidth(statusBarRect))
return 0;
Expand Down Expand Up @@ -465,7 +465,7 @@ + (UIImage *)mmm_imageFromPDFNamed:(NSString *)name rasterizedForHeight:(CGFloat
}

+ (UIImage *)mmm_imageFromPDFNamed:(NSString *)name tintColor:(UIColor *)tintColor {
return [self mmm_cacheKeyForNamed:name height:0 tintColor:tintColor];
return [self mmm_imageFromPDFNamed:name rasterizedForHeight:0 tintColor:tintColor];
}

+ (UIImage *)mmm_imageFromPDFNamed:(NSString *)name rasterizedForHeight:(CGFloat)height {
Expand Down

0 comments on commit 6f84dcf

Please sign in to comment.