Browse Source

Unify framework names across platforms

- Remove header comments
- Rename tvOS target to use dash
- Closes #122
master
Reda Lemeden 4 years ago
parent
commit
2e196c221e
  1. 0
      Gifu-tvOS-Info.plist
  2. 4
      Gifu-tvOS/Gifu-tvOS.h
  3. 0
      Gifu-tvOS/Info.plist
  4. 38
      Gifu-tvOSTests/Gifu-tvOSTests.swift
  5. 0
      Gifu-tvOSTests/Info.plist
  6. 88
      Gifu.xcodeproj/project.pbxproj
  7. 19
      Gifu_tvOS/Gifu_tvOS.h

0
Gifu_tvOS-Info.plist → Gifu-tvOS-Info.plist

4
Gifu-tvOS/Gifu-tvOS.h

@ -0,0 +1,4 @@
#import <UIKit/UIKit.h>
FOUNDATION_EXPORT double Gifu-tvOSVersionNumber;
FOUNDATION_EXPORT const unsigned char Gifu-tvOSVersionString[];

0
Gifu_tvOS/Info.plist → Gifu-tvOS/Info.plist

38
Gifu_tvOSTests/Gifu_tvOSTests.swift → Gifu-tvOSTests/Gifu-tvOSTests.swift

@ -1,14 +1,6 @@
//
// Gifu_tvOSTests.swift
// Gifu_tvOSTests
//
// Created by Gruppioni Michele on 17/02/18.
// Copyright © 2018 Kaishin & Co. All rights reserved.
//
import XCTest
import ImageIO
@testable import Gifu_tvOS
@testable import Gifu
private let imageData = testImageDataNamed("mugen.gif")
private let staticImage = UIImage(data: imageData)!
@ -28,69 +20,69 @@ class GifuTests: XCTestCase {
var animator: Animator!
var originalFrameCount: Int!
let delegate = DummyAnimatable()
override func setUp() {
super.setUp()
animator = Animator(withDelegate: delegate)
animator.prepareForAnimation(withGIFData: imageData, size: staticImage.size, contentMode: .scaleToFill)
originalFrameCount = 44
}
func testIsAnimatable() {
XCTAssertNotNil(animator.frameStore)
guard let store = animator.frameStore else { return }
XCTAssertTrue(store.isAnimatable)
}
func testCurrentFrame() {
XCTAssertNotNil(animator.frameStore)
guard let store = animator.frameStore else { return }
XCTAssertEqual(store.currentFrameIndex, 0)
}
func testFramePreload() {
XCTAssertNotNil(animator.frameStore)
guard let store = animator.frameStore else { return }
let expectation = self.expectation(description: "frameDuration")
store.prepareFrames {
let animatedFrameCount = store.animatedFrames.count
XCTAssertEqual(animatedFrameCount, self.originalFrameCount)
XCTAssertNotNil(store.frame(at: preloadFrameCount - 1))
XCTAssertNil(store.frame(at: preloadFrameCount + 1)?.images)
XCTAssertEqual(store.currentFrameIndex, 0)
store.shouldChangeFrame(with: 1.0) { hasNewFrame in
XCTAssertTrue(hasNewFrame)
XCTAssertEqual(store.currentFrameIndex, 1)
expectation.fulfill()
}
}
waitForExpectations(timeout: 1.0) { error in
if let error = error {
print("Error: \(error.localizedDescription)")
}
}
}
func testFrameInfo() {
XCTAssertNotNil(animator.frameStore)
guard let store = animator.frameStore else { return }
let expectation = self.expectation(description: "testFrameInfoIsAccurate")
store.prepareFrames {
let frameDuration = store.frame(at: 5)?.duration ?? 0
XCTAssertTrue((frameDuration - 0.05) < 0.00001)
let imageSize = store.frame(at: 5)?.size ?? CGSize.zero
XCTAssertEqual(imageSize, staticImage.size)
expectation.fulfill()
}
waitForExpectations(timeout: 1.0) { error in
if let error = error {
print("Error: \(error.localizedDescription)")

0
Gifu_tvOSTests/Info.plist → Gifu-tvOSTests/Info.plist

88
Gifu.xcodeproj/project.pbxproj

@ -20,8 +20,8 @@
00B8C7961A3650EE00C188E7 /* Gifu.h in Headers */ = {isa = PBXBuildFile; fileRef = 00B8C7951A3650EE00C188E7 /* Gifu.h */; settings = {ATTRIBUTES = (Public, ); }; };
00BF42CC1D99A1DC00C6F28D /* GIFAnimatable.swift in Sources */ = {isa = PBXBuildFile; fileRef = 00BF42CB1D99A1DC00C6F28D /* GIFAnimatable.swift */; };
00DD26EE1DA9643800A0F683 /* UIImageView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 00DD26ED1DA9643800A0F683 /* UIImageView.swift */; };
71E8B2E620387D830037BA62 /* Gifu_tvOS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 71E8B2DD20387D830037BA62 /* Gifu_tvOS.framework */; };
71E8B2ED20387D830037BA62 /* Gifu_tvOS.h in Headers */ = {isa = PBXBuildFile; fileRef = 71E8B2DF20387D830037BA62 /* Gifu_tvOS.h */; settings = {ATTRIBUTES = (Public, ); }; };
71E8B2E620387D830037BA62 /* Gifu.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 71E8B2DD20387D830037BA62 /* Gifu.framework */; };
71E8B2ED20387D830037BA62 /* Gifu-tvOS.h in Headers */ = {isa = PBXBuildFile; fileRef = 71E8B2DF20387D830037BA62 /* Gifu-tvOS.h */; settings = {ATTRIBUTES = (Public, ); }; };
71E8B2F420387D8E0037BA62 /* AnimatedFrame.swift in Sources */ = {isa = PBXBuildFile; fileRef = EAF49CB01A3B6EEB00B395DF /* AnimatedFrame.swift */; };
71E8B2F520387D8E0037BA62 /* Animator.swift in Sources */ = {isa = PBXBuildFile; fileRef = 00978B6B1D9C6D2A00A6575F /* Animator.swift */; };
71E8B2F620387D8E0037BA62 /* FrameStore.swift in Sources */ = {isa = PBXBuildFile; fileRef = 005656EC1A6F14D6008A0ED1 /* FrameStore.swift */; };
@ -34,7 +34,7 @@
71E8B2FD20387D950037BA62 /* ImageSourceHelpers.swift in Sources */ = {isa = PBXBuildFile; fileRef = 00B8C75C1A364DCE00C188E7 /* ImageSourceHelpers.swift */; };
71E8B30220387E1E0037BA62 /* nailed.gif in Resources */ = {isa = PBXBuildFile; fileRef = 71E8B30020387E1E0037BA62 /* nailed.gif */; };
71E8B30320387E1E0037BA62 /* mugen.gif in Resources */ = {isa = PBXBuildFile; fileRef = 71E8B30120387E1E0037BA62 /* mugen.gif */; };
71E8B30420387ED70037BA62 /* Gifu_tvOSTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 71E8B2CE20387CE60037BA62 /* Gifu_tvOSTests.swift */; };
71E8B30420387ED70037BA62 /* Gifu-tvOSTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 71E8B2CE20387CE60037BA62 /* Gifu-tvOSTests.swift */; };
EAF49C7F1A3A4DE000B395DF /* UIImage.swift in Sources */ = {isa = PBXBuildFile; fileRef = EAF49C7E1A3A4DE000B395DF /* UIImage.swift */; };
EAF49CB11A3B6EEB00B395DF /* AnimatedFrame.swift in Sources */ = {isa = PBXBuildFile; fileRef = EAF49CB01A3B6EEB00B395DF /* AnimatedFrame.swift */; };
/* End PBXBuildFile section */
@ -52,7 +52,7 @@
containerPortal = 00B8C7351A364DA400C188E7 /* Project object */;
proxyType = 1;
remoteGlobalIDString = 71E8B2DC20387D830037BA62;
remoteInfo = Gifu_tvOS;
remoteInfo = "Gifu-tvOS";
};
/* End PBXContainerItemProxy section */
@ -73,13 +73,13 @@
00B8C7951A3650EE00C188E7 /* Gifu.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = Gifu.h; sourceTree = "<group>"; };
00BF42CB1D99A1DC00C6F28D /* GIFAnimatable.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GIFAnimatable.swift; sourceTree = "<group>"; };
00DD26ED1DA9643800A0F683 /* UIImageView.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIImageView.swift; sourceTree = "<group>"; };
71E8B2B82038784C0037BA62 /* Gifu_tvOS-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = "Gifu_tvOS-Info.plist"; path = "/Users/gruppionim/Documents/Developer/Github/Gifu/Gifu_tvOS-Info.plist"; sourceTree = "<absolute>"; };
71E8B2CE20387CE60037BA62 /* Gifu_tvOSTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Gifu_tvOSTests.swift; sourceTree = "<group>"; };
71E8B2B82038784C0037BA62 /* Gifu-tvOS-Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = "Gifu-tvOS-Info.plist"; path = "/Users/gruppionim/Documents/Developer/Github/Gifu/Gifu-tvOS-Info.plist"; sourceTree = "<absolute>"; };
71E8B2CE20387CE60037BA62 /* Gifu-tvOSTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Gifu-tvOSTests.swift"; sourceTree = "<group>"; };
71E8B2D020387CE60037BA62 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
71E8B2DD20387D830037BA62 /* Gifu_tvOS.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Gifu_tvOS.framework; sourceTree = BUILT_PRODUCTS_DIR; };
71E8B2DF20387D830037BA62 /* Gifu_tvOS.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = Gifu_tvOS.h; sourceTree = "<group>"; };
71E8B2DD20387D830037BA62 /* Gifu.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Gifu.framework; sourceTree = BUILT_PRODUCTS_DIR; };
71E8B2DF20387D830037BA62 /* Gifu-tvOS.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "Gifu-tvOS.h"; sourceTree = "<group>"; };
71E8B2E020387D830037BA62 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
71E8B2E520387D830037BA62 /* Gifu_tvOSTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = Gifu_tvOSTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
71E8B2E520387D830037BA62 /* Gifu-tvOSTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Gifu-tvOSTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; };
71E8B30020387E1E0037BA62 /* nailed.gif */ = {isa = PBXFileReference; lastKnownFileType = image.gif; path = nailed.gif; sourceTree = "<group>"; };
71E8B30120387E1E0037BA62 /* mugen.gif */ = {isa = PBXFileReference; lastKnownFileType = image.gif; path = mugen.gif; sourceTree = "<group>"; };
EAF49C7E1A3A4DE000B395DF /* UIImage.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = UIImage.swift; sourceTree = "<group>"; };
@ -113,7 +113,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
71E8B2E620387D830037BA62 /* Gifu_tvOS.framework in Frameworks */,
71E8B2E620387D830037BA62 /* Gifu.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -174,12 +174,12 @@
isa = PBXGroup;
children = (
009BD1371BBC7F6500FC982B /* GifuTests */,
71E8B2CD20387CE60037BA62 /* Gifu_tvOSTests */,
71E8B2DE20387D830037BA62 /* Gifu_tvOS */,
71E8B2CD20387CE60037BA62 /* Gifu-tvOSTests */,
71E8B2DE20387D830037BA62 /* Gifu-tvOS */,
00B8C73F1A364DA400C188E7 /* Products */,
00B8C75A1A364DBE00C188E7 /* Source */,
00B8C7411A364DA400C188E7 /* Supporting Files */,
71E8B2B82038784C0037BA62 /* Gifu_tvOS-Info.plist */,
71E8B2B82038784C0037BA62 /* Gifu-tvOS-Info.plist */,
);
sourceTree = "<group>";
};
@ -188,8 +188,8 @@
children = (
00B8C73E1A364DA400C188E7 /* Gifu.framework */,
009BD1361BBC7F6500FC982B /* GifuTests.xctest */,
71E8B2DD20387D830037BA62 /* Gifu_tvOS.framework */,
71E8B2E520387D830037BA62 /* Gifu_tvOSTests.xctest */,
71E8B2DD20387D830037BA62 /* Gifu.framework */,
71E8B2E520387D830037BA62 /* Gifu-tvOSTests.xctest */,
);
name = Products;
sourceTree = "<group>";
@ -213,23 +213,23 @@
path = Source;
sourceTree = "<group>";
};
71E8B2CD20387CE60037BA62 /* Gifu_tvOSTests */ = {
71E8B2CD20387CE60037BA62 /* Gifu-tvOSTests */ = {
isa = PBXGroup;
children = (
71E8B2FF20387E1E0037BA62 /* Images */,
71E8B2CE20387CE60037BA62 /* Gifu_tvOSTests.swift */,
71E8B2CE20387CE60037BA62 /* Gifu-tvOSTests.swift */,
71E8B2D020387CE60037BA62 /* Info.plist */,
);
path = Gifu_tvOSTests;
path = "Gifu-tvOSTests";
sourceTree = "<group>";
};
71E8B2DE20387D830037BA62 /* Gifu_tvOS */ = {
71E8B2DE20387D830037BA62 /* Gifu-tvOS */ = {
isa = PBXGroup;
children = (
71E8B2DF20387D830037BA62 /* Gifu_tvOS.h */,
71E8B2DF20387D830037BA62 /* Gifu-tvOS.h */,
71E8B2E020387D830037BA62 /* Info.plist */,
);
path = Gifu_tvOS;
path = "Gifu-tvOS";
sourceTree = "<group>";
};
71E8B2FF20387E1E0037BA62 /* Images */ = {
@ -257,7 +257,7 @@
isa = PBXHeadersBuildPhase;
buildActionMask = 2147483647;
files = (
71E8B2ED20387D830037BA62 /* Gifu_tvOS.h in Headers */,
71E8B2ED20387D830037BA62 /* Gifu-tvOS.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -301,9 +301,9 @@
productReference = 00B8C73E1A364DA400C188E7 /* Gifu.framework */;
productType = "com.apple.product-type.framework";
};
71E8B2DC20387D830037BA62 /* Gifu_tvOS */ = {
71E8B2DC20387D830037BA62 /* Gifu-tvOS */ = {
isa = PBXNativeTarget;
buildConfigurationList = 71E8B2EE20387D830037BA62 /* Build configuration list for PBXNativeTarget "Gifu_tvOS" */;
buildConfigurationList = 71E8B2EE20387D830037BA62 /* Build configuration list for PBXNativeTarget "Gifu-tvOS" */;
buildPhases = (
71E8B2D820387D830037BA62 /* Sources */,
71E8B2D920387D830037BA62 /* Frameworks */,
@ -314,14 +314,14 @@
);
dependencies = (
);
name = Gifu_tvOS;
productName = Gifu_tvOS;
productReference = 71E8B2DD20387D830037BA62 /* Gifu_tvOS.framework */;
name = "Gifu-tvOS";
productName = "Gifu-tvOS";
productReference = 71E8B2DD20387D830037BA62 /* Gifu.framework */;
productType = "com.apple.product-type.framework";
};
71E8B2E420387D830037BA62 /* Gifu_tvOSTests */ = {
71E8B2E420387D830037BA62 /* Gifu-tvOSTests */ = {
isa = PBXNativeTarget;
buildConfigurationList = 71E8B2F120387D830037BA62 /* Build configuration list for PBXNativeTarget "Gifu_tvOSTests" */;
buildConfigurationList = 71E8B2F120387D830037BA62 /* Build configuration list for PBXNativeTarget "Gifu-tvOSTests" */;
buildPhases = (
71E8B2E120387D830037BA62 /* Sources */,
71E8B2E220387D830037BA62 /* Frameworks */,
@ -332,9 +332,9 @@
dependencies = (
71E8B2E820387D830037BA62 /* PBXTargetDependency */,
);
name = Gifu_tvOSTests;
productName = Gifu_tvOSTests;
productReference = 71E8B2E520387D830037BA62 /* Gifu_tvOSTests.xctest */;
name = "Gifu-tvOSTests";
productName = "Gifu-tvOSTests";
productReference = 71E8B2E520387D830037BA62 /* Gifu-tvOSTests.xctest */;
productType = "com.apple.product-type.bundle.unit-test";
};
/* End PBXNativeTarget section */
@ -380,8 +380,8 @@
targets = (
00B8C73D1A364DA400C188E7 /* Gifu */,
009BD1351BBC7F6500FC982B /* GifuTests */,
71E8B2DC20387D830037BA62 /* Gifu_tvOS */,
71E8B2E420387D830037BA62 /* Gifu_tvOSTests */,
71E8B2DC20387D830037BA62 /* Gifu-tvOS */,
71E8B2E420387D830037BA62 /* Gifu-tvOSTests */,
);
};
/* End PBXProject section */
@ -485,7 +485,7 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
71E8B30420387ED70037BA62 /* Gifu_tvOSTests.swift in Sources */,
71E8B30420387ED70037BA62 /* Gifu-tvOSTests.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
@ -499,7 +499,7 @@
};
71E8B2E820387D830037BA62 /* PBXTargetDependency */ = {
isa = PBXTargetDependency;
target = 71E8B2DC20387D830037BA62 /* Gifu_tvOS */;
target = 71E8B2DC20387D830037BA62 /* Gifu-tvOS */;
targetProxy = 71E8B2E720387D830037BA62 /* PBXContainerItemProxy */;
};
/* End PBXTargetDependency section */
@ -705,11 +705,11 @@
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
GCC_C_LANGUAGE_STANDARD = gnu11;
INFOPLIST_FILE = Gifu_tvOS/Info.plist;
INFOPLIST_FILE = "Gifu-tvOS/Info.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = "co.kaishin.gifu.Gifu-tvOS";
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
PRODUCT_NAME = Gifu;
SDKROOT = appletvos;
SKIP_INSTALL = YES;
SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
@ -736,11 +736,11 @@
DYLIB_CURRENT_VERSION = 1;
DYLIB_INSTALL_NAME_BASE = "@rpath";
GCC_C_LANGUAGE_STANDARD = gnu11;
INFOPLIST_FILE = Gifu_tvOS/Info.plist;
INFOPLIST_FILE = "Gifu-tvOS/Info.plist";
INSTALL_PATH = "$(LOCAL_LIBRARY_DIR)/Frameworks";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = "co.kaishin.gifu.Gifu-tvOS";
PRODUCT_NAME = "$(TARGET_NAME:c99extidentifier)";
PRODUCT_NAME = Gifu;
SDKROOT = appletvos;
SKIP_INSTALL = YES;
SWIFT_OPTIMIZATION_LEVEL = "-Owholemodule";
@ -762,7 +762,7 @@
CODE_SIGN_STYLE = Automatic;
DEBUG_INFORMATION_FORMAT = dwarf;
GCC_C_LANGUAGE_STANDARD = gnu11;
INFOPLIST_FILE = Gifu_tvOSTests/Info.plist;
INFOPLIST_FILE = "Gifu-tvOSTests/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = "co.kaishin.gifu.Gifu-tvOSTests";
PRODUCT_NAME = "$(TARGET_NAME)";
@ -787,7 +787,7 @@
COPY_PHASE_STRIP = NO;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
GCC_C_LANGUAGE_STANDARD = gnu11;
INFOPLIST_FILE = Gifu_tvOSTests/Info.plist;
INFOPLIST_FILE = "Gifu-tvOSTests/Info.plist";
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = "co.kaishin.gifu.Gifu-tvOSTests";
PRODUCT_NAME = "$(TARGET_NAME)";
@ -829,7 +829,7 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
71E8B2EE20387D830037BA62 /* Build configuration list for PBXNativeTarget "Gifu_tvOS" */ = {
71E8B2EE20387D830037BA62 /* Build configuration list for PBXNativeTarget "Gifu-tvOS" */ = {
isa = XCConfigurationList;
buildConfigurations = (
71E8B2EF20387D830037BA62 /* Debug */,
@ -838,7 +838,7 @@
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
71E8B2F120387D830037BA62 /* Build configuration list for PBXNativeTarget "Gifu_tvOSTests" */ = {
71E8B2F120387D830037BA62 /* Build configuration list for PBXNativeTarget "Gifu-tvOSTests" */ = {
isa = XCConfigurationList;
buildConfigurations = (
71E8B2F220387D830037BA62 /* Debug */,

19
Gifu_tvOS/Gifu_tvOS.h

@ -1,19 +0,0 @@
//
// Gifu_tvOS.h
// Gifu_tvOS
//
// Created by Gruppioni Michele on 17/02/18.
// Copyright © 2018 Kaishin & Co. All rights reserved.
//
#import <UIKit/UIKit.h>
//! Project version number for Gifu_tvOS.
FOUNDATION_EXPORT double Gifu_tvOSVersionNumber;
//! Project version string for Gifu_tvOS.
FOUNDATION_EXPORT const unsigned char Gifu_tvOSVersionString[];
// In this header, you should import all the public headers of your framework using statements like #import <Gifu_tvOS/PublicHeader.h>
Loading…
Cancel
Save