Skip to content
This repository has been archived by the owner on Feb 6, 2023. It is now read-only.

Commit

Permalink
feat: Add support for audio play in stepToFrame.
Browse files Browse the repository at this point in the history
  • Loading branch information
errnull committed Sep 22, 2019
1 parent fcf731d commit 873f8e4
Show file tree
Hide file tree
Showing 11 changed files with 322 additions and 45 deletions.
2 changes: 1 addition & 1 deletion Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -64,4 +64,4 @@ SPEC CHECKSUMS:

PODFILE CHECKSUM: 7f6714245d47e69d2933463289e4c4d6de65b831

COCOAPODS: 1.6.1
COCOAPODS: 1.7.3
6 changes: 3 additions & 3 deletions SVGAPlayer.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@
TargetAttributes = {
90A676DC1D13A6DF008A69F3 = {
CreatedOnToolsVersion = 7.3;
DevelopmentTeam = 544P5CH38C;
DevelopmentTeam = TD97KS79S9;
};
90CB64C91EF290F400DAA382 = {
DevelopmentTeam = 8M2FQ87SLP;
Expand Down Expand Up @@ -582,7 +582,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_IDENTITY = "iPhone Developer";
DEVELOPMENT_TEAM = 544P5CH38C;
DEVELOPMENT_TEAM = TD97KS79S9;
INFOPLIST_FILE = SVGAPlayer/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
Expand All @@ -599,7 +599,7 @@
buildSettings = {
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
CODE_SIGN_IDENTITY = "iPhone Developer";
DEVELOPMENT_TEAM = 544P5CH38C;
DEVELOPMENT_TEAM = TD97KS79S9;
INFOPLIST_FILE = SVGAPlayer/Info.plist;
IPHONEOS_DEPLOYMENT_TARGET = 8.0;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
Expand Down
78 changes: 78 additions & 0 deletions SVGAPlayer.xcodeproj/xcshareddata/xcschemes/SVGAPlayer.xcscheme
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1100"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "90A676DC1D13A6DF008A69F3"
BuildableName = "SVGAPlayer.app"
BlueprintName = "SVGAPlayer"
ReferencedContainer = "container:SVGAPlayer.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "90A676DC1D13A6DF008A69F3"
BuildableName = "SVGAPlayer.app"
BlueprintName = "SVGAPlayer"
ReferencedContainer = "container:SVGAPlayer.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "90A676DC1D13A6DF008A69F3"
BuildableName = "SVGAPlayer.app"
BlueprintName = "SVGAPlayer"
ReferencedContainer = "container:SVGAPlayer.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
Original file line number Diff line number Diff line change
@@ -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>SVGAPlayer React.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>7</integer>
</dict>
<key>SVGAPlayer.xcscheme_^#shared#^_</key>
<dict>
<key>orderHint</key>
<integer>6</integer>
</dict>
</dict>
<key>SuppressBuildableAutocreation</key>
<dict>
<key>90A676DC1D13A6DF008A69F3</key>
<dict>
<key>primary</key>
<true/>
</dict>
</dict>
</dict>
</plist>
8 changes: 8 additions & 0 deletions SVGAPlayer.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<?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>IDEDidComputeMac32BitWarning</key>
<true/>
</dict>
</plist>
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
<?xml version="1.0" encoding="UTF-8"?>
<Bucket
uuid = "64DA03BB-C5DC-42D4-BADC-AD0639445B58"
type = "0"
version = "2.0">
<Breakpoints>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "3AE24567-7384-4566-B71B-DED67D03525A"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "SVGAPlayer/ViewController.m"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "66"
endingLineNumber = "66"
landmarkName = "-onSliderClick:"
landmarkType = "7">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "D8154CC8-03F2-40FD-87BF-47C3CFBDBFC5"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Source/SVGAPlayer.m"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "125"
endingLineNumber = "125"
landmarkName = "-stepToFrame:andPlay:"
landmarkType = "7">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "0AF589EC-210A-4B63-8DCF-18F1727DF3D5"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Source/SVGAPlayer.m"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "300"
endingLineNumber = "300"
landmarkName = "-update"
landmarkType = "7">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "08D33BAA-30CD-475A-A15C-BE5608038FCD"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Source/SVGAPlayer.m"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "304"
endingLineNumber = "304"
landmarkName = "-update"
landmarkType = "7">
</BreakpointContent>
</BreakpointProxy>
<BreakpointProxy
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
<BreakpointContent
uuid = "D6A59950-2B5E-4C3F-A760-A6B911356ECD"
shouldBeEnabled = "Yes"
ignoreCount = "0"
continueAfterRunningActions = "No"
filePath = "Source/SVGAPlayer.m"
startingColumnNumber = "9223372036854775807"
endingColumnNumber = "9223372036854775807"
startingLineNumber = "114"
endingLineNumber = "114"
landmarkName = "-clearAudios"
landmarkType = "7">
</BreakpointContent>
</BreakpointProxy>
</Breakpoints>
</Bucket>
15 changes: 15 additions & 0 deletions SVGAPlayer/Assets.xcassets/AppIcon.appiconset/Contents.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
{
"images" : [
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "2x"
},
{
"idiom" : "iphone",
"size" : "20x20",
"scale" : "3x"
},
{
"idiom" : "iphone",
"size" : "29x29",
Expand Down Expand Up @@ -29,6 +39,11 @@
"idiom" : "iphone",
"size" : "60x60",
"scale" : "3x"
},
{
"idiom" : "ios-marketing",
"size" : "1024x1024",
"scale" : "1x"
}
],
"info" : {
Expand Down
40 changes: 34 additions & 6 deletions SVGAPlayer/Base.lproj/Main.storyboard
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="14490.70" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="4uQ-1Q-oSI">
<device id="retina4_7" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="14868" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="4uQ-1Q-oSI">
<device id="retina4_7" orientation="portrait" appearance="light"/>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14490.49"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14824"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<scenes>
Expand Down Expand Up @@ -139,18 +137,47 @@
</constraints>
<connections>
<action selector="onSlide:" destination="BYZ-38-t0r" eventType="valueChanged" id="ra7-7t-qog"/>
<action selector="onSliderClick:" destination="BYZ-38-t0r" eventType="touchUpInside" id="Adw-EM-7q9"/>
</connections>
</slider>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="C20-qv-lcV">
<rect key="frame" x="178" y="132" width="31" height="30"/>
<state key="normal" title="开始"/>
<state key="selected" title="暂停"/>
<connections>
<action selector="onBeginButton:" destination="BYZ-38-t0r" eventType="touchUpInside" id="E08-3x-QFp"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="bja-sU-K2f">
<rect key="frame" x="118" y="132" width="31" height="30"/>
<state key="normal" title="快退"/>
<connections>
<action selector="onRetreatButton:" destination="BYZ-38-t0r" eventType="touchUpInside" id="gtQ-WY-bYg"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="7F2-zY-5ah">
<rect key="frame" x="235" y="132" width="31" height="30"/>
<state key="normal" title="快进"/>
<connections>
<action selector="onForwardButton:" destination="BYZ-38-t0r" eventType="touchUpInside" id="3Zv-gX-WB3"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
<constraints>
<constraint firstItem="wfy-db-euE" firstAttribute="top" secondItem="wYi-Zk-AVg" secondAttribute="bottom" id="1Yo-HY-RGm"/>
<constraint firstItem="C20-qv-lcV" firstAttribute="leading" secondItem="bja-sU-K2f" secondAttribute="trailing" constant="29" id="2Dj-2r-SGO"/>
<constraint firstItem="7F2-zY-5ah" firstAttribute="centerY" secondItem="bja-sU-K2f" secondAttribute="centerY" id="A2h-d2-lEJ"/>
<constraint firstItem="wYi-Zk-AVg" firstAttribute="leading" secondItem="8bC-Xf-vdC" secondAttribute="leading" constant="30" id="Anv-E0-INT"/>
<constraint firstItem="C20-qv-lcV" firstAttribute="centerY" secondItem="bja-sU-K2f" secondAttribute="centerY" id="E6S-89-f4n"/>
<constraint firstItem="cmN-DO-oLC" firstAttribute="centerX" secondItem="8bC-Xf-vdC" secondAttribute="centerX" id="HF3-PL-7Ua"/>
<constraint firstAttribute="trailing" secondItem="wYi-Zk-AVg" secondAttribute="trailing" constant="30" id="RKP-BR-fhw"/>
<constraint firstAttribute="trailingMargin" secondItem="7F2-zY-5ah" secondAttribute="trailing" constant="93" id="U0f-Fp-eBj"/>
<constraint firstItem="cmN-DO-oLC" firstAttribute="centerY" secondItem="8bC-Xf-vdC" secondAttribute="centerY" id="V4O-Ov-ZmN"/>
<constraint firstItem="cmN-DO-oLC" firstAttribute="leading" secondItem="8bC-Xf-vdC" secondAttribute="leadingMargin" id="aSq-Gs-nkk"/>
<constraint firstItem="iu9-fO-pPv" firstAttribute="leading" secondItem="8bC-Xf-vdC" secondAttribute="leadingMargin" constant="10" id="bJf-cY-y2d"/>
<constraint firstItem="cmN-DO-oLC" firstAttribute="top" secondItem="C20-qv-lcV" secondAttribute="bottom" id="mMX-mv-Dre"/>
<constraint firstItem="7F2-zY-5ah" firstAttribute="leading" secondItem="C20-qv-lcV" secondAttribute="trailing" constant="26" id="ndw-Lp-TMx"/>
<constraint firstAttribute="trailingMargin" secondItem="iu9-fO-pPv" secondAttribute="trailing" constant="10" id="oNb-um-6Qz"/>
<constraint firstAttribute="trailingMargin" secondItem="cmN-DO-oLC" secondAttribute="trailing" id="vsb-Wl-Nhq"/>
<constraint firstItem="wYi-Zk-AVg" firstAttribute="top" secondItem="iu9-fO-pPv" secondAttribute="bottom" constant="8" id="wjk-LT-TP4"/>
Expand All @@ -165,6 +192,7 @@
</navigationItem>
<connections>
<outlet property="aPlayer" destination="cmN-DO-oLC" id="9nH-oR-Hmu"/>
<outlet property="aSlider" destination="iu9-fO-pPv" id="rXQ-hz-Aih"/>
</connections>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
Expand All @@ -176,7 +204,7 @@
<objects>
<navigationController id="4uQ-1Q-oSI" sceneMemberID="viewController">
<navigationBar key="navigationBar" contentMode="scaleToFill" id="h5y-PJ-oVu">
<rect key="frame" x="0.0" y="20" width="375" height="44"/>
<rect key="frame" x="0.0" y="0.0" width="375" height="44"/>
<autoresizingMask key="autoresizingMask"/>
</navigationBar>
<connections>
Expand Down
Loading

0 comments on commit 873f8e4

Please sign in to comment.