Skip to content

Commit

Permalink
Merge pull request MiMo42#33 from Eitot/spm-fix
Browse files Browse the repository at this point in the history
Add missing header to SPM public header and insert NSBundle macro
  • Loading branch information
barijaona authored Dec 1, 2020
2 parents 58c9333 + 3a574dd commit 658a980
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 11 deletions.
11 changes: 1 addition & 10 deletions MMTabBarView/MMTabBarView/MMOverflowPopUpButton.m
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,10 @@
#import "MMOverflowPopUpButton.h"

#import "MMOverflowPopUpButtonCell.h"
// #import "MMTabBarView.h"
#import "MMTabBarView.h"

NS_ASSUME_NONNULL_BEGIN

#define StaticImage(name) \
static NSImage* _static##name##Image() \
{ \
static NSImage* image = nil; \
if (!image) \
image = [[NSBundle bundleForClass:MMOverflowPopUpButtonCell.class] imageForResource:@#name]; \
return image; \
}

@interface MMOverflowPopUpButton ()

@property (assign) CGFloat secondImageAlpha;
Expand Down
6 changes: 5 additions & 1 deletion MMTabBarView/MMTabBarView/MMTabBarView.m
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,11 @@ + (NSBundle *)bundle;
{
static NSBundle *bundle = nil;
if (!bundle) {
bundle = [NSBundle bundleForClass:MMTabBarView.class];
#ifdef SWIFTPM_MODULE_BUNDLE
bundle = SWIFTPM_MODULE_BUNDLE;
#else
bundle = [NSBundle bundleForClass:MMTabBarView.class];
#endif
}
return bundle;
}
Expand Down
1 change: 1 addition & 0 deletions MMTabBarView/MMTabBarView/include/MMTarBarStyle-SPM.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
#import "../MMTabBarButtonCell.h"
#import "../MMTabBarItem.h"
#import "../MMTabBarView.Globals.h"
#import "../MMTabBarView.h"
#import "../MMTabStyle.h"
#import "../MMUnifiedTabStyle.h"
#import "../MMYosemiteTabStyle.h"
Expand Down
3 changes: 3 additions & 0 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ import PackageDescription
let package = Package(
name: "MMTabBarView",
defaultLocalization: LanguageTag("en"),
platforms: [
.macOS(.v10_10),
],
products: [
.library(name: "MMTabBarView", targets: ["MMTabBarView"]),
],
Expand Down

0 comments on commit 658a980

Please sign in to comment.