This commit is contained in:
Reda Lemeden 2014-09-10 21:28:19 +02:00
parent 4a3816c75f
commit 0e48455fe3
20 changed files with 801 additions and 7 deletions

17
.gitignore vendored Normal file
View File

@ -0,0 +1,17 @@
*.mode1
*.mode1v3
*.mode2v3
*.perspective
*.perspectivev3
*.pbxuser
*.xccheckout
xcuserdata
build/
*.o
*.LinkFileList
*.hmap
*~.nib/
*.swp
*~
*.dat
*.dep

View File

@ -1,6 +1,6 @@
<img src="https://dl.dropboxusercontent.com/u/148921/assets/logo.svg" width="100" /> <img src="https://db.tt/mZ1iMNXO" width="100" />
Adds performant animated GIF support to UIKit, without subclassing `UIImageView`. Check out the __[demo](#demo-app)__. If you're looking for the Japanese prefecture, click [here](https://goo.gl/maps/CCeAc). Adds performant animated GIF support to UIKit, without subclassing `UIImageView`. If you're looking for the Japanese prefecture, click [here](https://goo.gl/maps/CCeAc).
#### Why? #### Why?
@ -17,7 +17,7 @@ The figure below summarizes how this works in practice. Given an image
containing 10 frames, Gifu will load the current frame (red), pre-load the next two frames in this example (orange), containing 10 frames, Gifu will load the current frame (red), pre-load the next two frames in this example (orange),
and nullify all the other frames to free up memory (gray): and nullify all the other frames to free up memory (gray):
<img src="https://raw.githubusercontent.com/kaishin/gifu/master/figure.gif" width="300" /> <img src="https://db.tt/ZLfx23hg" width="300" />
#### Usage #### Usage
@ -42,9 +42,7 @@ The `isAnimating()` method returns the current animation state of the view.
#### Demo App #### Demo App
For an example, check out the demo app [here](https://github.com/kaishin/gifu/tree/demo) (requires Xcode 6). <img src="https://db.tt/ZoUNLHGp" width="300" />
<img src="https://raw.githubusercontent.com/kaishin/gifu/demo/demo.gif" width="300" />
#### Compatibility #### Compatibility

View File

@ -0,0 +1,26 @@
{
"images" : [
{
"size" : "29x29",
"idiom" : "iphone",
"filename" : "New icon-Small@2x.png",
"scale" : "2x"
},
{
"size" : "40x40",
"idiom" : "iphone",
"filename" : "New icon-Small-40@2x.png",
"scale" : "2x"
},
{
"size" : "60x60",
"idiom" : "iphone",
"filename" : "New icon-60@2x.png",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 31 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

View File

@ -0,0 +1,23 @@
{
"images" : [
{
"orientation" : "portrait",
"idiom" : "iphone",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"subtype" : "retina4",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}

40
demo/Info.plist Normal file
View File

@ -0,0 +1,40 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>en</string>
<key>CFBundleExecutable</key>
<string>$(EXECUTABLE_NAME)</string>
<key>CFBundleIdentifier</key>
<string>co.kaishin.$(PRODUCT_NAME:rfc1034identifier)</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>$(PRODUCT_NAME)</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIMainStoryboardFile</key>
<string>Main</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
</dict>
</plist>

103
demo/Main.storyboard Normal file
View File

@ -0,0 +1,103 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="6206.9" systemVersion="13E28" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="vXZ-lx-hvc">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="7026.1"/>
<capability name="Aspect ratio constraints" minToolsVersion="5.1"/>
</dependencies>
<scenes>
<!--Gifu-->
<scene sceneID="ufC-wZ-h7g">
<objects>
<viewController title="Gifu" id="vXZ-lx-hvc" customClass="ViewController" customModule="gifu_demo" customModuleProvider="target" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="jyV-Pf-zRb"/>
<viewControllerLayoutGuide type="bottom" id="2fi-mo-0CV"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="kh9-bI-dsS">
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="FSz-xF-Xds">
<rect key="frame" x="75" y="150" width="450" height="300"/>
<color key="backgroundColor" red="0.7725490196" green="0.1764705882" blue="0.1843137255" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="height" constant="300" id="oev-E3-JrW"/>
<constraint firstAttribute="width" secondItem="FSz-xF-Xds" secondAttribute="height" multiplier="1.5:1" id="vUc-PW-K4t"/>
</constraints>
</imageView>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="bFY-3J-OXr" customClass="FlatButton" customModule="gifu_demo" customModuleProvider="target">
<rect key="frame" x="275" y="509" width="50" height="50"/>
<constraints>
<constraint firstAttribute="height" constant="50" id="Lmc-xA-WNU"/>
<constraint firstAttribute="height" constant="50" id="d3c-zA-X4Y"/>
<constraint firstAttribute="width" constant="50" id="eYX-lm-C2V"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="tintColor" red="0.99444444444444446" green="1" blue="0.98888888888888893" alpha="1" colorSpace="calibratedRGB"/>
<state key="normal" title="❙❙"/>
<variation key="default">
<mask key="constraints">
<exclude reference="d3c-zA-X4Y"/>
</mask>
</variation>
<connections>
<action selector="toggleAnimation:" destination="vXZ-lx-hvc" eventType="touchUpInside" id="PvH-3E-LbB"/>
</connections>
</button>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Gifu" textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="c8Y-41-BaC">
<rect key="frame" x="283" y="45" width="42" height="20.5"/>
<constraints>
<constraint firstAttribute="width" relation="greaterThanOrEqual" constant="42" id="1Mg-oH-beY"/>
</constraints>
<fontDescription key="fontDescription" type="boldSystem" pointSize="17"/>
<color key="textColor" red="1" green="1" blue="1" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="Not the Japanese prefecture." textAlignment="center" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="wsv-cU-WO5">
<rect key="frame" x="217" y="69" width="175" height="13.5"/>
<constraints>
<constraint firstAttribute="width" constant="175" id="qtB-pf-agE"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="11"/>
<color key="textColor" red="1" green="1" blue="1" alpha="0.5" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<color key="backgroundColor" red="0.2304944545" green="0.24875254929999999" blue="0.2778563201" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="centerY" secondItem="bFY-3J-OXr" secondAttribute="centerY" id="09i-ag-RTM"/>
<constraint firstItem="bFY-3J-OXr" firstAttribute="top" secondItem="FSz-xF-Xds" secondAttribute="bottom" constant="-73" id="1KN-hB-V2y"/>
<constraint firstAttribute="centerX" secondItem="bFY-3J-OXr" secondAttribute="centerX" id="CNh-OD-Msi"/>
<constraint firstItem="c8Y-41-BaC" firstAttribute="top" secondItem="jyV-Pf-zRb" secondAttribute="bottom" constant="25" id="JHy-q1-JuJ"/>
<constraint firstAttribute="centerX" secondItem="c8Y-41-BaC" secondAttribute="centerX" constant="-4" id="Kc0-P5-KMZ"/>
<constraint firstItem="wsv-cU-WO5" firstAttribute="leading" secondItem="c8Y-41-BaC" secondAttribute="trailing" constant="-108" id="WMw-79-FUC"/>
<constraint firstItem="wsv-cU-WO5" firstAttribute="top" secondItem="c8Y-41-BaC" secondAttribute="bottom" constant="3.5" id="cLO-Rh-lrl"/>
<constraint firstItem="bFY-3J-OXr" firstAttribute="centerY" secondItem="FSz-xF-Xds" secondAttribute="centerY" constant="102" id="eTb-IQ-R1d"/>
<constraint firstAttribute="centerY" secondItem="FSz-xF-Xds" secondAttribute="centerY" id="lUc-8z-Gjn"/>
<constraint firstAttribute="centerX" secondItem="FSz-xF-Xds" secondAttribute="centerX" id="oih-yH-vRh"/>
<constraint firstItem="2fi-mo-0CV" firstAttribute="top" secondItem="bFY-3J-OXr" secondAttribute="bottom" constant="41" id="w4g-Xu-ht2"/>
<constraint firstItem="bFY-3J-OXr" firstAttribute="top" secondItem="FSz-xF-Xds" secondAttribute="bottom" constant="-73" id="wKy-oP-72d"/>
<constraint firstAttribute="centerX" secondItem="wsv-cU-WO5" secondAttribute="centerX" constant="-4.5" id="yLb-zR-gfU"/>
</constraints>
<variation key="default">
<mask key="constraints">
<exclude reference="09i-ag-RTM"/>
<exclude reference="1KN-hB-V2y"/>
<exclude reference="eTb-IQ-R1d"/>
<exclude reference="wKy-oP-72d"/>
</mask>
</variation>
</view>
<simulatedStatusBarMetrics key="simulatedStatusBarMetrics" statusBarStyle="lightContent"/>
<nil key="simulatedTopBarMetrics"/>
<nil key="simulatedBottomBarMetrics"/>
<connections>
<outlet property="button" destination="bFY-3J-OXr" id="MYJ-Xm-nTf"/>
<outlet property="imageView" destination="FSz-xF-Xds" id="gtV-MK-Fwd"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="x5A-6p-PRh" sceneMemberID="firstResponder"/>
</objects>
</scene>
</scenes>
</document>

View File

@ -0,0 +1,12 @@
import UIKit
@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate {
var window: UIWindow?
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool {
return true
}
}

View File

@ -0,0 +1,48 @@
import UIKit
class FlatButton: UIButton {
let horizontalPadding: CGFloat = 14.0
var buttonColor: UIColor?
override init(frame: CGRect) {
super.init(frame: frame)
customizeAppearance()
}
required init(coder aDecoder: NSCoder) {
super.init(coder: aDecoder)
customizeAppearance()
}
override func drawRect(rect: CGRect) {
layer.borderColor = tintColor.CGColor
setTitleColor(tintColor, forState: UIControlState.Normal)
setTitleColor(UIColor.whiteColor(), forState: UIControlState.Selected)
}
func customizeAppearance() {
let containsEdgeInsets = !UIEdgeInsetsEqualToEdgeInsets(contentEdgeInsets, UIEdgeInsetsZero)
contentEdgeInsets = containsEdgeInsets ? contentEdgeInsets : UIEdgeInsets(top: 0, left: 0, bottom: 0, right: 0)
layer.borderWidth = 2.0
layer.borderColor = tintColor.CGColor
layer.cornerRadius = frame.size.height / 2.0
layer.masksToBounds = true
}
override var tintColor: UIColor! {
get {
if let color = buttonColor {
return color
} else {
return super.tintColor
}
}
set {
super.tintColor = newValue
buttonColor = newValue
}
}
}

View File

@ -0,0 +1,27 @@
import UIKit
class ViewController: UIViewController {
@IBOutlet weak var imageView: UIImageView!
@IBOutlet weak var button: FlatButton!
override func viewDidLoad() {
super.viewDidLoad()
imageView.setAnimatableImage(named: "mugen.gif")
imageView.startAnimating()
UIApplication.sharedApplication().setStatusBarStyle(.LightContent, animated: false)
}
@IBAction func toggleAnimation(button: UIButton) {
if imageView.isAnimating {
imageView.stopAnimating()
button.layer.backgroundColor = UIColor.whiteColor().CGColor
button.setTitleColor(UIColor.blackColor(), forState: .Normal)
} else {
imageView.startAnimating()
button.layer.backgroundColor = UIColor.clearColor().CGColor
button.setTitleColor(UIColor.whiteColor(), forState: .Normal)
}
}
}

BIN
demo/mugen.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 933 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

View File

@ -0,0 +1,304 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
9D25870819BCCB0F00A55A18 /* mugen.gif in Resources */ = {isa = PBXBuildFile; fileRef = 9D25870619BCCB0F00A55A18 /* mugen.gif */; };
9D25870C19BD16FC00A55A18 /* Gifu.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9D25870919BD16FC00A55A18 /* Gifu.swift */; };
9D25870D19BD16FC00A55A18 /* ImageSourceHelpers.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9D25870A19BD16FC00A55A18 /* ImageSourceHelpers.swift */; };
9D25870E19BD16FC00A55A18 /* UIImageView+Gifu.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9D25870B19BD16FC00A55A18 /* UIImageView+Gifu.swift */; };
9D98823D19BC69CA00B790C6 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9D98823C19BC69CA00B790C6 /* AppDelegate.swift */; };
9D98823F19BC69CA00B790C6 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9D98823E19BC69CA00B790C6 /* ViewController.swift */; };
9D98824419BC69CA00B790C6 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 9D98824319BC69CA00B790C6 /* Images.xcassets */; };
9D98825A19BC69F600B790C6 /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 9D98825919BC69F600B790C6 /* Main.storyboard */; };
9D98826719BC874C00B790C6 /* FlatButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9D98826619BC874C00B790C6 /* FlatButton.swift */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
9D25870519BCCB0F00A55A18 /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
9D25870619BCCB0F00A55A18 /* mugen.gif */ = {isa = PBXFileReference; lastKnownFileType = image.gif; path = mugen.gif; sourceTree = "<group>"; };
9D25870919BD16FC00A55A18 /* Gifu.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Gifu.swift; sourceTree = "<group>"; };
9D25870A19BD16FC00A55A18 /* ImageSourceHelpers.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = ImageSourceHelpers.swift; sourceTree = "<group>"; };
9D25870B19BD16FC00A55A18 /* UIImageView+Gifu.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "UIImageView+Gifu.swift"; sourceTree = "<group>"; };
9D98823719BC69CA00B790C6 /* gifu-demo.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "gifu-demo.app"; sourceTree = BUILT_PRODUCTS_DIR; };
9D98823C19BC69CA00B790C6 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = AppDelegate.swift; path = classes/AppDelegate.swift; sourceTree = "<group>"; };
9D98823E19BC69CA00B790C6 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; name = ViewController.swift; path = classes/ViewController.swift; sourceTree = "<group>"; };
9D98824319BC69CA00B790C6 /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Images.xcassets; sourceTree = "<group>"; };
9D98825919BC69F600B790C6 /* Main.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; path = Main.storyboard; sourceTree = "<group>"; };
9D98826619BC874C00B790C6 /* FlatButton.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; name = FlatButton.swift; path = classes/FlatButton.swift; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
9D98823419BC69CA00B790C6 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
9D98822E19BC69CA00B790C6 = {
isa = PBXGroup;
children = (
9D98823919BC69CA00B790C6 /* gifu-demo */,
9D98823819BC69CA00B790C6 /* Products */,
);
sourceTree = "<group>";
};
9D98823819BC69CA00B790C6 /* Products */ = {
isa = PBXGroup;
children = (
9D98823719BC69CA00B790C6 /* gifu-demo.app */,
);
name = Products;
sourceTree = "<group>";
};
9D98823919BC69CA00B790C6 /* gifu-demo */ = {
isa = PBXGroup;
children = (
9D98826119BC6A9700B790C6 /* Gifu */,
9D98823C19BC69CA00B790C6 /* AppDelegate.swift */,
9D98823E19BC69CA00B790C6 /* ViewController.swift */,
9D98826619BC874C00B790C6 /* FlatButton.swift */,
9D98825919BC69F600B790C6 /* Main.storyboard */,
9D98824319BC69CA00B790C6 /* Images.xcassets */,
9D98823A19BC69CA00B790C6 /* Supporting Files */,
);
name = "gifu-demo";
path = demo;
sourceTree = "<group>";
};
9D98823A19BC69CA00B790C6 /* Supporting Files */ = {
isa = PBXGroup;
children = (
9D25870519BCCB0F00A55A18 /* Info.plist */,
9D25870619BCCB0F00A55A18 /* mugen.gif */,
);
name = "Supporting Files";
sourceTree = "<group>";
};
9D98826119BC6A9700B790C6 /* Gifu */ = {
isa = PBXGroup;
children = (
9D25870919BD16FC00A55A18 /* Gifu.swift */,
9D25870A19BD16FC00A55A18 /* ImageSourceHelpers.swift */,
9D25870B19BD16FC00A55A18 /* UIImageView+Gifu.swift */,
);
name = Gifu;
path = ../source;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
9D98823619BC69CA00B790C6 /* gifu-demo */ = {
isa = PBXNativeTarget;
buildConfigurationList = 9D98825319BC69CA00B790C6 /* Build configuration list for PBXNativeTarget "gifu-demo" */;
buildPhases = (
9D98823319BC69CA00B790C6 /* Sources */,
9D98823419BC69CA00B790C6 /* Frameworks */,
9D98823519BC69CA00B790C6 /* Resources */,
);
buildRules = (
);
dependencies = (
);
name = "gifu-demo";
productName = "gifu-demo";
productReference = 9D98823719BC69CA00B790C6 /* gifu-demo.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
9D98822F19BC69CA00B790C6 /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0600;
ORGANIZATIONNAME = "Kaishin & Co";
TargetAttributes = {
9D98823619BC69CA00B790C6 = {
CreatedOnToolsVersion = 6.0;
};
};
};
buildConfigurationList = 9D98823219BC69CA00B790C6 /* Build configuration list for PBXProject "gifu-demo" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 0;
knownRegions = (
en,
Base,
);
mainGroup = 9D98822E19BC69CA00B790C6;
productRefGroup = 9D98823819BC69CA00B790C6 /* Products */;
projectDirPath = "";
projectRoot = "";
targets = (
9D98823619BC69CA00B790C6 /* gifu-demo */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
9D98823519BC69CA00B790C6 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
9D98824419BC69CA00B790C6 /* Images.xcassets in Resources */,
9D25870819BCCB0F00A55A18 /* mugen.gif in Resources */,
9D98825A19BC69F600B790C6 /* Main.storyboard in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
9D98823319BC69CA00B790C6 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
9D25870C19BD16FC00A55A18 /* Gifu.swift in Sources */,
9D25870D19BD16FC00A55A18 /* ImageSourceHelpers.swift in Sources */,
9D98823F19BC69CA00B790C6 /* ViewController.swift in Sources */,
9D25870E19BD16FC00A55A18 /* UIImageView+Gifu.swift in Sources */,
9D98823D19BC69CA00B790C6 /* AppDelegate.swift in Sources */,
9D98826719BC874C00B790C6 /* FlatButton.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
9D98825119BC69CA00B790C6 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = (
"DEBUG=1",
"$(inherited)",
);
GCC_SYMBOLS_PRIVATE_EXTERN = NO;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
MTL_ENABLE_DEBUG_INFO = YES;
ONLY_ACTIVE_ARCH = YES;
SDKROOT = iphoneos;
SWIFT_OPTIMIZATION_LEVEL = "-Onone";
};
name = Debug;
};
9D98825219BC69CA00B790C6 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
CLANG_CXX_LIBRARY = "libc++";
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_WARN_BOOL_CONVERSION = YES;
CLANG_WARN_CONSTANT_CONVERSION = YES;
CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
CLANG_WARN_EMPTY_BODY = YES;
CLANG_WARN_ENUM_CONVERSION = YES;
CLANG_WARN_INT_CONVERSION = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_UNREACHABLE_CODE = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
COPY_PHASE_STRIP = YES;
ENABLE_NS_ASSERTIONS = NO;
ENABLE_STRICT_OBJC_MSGSEND = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNDECLARED_SELECTOR = YES;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GCC_WARN_UNUSED_FUNCTION = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
MTL_ENABLE_DEBUG_INFO = NO;
SDKROOT = iphoneos;
VALIDATE_PRODUCT = YES;
};
name = Release;
};
9D98825419BC69CA00B790C6 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
INFOPLIST_FILE = demo/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 7.1;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Debug;
};
9D98825519BC69CA00B790C6 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
INFOPLIST_FILE = demo/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 7.1;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
PRODUCT_NAME = "$(TARGET_NAME)";
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
9D98823219BC69CA00B790C6 /* Build configuration list for PBXProject "gifu-demo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
9D98825119BC69CA00B790C6 /* Debug */,
9D98825219BC69CA00B790C6 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
9D98825319BC69CA00B790C6 /* Build configuration list for PBXNativeTarget "gifu-demo" */ = {
isa = XCConfigurationList;
buildConfigurations = (
9D98825419BC69CA00B790C6 /* Debug */,
9D98825519BC69CA00B790C6 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 9D98822F19BC69CA00B790C6 /* Project object */;
}

View File

@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:gifu-demo.xcodeproj">
</FileRef>
</Workspace>

View File

@ -0,0 +1,53 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IDESourceControlProjectFavoriteDictionaryKey</key>
<false/>
<key>IDESourceControlProjectIdentifier</key>
<string>6D75083F-F54B-476A-805A-7C4AECACA1D4</string>
<key>IDESourceControlProjectName</key>
<string>gifu-demo</string>
<key>IDESourceControlProjectOriginsDictionary</key>
<dict>
<key>4F201322DFCBE25D8D43B7E20BE17D99A7146515</key>
<string>/Users/reda/Developer/iOS/gifu</string>
<key>EA0259997B7ABC22E2A236D9C38DE21665A9128B</key>
<string>github.com:kaishin/gifu-demo.git</string>
</dict>
<key>IDESourceControlProjectPath</key>
<string>gifu-demo.xcodeproj</string>
<key>IDESourceControlProjectRelativeInstallPathDictionary</key>
<dict>
<key>4F201322DFCBE25D8D43B7E20BE17D99A7146515</key>
<string>../../../gifu</string>
<key>EA0259997B7ABC22E2A236D9C38DE21665A9128B</key>
<string>../..</string>
</dict>
<key>IDESourceControlProjectURL</key>
<string>github.com:kaishin/gifu-demo.git</string>
<key>IDESourceControlProjectVersion</key>
<integer>111</integer>
<key>IDESourceControlProjectWCCIdentifier</key>
<string>EA0259997B7ABC22E2A236D9C38DE21665A9128B</string>
<key>IDESourceControlProjectWCConfigurations</key>
<array>
<dict>
<key>IDESourceControlRepositoryExtensionIdentifierKey</key>
<string>public.vcs.git</string>
<key>IDESourceControlWCCIdentifierKey</key>
<string>4F201322DFCBE25D8D43B7E20BE17D99A7146515</string>
<key>IDESourceControlWCCName</key>
<string>gifu</string>
</dict>
<dict>
<key>IDESourceControlRepositoryExtensionIdentifierKey</key>
<string>public.vcs.git</string>
<key>IDESourceControlWCCIdentifierKey</key>
<string>EA0259997B7ABC22E2A236D9C38DE21665A9128B</string>
<key>IDESourceControlWCCName</key>
<string>gifu-demo</string>
</dict>
</array>
</dict>
</plist>

View File

@ -0,0 +1,110 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "0600"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9D98823619BC69CA00B790C6"
BuildableName = "gifu-demo.app"
BlueprintName = "gifu-demo"
ReferencedContainer = "container:gifu-demo.xcodeproj">
</BuildableReference>
</BuildActionEntry>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "NO"
buildForArchiving = "NO"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9D98824819BC69CA00B790C6"
BuildableName = "gifu-demoTests.xctest"
BlueprintName = "gifu-demoTests"
ReferencedContainer = "container:gifu-demo.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES"
buildConfiguration = "Debug">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9D98824819BC69CA00B790C6"
BuildableName = "gifu-demoTests.xctest"
BlueprintName = "gifu-demoTests"
ReferencedContainer = "container:gifu-demo.xcodeproj">
</BuildableReference>
</TestableReference>
</Testables>
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9D98823619BC69CA00B790C6"
BuildableName = "gifu-demo.app"
BlueprintName = "gifu-demo"
ReferencedContainer = "container:gifu-demo.xcodeproj">
</BuildableReference>
</MacroExpansion>
</TestAction>
<LaunchAction
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
buildConfiguration = "Debug"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
allowLocationSimulation = "YES">
<BuildableProductRunnable>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9D98823619BC69CA00B790C6"
BuildableName = "gifu-demo.app"
BlueprintName = "gifu-demo"
ReferencedContainer = "container:gifu-demo.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
buildConfiguration = "Release"
debugDocumentVersioning = "YES">
<BuildableProductRunnable>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "9D98823619BC69CA00B790C6"
BuildableName = "gifu-demo.app"
BlueprintName = "gifu-demo"
ReferencedContainer = "container:gifu-demo.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>

View File

@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>SchemeUserState</key>
<dict>
<key>gifu-demo.xcscheme</key>
<dict>
<key>orderHint</key>
<integer>0</integer>
</dict>
</dict>
<key>SuppressBuildableAutocreation</key>
<dict>
<key>9D98823619BC69CA00B790C6</key>
<dict>
<key>primary</key>
<true/>
</dict>
<key>9D98824819BC69CA00B790C6</key>
<dict>
<key>primary</key>
<true/>
</dict>
</dict>
</dict>
</plist>

View File

@ -1 +0,0 @@
<svg width="554" height="296" viewBox="0 0 554 296" xmlns="http://www.w3.org/2000/svg"><title>logo</title><path d="M80.605 290.018c18.085-3.74 19.33-18.23 19.035-31.52-.553-24.996-3.087-49.95-4.852-74.918-.252-3.556-.817-7.09-2.4-10.57 1.677 26.267 3.352 52.536 5.028 78.805-.98.11-1.958.217-2.937.326l-9.226-66.033c-4.26 5.97-7.704 11.432-11.782 16.372-8.46 10.248-18.08 18.908-32.39 19.51-14.98.634-26.492-7.462-33.165-23.21-9.303-21.957-9.165-44.605-4.688-67.502 3.388-17.325 7.614-34.3 18.42-48.944 11.017-14.93 24.64-24.27 43.997-22.757 8.402.657 16.857 1.057 25.16 2.38 3.658.583 6.996 3.176 10.477 4.858-2.623 2.92-4.746 6.67-7.96 8.61C83 81.644 74.185 89.274 67.863 99.57c-12.028 19.6-18.885 40.577-16.245 63.89.73 6.465 2.686 12.793 10.053 14.29 7.28 1.477 11.465-3.658 15.178-8.954 4.092-5.836 5.633-12.058 6.203-19.42 1.653-21.33 4.776-42.545 7.412-63.796.775-6.255 5.073-9.722 10.53-11.756 16.042-5.987 32.465-6.588 49.092-2.9 4.56 1.013 6.068 2.7 5.22 8.517-2.77 19.044-4.68 38.262-5.82 57.48-1.77 29.85-2.635 59.756-3.88 89.638-.745 17.94-5.626 34.668-15.025 49.97-11.346 18.475-35.844 21.76-49.977 13.49zm319.572-215c2.874 4.184 6.117 8.17 8.52 12.61 2.36 4.355 3.867 9.172 6.277 13.548.378-12.366-4.93-22.183-15.172-30.278 2.415-1.72 3.807-3.52 5.384-3.7 12.098-1.374 24.23-3.245 36.355-3.293 7.49-.03 12.867 7 12.89 16.687.04 17.053-1.27 34.107-1.923 51.163-.38 9.863-.864 19.736-.736 29.598.052 3.998 1.256 8.094 2.55 11.938 1.714 5.095 4.024 10.24 10.454 10.553 6.832.333 9.372-5.234 10.42-10.213 3.703-17.618 7.235-35.317 9.658-53.145 1.912-14.064 2.013-28.367 3.074-42.552.79-10.572 6.463-16.17 16.955-14.966 9.007 1.034 17.873 3.685 26.618 6.244 1.86.546 3.966 3.674 4.19 5.797.958 9.088 1.566 18.24 1.733 27.377.51 27.957.716 55.92 1.156 83.877.05 3.106.913 6.19 1.28 9.296.706 5.98 2.436 10.98 12.605 10.352-3.357 3.965-4.844 7.346-7.286 8.31-8.844 3.495-17.87 6.734-27.095 8.99-7.303 1.785-12.896-2.062-15.197-9.107-4.317-13.22-8.085-26.62-12.08-39.945-.48 1.448-1.024 3.598-1.89 5.61-4.37 10.145-7.716 20.94-13.474 30.24-13.254 21.404-48.027 20.556-61.72-.767-6.94-10.81-9.136-22.766-8.522-35.25.805-16.362 2.353-32.69 3.248-49.05.866-15.836-.09-31.39-9.522-45.12-.608-.885-.672-2.144-.987-3.23l2.24-1.57zm-27.953-8.18c-3.107-5.528-5.832-10.79-8.946-15.81-4.286-6.917-8.312-14.114-13.483-20.33-4.7-5.645-9.926-4.75-13.973 1.51-1.512 2.34-2.818 5.305-2.873 8.013-.286 13.93-.133 27.866-.133 41.862 10.77.577 20.584.817 30.34 1.706 9.337.852 10.91 4.568 9.53 13.84-.78 5.244-.213 10.127-3.425 15.247-2.473 3.945-4.742 5.57-8.86 5.59-6.92.032-13.836.01-20.234.01-1.015 20.058-1.325 38.606-3.037 57.022-2.315 24.91-6.972 49.245-23.563 69.484-8.557 10.44-18.384 19.14-31.013 24.217-2.946 1.184-6.276 1.412-11.228 2.46 1.173-3.697 1.353-5.857 2.425-7.395 11.86-17.004 15.36-36.577 15.207-56.447-.243-31.445-2.196-62.877-3.517-96.63l-33.863 6.857c4.967-10.72 14.92-14.72 24.595-18.66 5.23-2.132 6.305-4.91 6.01-10.292-.932-17.07-2.248-34.24-1.35-51.26 1.515-28.694 22.235-41.464 49.464-31.98 2.476.863 5.753.84 8.25.006 24.418-8.15 44.476 6.76 43.088 33.02-.448 8.468-3.615 16.804-5.735 25.15-.223.874-1.78 1.41-3.676 2.812zm-38.928-43.21c-9.905 1.1-17.725 19.195-14.522 33.21 4.364-9.98 9.54-21.82 14.522-33.21zm-115.44 35.107c.68.393.873.558 1.096.625 23.365 6.97 26.693 12.72 23.494 37.28-3.387 26.015-6.897 52.062-8.76 78.21-.852 11.974 2.286 24.208 3.142 36.356.12 1.748-2.044 4.74-3.792 5.367-16.33 5.858-38.267-4.3-42.026-21.076-3.82-17.056-5.37-34.68-7.07-52.138-1.936-19.907-2.83-39.912-4.43-59.854-.364-4.52-1.132-9.223-2.845-13.374-2.56-6.203.198-8.534 5.55-9.42 7.784-1.292 15.62-2.282 23.738-3.445 1.056-6.787-2.59-10.928-8.583-13.688-8.305-3.828-16.94-7.082-24.82-11.647-11.112-6.44-11.403-12.756-.948-20.323 27.225-19.7 61.89-11.386 81.47 9.578 8.316 8.903 5.347 19.15-6.123 23.27-5.63 2.022-11.6 3.44-17.534 4.155-6.402.773-10.263 3.574-11.56 10.122zm5.62 115.586c.54.07 1.08.137 1.62.205 1.847-24.102 3.696-48.204 5.545-72.306l-3.05-.185c-1.37 24.095-2.74 48.19-4.113 72.286zm109.82-150.693c-4.98 11.392-10.158 23.232-14.522 33.21-3.203-14.014 4.617-32.108 14.522-33.21z" fill="#FF9000"/></svg>

Before

Width:  |  Height:  |  Size: 4.0 KiB