├── iTunesLyrics
├── Vendors
│ ├── Sparkle.framework
│ │ ├── Versions
│ │ │ ├── Current
│ │ │ └── A
│ │ │ │ ├── Resources
│ │ │ │ ├── fr_CA.lproj
│ │ │ │ ├── pt.lproj
│ │ │ │ ├── Autoupdate.app
│ │ │ │ │ └── Contents
│ │ │ │ │ │ ├── PkgInfo
│ │ │ │ │ │ ├── MacOS
│ │ │ │ │ │ └── Autoupdate
│ │ │ │ │ │ ├── Resources
│ │ │ │ │ │ ├── AppIcon.icns
│ │ │ │ │ │ ├── SUStatus.nib
│ │ │ │ │ │ ├── ar.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── ca.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── cs.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── da.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── de.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── el.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── en.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── es.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── fi.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── fr.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── he.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── is.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── it.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── ja.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── ko.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── nb.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── nl.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── pl.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── ro.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── ru.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── sk.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── sl.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── sv.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── th.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── tr.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── uk.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── pt_BR.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── pt_PT.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ ├── zh_CN.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ └── zh_TW.lproj
│ │ │ │ │ │ │ └── Sparkle.strings
│ │ │ │ │ │ └── Info.plist
│ │ │ │ ├── SUStatus.nib
│ │ │ │ ├── ar.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── ca.lproj
│ │ │ │ │ └── Sparkle.strings
│ │ │ │ ├── cs.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── da.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── de.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── el.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── en.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── es.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── fi.lproj
│ │ │ │ │ └── Sparkle.strings
│ │ │ │ ├── fr.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── he.lproj
│ │ │ │ │ └── Sparkle.strings
│ │ │ │ ├── is.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── it.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── ja.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── ko.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── nb.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── nl.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── pl.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── ro.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── ru.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── sk.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── sl.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── sv.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── th.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── tr.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── uk.lproj
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── pt_BR.lproj
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── pt_PT.lproj
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── zh_CN.lproj
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ ├── zh_TW.lproj
│ │ │ │ │ ├── Sparkle.strings
│ │ │ │ │ ├── SUUpdateAlert.nib
│ │ │ │ │ ├── SUAutomaticUpdateAlert.nib
│ │ │ │ │ └── SUUpdatePermissionPrompt.nib
│ │ │ │ └── Info.plist
│ │ │ │ ├── Sparkle
│ │ │ │ ├── Modules
│ │ │ │ └── module.modulemap
│ │ │ │ ├── Headers
│ │ │ │ ├── SUExport.h
│ │ │ │ ├── SUAppcast.h
│ │ │ │ ├── SUVersionDisplayProtocol.h
│ │ │ │ ├── Sparkle.h
│ │ │ │ ├── SUVersionComparisonProtocol.h
│ │ │ │ ├── SUStandardVersionComparator.h
│ │ │ │ ├── SUErrors.h
│ │ │ │ └── SUAppcastItem.h
│ │ │ │ └── PrivateHeaders
│ │ │ │ └── SUUnarchiver.h
│ │ ├── Headers
│ │ ├── Modules
│ │ ├── Sparkle
│ │ ├── Resources
│ │ └── PrivateHeaders
│ └── ASIHTTPRequest
│ │ ├── ASIInputStream.h
│ │ ├── ASIAuthenticationDialog.h
│ │ ├── ASIHTTPRequestConfig.h
│ │ ├── ASIHTTPRequestDelegate.h
│ │ ├── ASIProgressDelegate.h
│ │ ├── ASIDataDecompressor.h
│ │ ├── ASIDataCompressor.h
│ │ ├── ASIDownloadCache.h
│ │ ├── ASIFormDataRequest.h
│ │ ├── ASIInputStream.m
│ │ ├── ASINetworkQueue.h
│ │ ├── ASICacheDelegate.h
│ │ ├── ASIDataDecompressor.m
│ │ ├── ASIDataCompressor.m
│ │ ├── Reachability.h
│ │ └── JSONKit.h
├── Resource
│ ├── logo.icns
│ ├── star.png
│ ├── transparent.png
│ └── transparent@2x.png
├── main.m
├── Credits.rtf
├── Utils
│ ├── Utils.h
│ ├── Marco.h
│ └── Utils.m
├── UI
│ ├── LyricWindow
│ │ ├── LyricDisplayWindow.h
│ │ └── LyricDisplayWindow.m
│ ├── Preference
│ │ ├── AppDelegate+Preference.h
│ │ └── AppDelegate+Preference.m
│ ├── StatusBar
│ │ ├── StatusBarView.h
│ │ └── StatusBarView.m
│ └── Search
│ │ ├── SearchLyricWindowController.h
│ │ └── SearchLyricWindowController.m
├── Model
│ ├── Song.h
│ └── Song.m
├── AppDelegate.h
├── Helper
│ ├── iTunesLyricHelper.h
│ └── iTunesLyricHelper.m
├── Images.xcassets
│ └── AppIcon.appiconset
│ │ └── Contents.json
├── Info.plist
├── pubilc_release_note.xml
├── dsa_pub.pem
└── AppDelegate.m
├── Snapshoot
├── 1.png
├── 2.png
├── 3.png
└── 4.png
├── Release
└── iTunesLyrics1_0.zip
├── iTunesLyrics.xcodeproj
├── project.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcuserdata
│ │ └── Penny.xcuserdatad
│ │ └── UserInterfaceState.xcuserstate
└── xcuserdata
│ └── Penny.xcuserdatad
│ ├── xcschemes
│ ├── xcschememanagement.plist
│ └── iTunesLyrics.xcscheme
│ └── xcdebugger
│ └── Breakpoints_v2.xcbkptlist
├── README.md
└── iTunesLyricsTests
├── Info.plist
└── iTunesLyricsTests.m
/iTunesLyrics/Vendors/Sparkle.framework/Versions/Current:
--------------------------------------------------------------------------------
1 | A
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Headers:
--------------------------------------------------------------------------------
1 | Versions/Current/Headers
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Modules:
--------------------------------------------------------------------------------
1 | Versions/Current/Modules
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Sparkle:
--------------------------------------------------------------------------------
1 | Versions/Current/Sparkle
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Resources:
--------------------------------------------------------------------------------
1 | Versions/Current/Resources
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr_CA.lproj:
--------------------------------------------------------------------------------
1 | fr.lproj
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt.lproj:
--------------------------------------------------------------------------------
1 | pt_BR.lproj
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/PrivateHeaders:
--------------------------------------------------------------------------------
1 | Versions/Current/PrivateHeaders
--------------------------------------------------------------------------------
/Snapshoot/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/Snapshoot/1.png
--------------------------------------------------------------------------------
/Snapshoot/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/Snapshoot/2.png
--------------------------------------------------------------------------------
/Snapshoot/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/Snapshoot/3.png
--------------------------------------------------------------------------------
/Snapshoot/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/Snapshoot/4.png
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/PkgInfo:
--------------------------------------------------------------------------------
1 | APPL????
--------------------------------------------------------------------------------
/Release/iTunesLyrics1_0.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/Release/iTunesLyrics1_0.zip
--------------------------------------------------------------------------------
/iTunesLyrics/Resource/logo.icns:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Resource/logo.icns
--------------------------------------------------------------------------------
/iTunesLyrics/Resource/star.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Resource/star.png
--------------------------------------------------------------------------------
/iTunesLyrics/Resource/transparent.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Resource/transparent.png
--------------------------------------------------------------------------------
/iTunesLyrics/Resource/transparent@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Resource/transparent@2x.png
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Sparkle:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Sparkle
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Modules/module.modulemap:
--------------------------------------------------------------------------------
1 | framework module Sparkle {
2 | umbrella header "Sparkle.h"
3 |
4 | export *
5 | module * { export * }
6 | }
7 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/SUStatus.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/SUStatus.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ar.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ar.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ar.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ar.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ca.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ca.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/cs.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/cs.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/cs.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/cs.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/da.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/da.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/da.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/da.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/de.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/de.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/de.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/de.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/el.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/el.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/el.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/el.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/en.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/en.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/en.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/en.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/es.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/es.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/es.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/es.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fi.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fi.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/he.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/he.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/is.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/is.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/is.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/is.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/it.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/it.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/it.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/it.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ja.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ja.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ja.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ja.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ko.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ko.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ko.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ko.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nb.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nb.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nb.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nb.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nl.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nl.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nl.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nl.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pl.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pl.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pl.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pl.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ro.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ro.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ro.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ro.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ru.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ru.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ru.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ru.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sk.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sk.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sk.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sk.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sl.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sl.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sl.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sl.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sv.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sv.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sv.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sv.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/th.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/th.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/th.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/th.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/tr.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/tr.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/tr.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/tr.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/uk.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/uk.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/uk.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/uk.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_BR.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_BR.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_PT.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_PT.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_CN.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_CN.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_TW.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_TW.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_BR.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_BR.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_PT.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_PT.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_CN.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_CN.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_TW.lproj/SUUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_TW.lproj/SUUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ar.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ar.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/cs.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/cs.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/da.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/da.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/de.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/de.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/el.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/el.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/en.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/en.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/es.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/es.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/is.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/is.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/it.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/it.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ja.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ja.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ko.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ko.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nb.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nb.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nl.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nl.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pl.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pl.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ro.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ro.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ru.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ru.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sk.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sk.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sl.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sl.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sv.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sv.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/th.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/th.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/tr.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/tr.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/uk.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/uk.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ar.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ar.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/cs.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/cs.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/da.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/da.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/de.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/de.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/el.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/el.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/en.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/en.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/es.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/es.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/fr.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/is.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/is.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/it.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/it.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ja.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ja.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ko.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ko.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nb.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nb.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nl.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/nl.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pl.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pl.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_BR.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_BR.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_PT.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_PT.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ro.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ro.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ru.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/ru.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sk.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sk.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sl.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sl.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sv.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/sv.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/th.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/th.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/tr.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/tr.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/uk.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/uk.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_CN.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_CN.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_TW.lproj/SUAutomaticUpdateAlert.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_TW.lproj/SUAutomaticUpdateAlert.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/MacOS/Autoupdate:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/MacOS/Autoupdate
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_BR.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_BR.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_PT.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/pt_PT.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_CN.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_CN.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_TW.lproj/SUUpdatePermissionPrompt.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/zh_TW.lproj/SUUpdatePermissionPrompt.nib
--------------------------------------------------------------------------------
/iTunesLyrics.xcodeproj/project.xcworkspace/xcuserdata/Penny.xcuserdatad/UserInterfaceState.xcuserstate:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics.xcodeproj/project.xcworkspace/xcuserdata/Penny.xcuserdatad/UserInterfaceState.xcuserstate
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/AppIcon.icns:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/AppIcon.icns
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/SUStatus.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/SUStatus.nib
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ar.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ar.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ca.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ca.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/cs.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/cs.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/da.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/da.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/de.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/de.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/el.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/el.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/en.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/en.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/es.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/es.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/fi.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/fi.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/fr.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/fr.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/he.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/he.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/is.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/is.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/it.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/it.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ja.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ja.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ko.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ko.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/nb.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/nb.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/nl.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/nl.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/pl.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/pl.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ro.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ro.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ru.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/ru.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/sk.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/sk.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/sl.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/sl.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/sv.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/sv.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/th.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/th.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/tr.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/tr.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/uk.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/uk.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/pt_BR.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/pt_BR.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/pt_PT.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/pt_PT.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/zh_CN.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/zh_CN.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/zh_TW.lproj/Sparkle.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/iampennyli/iTunesLyricApp/HEAD/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Resources/zh_TW.lproj/Sparkle.strings
--------------------------------------------------------------------------------
/iTunesLyrics/main.m:
--------------------------------------------------------------------------------
1 | //
2 | // main.m
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/16/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | int main(int argc, const char * argv[]) {
12 | return NSApplicationMain(argc, argv);
13 | }
14 |
--------------------------------------------------------------------------------
/iTunesLyrics/Credits.rtf:
--------------------------------------------------------------------------------
1 | {\rtf1\ansi\ansicpg936\cocoartf1348\cocoasubrtf170
2 | {\fonttbl\f0\fnil\fcharset134 STHeitiSC-Light;}
3 | {\colortbl;\red255\green255\blue255;}
4 | \viewkind0
5 | \deftab720
6 | \pard\pardeftab720\ri0\qc
7 |
8 | \f0\b\fs24 \cf0
9 | \b0 \
10 | \pard\pardeftab720\ri0
11 | \cf0 Developed by pennyli\
12 | \
13 | \
14 | \
15 | }
--------------------------------------------------------------------------------
/iTunesLyrics/Utils/Utils.h:
--------------------------------------------------------------------------------
1 | //
2 | // Utils.h
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/18/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import
10 | #import
11 | #import "Marco.h"
12 |
13 | @interface NSImage (CGImageRef)
14 | - (CGImageRef)CGImage;
15 | @end
16 |
17 |
18 | CGPathRef createRoundRectPathInRect(CGRect rect, CGFloat radius);
--------------------------------------------------------------------------------
/iTunesLyrics/UI/LyricWindow/LyricDisplayWindow.h:
--------------------------------------------------------------------------------
1 | //
2 | // LyricDisplayWindow.h
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/18/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import
10 | @class InnerView;
11 |
12 | @interface LyricDisplayWindow : NSPanel {
13 | InnerView *_innerView;
14 | }
15 |
16 | @property (nonatomic, strong) NSString *lyric;
17 | @end
18 |
19 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Headers/SUExport.h:
--------------------------------------------------------------------------------
1 | //
2 | // SUExport.h
3 | // Sparkle
4 | //
5 | // Created by Jake Petroules on 2014-08-23.
6 | // Copyright (c) 2014 Sparkle Project. All rights reserved.
7 | //
8 |
9 | #ifndef SUEXPORT_H
10 | #define SUEXPORT_H
11 |
12 | #ifdef BUILDING_SPARKLE
13 | #define SU_EXPORT __attribute__((visibility("default")))
14 | #else
15 | #define SU_EXPORT
16 | #endif
17 |
18 | #endif
19 |
--------------------------------------------------------------------------------
/iTunesLyrics/UI/Preference/AppDelegate+Preference.h:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate+Preference.h
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/18/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "AppDelegate.h"
11 |
12 | @interface AppDelegate(Preference)
13 | - (IBAction)colorChanged:(id)sender;
14 | - (IBAction)fontChanged:(id)sender;
15 | - (IBAction)startupChanged:(id)sender;
16 | - (void)preference:(NSNotification *)n;
17 | - (void)hideLyricPanel:(NSNotification *)n;
18 | @end
19 |
--------------------------------------------------------------------------------
/iTunesLyrics/Model/Song.h:
--------------------------------------------------------------------------------
1 | //
2 | // Song.h
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/17/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface Song : NSObject
12 | @property (nonatomic, strong) NSString *album;
13 | @property (nonatomic, strong) NSString *artist;
14 | @property (nonatomic, strong) NSString *name;
15 | @property (nonatomic, assign) NSInteger duration;
16 | @property (nonatomic, assign) NSInteger lyricId;
17 | @property (nonatomic, strong) NSString *lyrics;
18 | @property (nonatomic, assign) NSInteger score;
19 | @end
20 |
--------------------------------------------------------------------------------
/iTunesLyrics/Model/Song.m:
--------------------------------------------------------------------------------
1 | //
2 | // Song.m
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/17/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import "Song.h"
10 |
11 | @implementation Song
12 | - (instancetype)init
13 | {
14 | if (self = [super init]) {
15 | _artist = @"default";
16 | _album = @"default";
17 | _lyricId = 0;
18 | _duration = 0;
19 | }
20 | return self;
21 | }
22 |
23 | - (BOOL)isEqual:(Song *)object
24 | {
25 | return self.duration == object.duration && [self.name isEqualToString: object.name] && [self.artist isEqualToString: object.artist];
26 | }
27 | @end
28 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # iTunesLyricApp
2 | iTunes歌词插件App 1.0
3 |
4 |
5 |
6 | ###功能
7 |
8 | * 智能根据歌曲显示歌词
9 | * 支持手动搜索以及导入歌词
10 |
11 | ###bug
12 |
13 | * 智能匹配可能匹配错误
14 | * 播放iTunes在线音乐的时候,如果没有缓存可能检测不到播放歌曲,需要手动搜索以及导入
15 | * 设置里面跟随iTunes启动暂时没做
16 |
17 | ###意见反馈
18 |
19 | [我的博客](http://penny.li/2015/12/07/iTunesLyricApp/)
20 |
21 | ###截图
22 | 
23 |
24 | 
25 |
26 | 
27 |
28 | 
29 |
30 |
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Headers/SUAppcast.h:
--------------------------------------------------------------------------------
1 | //
2 | // SUAppcast.h
3 | // Sparkle
4 | //
5 | // Created by Andy Matuschak on 3/12/06.
6 | // Copyright 2006 Andy Matuschak. All rights reserved.
7 | //
8 |
9 | #ifndef SUAPPCAST_H
10 | #define SUAPPCAST_H
11 |
12 | #import
13 | #import "SUExport.h"
14 |
15 | @class SUAppcastItem;
16 | SU_EXPORT @interface SUAppcast : NSObject
17 |
18 | @property (copy) NSString *userAgentString;
19 | @property (copy) NSDictionary *httpHeaders;
20 |
21 | - (void)fetchAppcastFromURL:(NSURL *)url completionBlock:(void (^)(NSError *))err;
22 |
23 | @property (readonly, copy) NSArray *items;
24 | @end
25 |
26 | #endif
27 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Headers/SUVersionDisplayProtocol.h:
--------------------------------------------------------------------------------
1 | //
2 | // SUVersionDisplayProtocol.h
3 | // EyeTV
4 | //
5 | // Created by Uli Kusterer on 08.12.09.
6 | // Copyright 2009 Elgato Systems GmbH. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "SUExport.h"
11 |
12 | /*!
13 | Applies special display formatting to version numbers.
14 | */
15 | @protocol SUVersionDisplay
16 |
17 | /*!
18 | Formats two version strings.
19 |
20 | Both versions are provided so that important distinguishing information
21 | can be displayed while also leaving out unnecessary/confusing parts.
22 | */
23 | - (void)formatVersion:(NSString **)inOutVersionA andVersion:(NSString **)inOutVersionB;
24 |
25 | @end
26 |
--------------------------------------------------------------------------------
/iTunesLyrics/UI/StatusBar/StatusBarView.h:
--------------------------------------------------------------------------------
1 | //
2 | // StatusBarView.h
3 | // iTips
4 | //
5 | // Created by Penny on 12-9-22.
6 | // Copyright (c) 2012年 Penny. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "Utils.h"
11 |
12 | typedef NS_ENUM(NSUInteger, StatusBarTag) {
13 | kStatusShowLyricTag = 0,
14 | kStatusSearchLyricTag,
15 | kStatusPreferenceTag,
16 | kStatusFeedbackTag,
17 | kStatusAboutTag,
18 | kStatusQuitTag,
19 | kStatusCheckUpdateTag
20 | };
21 |
22 | @interface StatusBarView : NSView {
23 | NSStatusItem *statusItem;
24 | NSMenu *statusMenu;
25 | CGImageRef normalIcon;
26 | BOOL isHiLight;
27 | }
28 |
29 | @end
30 |
31 |
--------------------------------------------------------------------------------
/iTunesLyrics.xcodeproj/xcuserdata/Penny.xcuserdatad/xcschemes/xcschememanagement.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | SchemeUserState
6 |
7 | iTunesLyrics.xcscheme
8 |
9 | orderHint
10 | 0
11 |
12 |
13 | SuppressBuildableAutocreation
14 |
15 | BC3CD8C81BD1206400FA3E86
16 |
17 | primary
18 |
19 |
20 | BC3CD8DB1BD1206500FA3E86
21 |
22 | primary
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/iTunesLyrics/AppDelegate.h:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.h
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/16/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "LyricDisplayWindow.h"
11 | #import "SearchLyricWindowController.h"
12 | #import "Song.h"
13 | #import
14 |
15 | @interface AppDelegate : NSObject
16 | @property (weak) IBOutlet SUUpdater *updater;
17 |
18 | @property (nonatomic, strong) Song *song;
19 |
20 | @property (nonatomic, strong) LyricDisplayWindow *lyricWindow;
21 | @property (nonatomic, strong) SearchLyricWindowController *searchViewController;
22 | @property (nonatomic, weak) IBOutlet NSWindow *prefWindow;
23 | @end
24 |
25 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Headers/Sparkle.h:
--------------------------------------------------------------------------------
1 | //
2 | // Sparkle.h
3 | // Sparkle
4 | //
5 | // Created by Andy Matuschak on 3/16/06. (Modified by CDHW on 23/12/07)
6 | // Copyright 2006 Andy Matuschak. All rights reserved.
7 | //
8 |
9 | #ifndef SPARKLE_H
10 | #define SPARKLE_H
11 |
12 | #import
13 |
14 | // This list should include the shared headers. It doesn't matter if some of them aren't shared (unless
15 | // there are name-space collisions) so we can list all of them to start with:
16 |
17 | #import "SUAppcast.h"
18 | #import "SUAppcastItem.h"
19 | #import "SUStandardVersionComparator.h"
20 | #import "SUUpdater.h"
21 | #import "SUVersionComparisonProtocol.h"
22 | #import "SUVersionDisplayProtocol.h"
23 | #import "SUErrors.h"
24 |
25 | #endif
26 |
--------------------------------------------------------------------------------
/iTunesLyricsTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | com.penny.li.$(PRODUCT_NAME:rfc1034identifier)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 |
24 |
25 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Headers/SUVersionComparisonProtocol.h:
--------------------------------------------------------------------------------
1 | //
2 | // SUVersionComparisonProtocol.h
3 | // Sparkle
4 | //
5 | // Created by Andy Matuschak on 12/21/07.
6 | // Copyright 2007 Andy Matuschak. All rights reserved.
7 | //
8 |
9 | #ifndef SUVERSIONCOMPARISONPROTOCOL_H
10 | #define SUVERSIONCOMPARISONPROTOCOL_H
11 |
12 | #import
13 | #import "SUExport.h"
14 |
15 | /*!
16 | Provides version comparison facilities for Sparkle.
17 | */
18 | @protocol SUVersionComparison
19 |
20 | /*!
21 | An abstract method to compare two version strings.
22 |
23 | Should return NSOrderedAscending if b > a, NSOrderedDescending if b < a,
24 | and NSOrderedSame if they are equivalent.
25 | */
26 | - (NSComparisonResult)compareVersion:(NSString *)versionA toVersion:(NSString *)versionB; // *** MAY BE CALLED ON NON-MAIN THREAD!
27 |
28 | @end
29 |
30 | #endif
31 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/PrivateHeaders/SUUnarchiver.h:
--------------------------------------------------------------------------------
1 | //
2 | // SUUnarchiver.h
3 | // Sparkle
4 | //
5 | // Created by Andy Matuschak on 3/16/06.
6 | // Copyright 2006 Andy Matuschak. All rights reserved.
7 | //
8 |
9 | #ifndef SUUNARCHIVER_H
10 | #define SUUNARCHIVER_H
11 |
12 | #import
13 |
14 | @class SUHost;
15 | @protocol SUUnarchiverDelegate;
16 |
17 | @interface SUUnarchiver : NSObject
18 |
19 | @property (copy, readonly) NSString *archivePath;
20 | @property (copy, readonly) NSString *updateHostBundlePath;
21 | @property (weak) id delegate;
22 |
23 | + (SUUnarchiver *)unarchiverForPath:(NSString *)path updatingHostBundlePath:(NSString *)host;
24 |
25 | - (void)start;
26 | @end
27 |
28 | @protocol SUUnarchiverDelegate
29 | - (void)unarchiverDidFinish:(SUUnarchiver *)unarchiver;
30 | - (void)unarchiverDidFail:(SUUnarchiver *)unarchiver;
31 | @optional
32 | - (void)unarchiver:(SUUnarchiver *)unarchiver extractedProgress:(double)progress;
33 | @end
34 |
35 | #endif
36 |
--------------------------------------------------------------------------------
/iTunesLyricsTests/iTunesLyricsTests.m:
--------------------------------------------------------------------------------
1 | //
2 | // iTunesLyricsTests.m
3 | // iTunesLyricsTests
4 | //
5 | // Created by pennyli on 10/16/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import
10 | #import
11 |
12 | @interface iTunesLyricsTests : XCTestCase
13 |
14 | @end
15 |
16 | @implementation iTunesLyricsTests
17 |
18 | - (void)setUp {
19 | [super setUp];
20 | // Put setup code here. This method is called before the invocation of each test method in the class.
21 | }
22 |
23 | - (void)tearDown {
24 | // Put teardown code here. This method is called after the invocation of each test method in the class.
25 | [super tearDown];
26 | }
27 |
28 | - (void)testExample {
29 | // This is an example of a functional test case.
30 | XCTAssert(YES, @"Pass");
31 | }
32 |
33 | - (void)testPerformanceExample {
34 | // This is an example of a performance test case.
35 | [self measureBlock:^{
36 | // Put the code you want to measure the time of here.
37 | }];
38 | }
39 |
40 | @end
41 |
--------------------------------------------------------------------------------
/iTunesLyrics/Utils/Marco.h:
--------------------------------------------------------------------------------
1 | //
2 | // Marco.h
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/17/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #ifndef iTunesLyrics_Marco_h
10 | #define iTunesLyrics_Marco_h
11 |
12 | #define FETCH_SONG_ID_URL @"http://music.163.com/api/search/pc"
13 | #define FETCH_SONG_LYRIC_URL @"http://music.163.com/api/song/lyric?os=osx&lv=-1&kv=-1&tv=-1"
14 |
15 | #define kNotification_ShowWindow @"kNotification_ShowWindow"
16 | #define kNotification_HideLyric @"kNotification_HideLyric"
17 | #define kNotificaiton_ColorChanged @"kNotificaiton_ColorChanged"
18 | #define kNotification_FontChanged @"kNotification_FontChanged"
19 |
20 | #define ENET_COOKIE @"deviceId=5F7F81C3-B8D3-5BA3-AAB2-D25599CBB3BE%7C793F6423-0C45-4DB4-B719-82010F55973E; os=osx; usertrack=c+5+hVVQh8ajuyyLCsdtAg==; __remember_me=true;"
21 |
22 | #define ENET_UA @"Mozilla/5.0 (Macintosh; Intel Mac OS X 10_10_5) AppleWebKit/600.8.9 (KHTML, like Gecko)"
23 | #endif
24 |
--------------------------------------------------------------------------------
/iTunesLyrics/Helper/iTunesLyricHelper.h:
--------------------------------------------------------------------------------
1 | //
2 | // iTunesLyricHelper.h
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/17/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "ASIHTTPRequest.h"
11 | #import "Song.h"
12 |
13 | typedef void (^FetchLyricListCompleteBlock)(NSArray *value);
14 | typedef void (^FetchLyricCompleteBlock)(Song *song);
15 |
16 | @interface iTunesLyricHelper : NSObject
17 |
18 | @property (nonatomic, strong) NSMutableDictionary *requestsDict;
19 |
20 | + (instancetype)shareHelper;
21 |
22 | /**
23 | 根据iTunes歌曲信息智能获取歌词
24 | */
25 | - (void)smartFetchLyricWithSong:(Song *)song completeBlock:(FetchLyricCompleteBlock)block;
26 |
27 | /**
28 | 根据歌曲名查询歌曲歌词列表
29 | */
30 | - (void)fetchLyricListWithName:(NSString *)songName completeBlock:(FetchLyricListCompleteBlock)block;
31 |
32 | /**
33 | 根据歌曲(含有歌词id)获取歌词
34 | */
35 | - (void)fetchLyricWithSong:(Song *)song completeBlock:(FetchLyricCompleteBlock)block;;
36 |
37 | /**
38 | 保存歌词到本地
39 | */
40 | - (void)saveSongLyricToLocal:(Song *)song;
41 | @end
42 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIInputStream.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIInputStream.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 10/08/2009.
6 | // Copyright 2009 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @class ASIHTTPRequest;
12 |
13 | // This is a wrapper for NSInputStream that pretends to be an NSInputStream itself
14 | // Subclassing NSInputStream seems to be tricky, and may involve overriding undocumented methods, so we'll cheat instead.
15 | // It is used by ASIHTTPRequest whenever we have a request body, and handles measuring and throttling the bandwidth used for uploading
16 |
17 | @interface ASIInputStream : NSObject {
18 | NSInputStream *stream;
19 | ASIHTTPRequest *request;
20 | }
21 | + (id)inputStreamWithFileAtPath:(NSString *)path request:(ASIHTTPRequest *)request;
22 | + (id)inputStreamWithData:(NSData *)data request:(ASIHTTPRequest *)request;
23 |
24 | @property (retain, nonatomic) NSInputStream *stream;
25 | @property (assign, nonatomic) ASIHTTPRequest *request;
26 | @end
27 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Headers/SUStandardVersionComparator.h:
--------------------------------------------------------------------------------
1 | //
2 | // SUStandardVersionComparator.h
3 | // Sparkle
4 | //
5 | // Created by Andy Matuschak on 12/21/07.
6 | // Copyright 2007 Andy Matuschak. All rights reserved.
7 | //
8 |
9 | #ifndef SUSTANDARDVERSIONCOMPARATOR_H
10 | #define SUSTANDARDVERSIONCOMPARATOR_H
11 |
12 | #import
13 | #import "SUExport.h"
14 | #import "SUVersionComparisonProtocol.h"
15 |
16 | /*!
17 | Sparkle's default version comparator.
18 |
19 | This comparator is adapted from MacPAD, by Kevin Ballard.
20 | It's "dumb" in that it does essentially string comparison,
21 | in components split by character type.
22 | */
23 | SU_EXPORT @interface SUStandardVersionComparator : NSObject
24 |
25 | /*!
26 | Returns a singleton instance of the comparator.
27 | */
28 | + (SUStandardVersionComparator *)defaultComparator;
29 |
30 | /*!
31 | Compares version strings through textual analysis.
32 |
33 | See the implementation for more details.
34 | */
35 | - (NSComparisonResult)compareVersion:(NSString *)versionA toVersion:(NSString *)versionB;
36 | @end
37 |
38 | #endif
39 |
--------------------------------------------------------------------------------
/iTunesLyrics/Images.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "mac",
5 | "size" : "16x16",
6 | "scale" : "1x"
7 | },
8 | {
9 | "idiom" : "mac",
10 | "size" : "16x16",
11 | "scale" : "2x"
12 | },
13 | {
14 | "idiom" : "mac",
15 | "size" : "32x32",
16 | "scale" : "1x"
17 | },
18 | {
19 | "idiom" : "mac",
20 | "size" : "32x32",
21 | "scale" : "2x"
22 | },
23 | {
24 | "idiom" : "mac",
25 | "size" : "128x128",
26 | "scale" : "1x"
27 | },
28 | {
29 | "idiom" : "mac",
30 | "size" : "128x128",
31 | "scale" : "2x"
32 | },
33 | {
34 | "idiom" : "mac",
35 | "size" : "256x256",
36 | "scale" : "1x"
37 | },
38 | {
39 | "idiom" : "mac",
40 | "size" : "256x256",
41 | "scale" : "2x"
42 | },
43 | {
44 | "idiom" : "mac",
45 | "size" : "512x512",
46 | "scale" : "1x"
47 | },
48 | {
49 | "idiom" : "mac",
50 | "size" : "512x512",
51 | "scale" : "2x"
52 | }
53 | ],
54 | "info" : {
55 | "version" : 1,
56 | "author" : "xcode"
57 | }
58 | }
--------------------------------------------------------------------------------
/iTunesLyrics/UI/Search/SearchLyricWindowController.h:
--------------------------------------------------------------------------------
1 | //
2 | // SearchLyricWindowController.h
3 | // iTunesLyrics
4 | //
5 | // Created by 鹏 李 on 15/12/5.
6 | // Copyright © 2015年 Cocoamad. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "Song.h"
11 |
12 | @protocol SearchLyricDelegate
13 |
14 | - (void)searchLyricWillBegin;
15 | - (void)searchLyricDidImportLyricToSong:(Song *)song;
16 |
17 | @end
18 |
19 | @interface SearchLyricWindowController : NSWindowController {
20 | NSArray *_songs;
21 | }
22 |
23 | @property (nonatomic, weak) id searchLyricDelegate;
24 |
25 | @property (weak) IBOutlet NSTableView *tableView;
26 | @property (weak) IBOutlet NSSearchField *searchField;
27 |
28 | @property (weak) IBOutlet NSTextField *songNameLabel;
29 | @property (weak) IBOutlet NSTextField *singerNameLabel;
30 | @property (weak) IBOutlet NSTextField *albumLabel;
31 | @property (weak) IBOutlet NSTextField *durationLabel;
32 |
33 | @property (strong) NSProgressIndicator *indicator;
34 |
35 | @property (nonatomic, strong) Song *song;
36 |
37 | - (instancetype)initWithWindowNibName:(NSString *)windowNibName Song:(Song *)song;
38 |
39 | @end
40 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Headers/SUErrors.h:
--------------------------------------------------------------------------------
1 | //
2 | // SUErrors.h
3 | // Sparkle
4 | //
5 | // Created by C.W. Betts on 10/13/14.
6 | // Copyright (c) 2014 Sparkle Project. All rights reserved.
7 | //
8 |
9 | #ifndef SUERRORS_H
10 | #define SUERRORS_H
11 |
12 | #import
13 | #import "SUExport.h"
14 |
15 | /**
16 | * Error domain used by Sparkle
17 | */
18 | SU_EXPORT extern NSString *const SUSparkleErrorDomain;
19 |
20 | typedef NS_ENUM(OSStatus, SUError) {
21 | // Appcast phase errors.
22 | SUAppcastParseError = 1000,
23 | SUNoUpdateError = 1001,
24 | SUAppcastError = 1002,
25 | SURunningFromDiskImageError = 1003,
26 |
27 | // Downlaod phase errors.
28 | SUTemporaryDirectoryError = 2000,
29 |
30 | // Extraction phase errors.
31 | SUUnarchivingError = 3000,
32 | SUSignatureError = 3001,
33 |
34 | // Installation phase errors.
35 | SUFileCopyFailure = 4000,
36 | SUAuthenticationFailure = 4001,
37 | SUMissingUpdateError = 4002,
38 | SUMissingInstallerToolError = 4003,
39 | SURelaunchError = 4004,
40 | SUInstallationError = 4005,
41 | SUDowngradeError = 4006,
42 |
43 | // System phase errors
44 | SUSystemPowerOffError = 5000
45 | };
46 |
47 | #endif
48 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIAuthenticationDialog.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIAuthenticationDialog.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 21/08/2009.
6 | // Copyright 2009 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import
10 | #import
11 | @class ASIHTTPRequest;
12 |
13 | typedef enum _ASIAuthenticationType {
14 | ASIStandardAuthenticationType = 0,
15 | ASIProxyAuthenticationType = 1
16 | } ASIAuthenticationType;
17 |
18 | @interface ASIAutorotatingViewController : UIViewController
19 | @end
20 |
21 | @interface ASIAuthenticationDialog : ASIAutorotatingViewController {
22 | ASIHTTPRequest *request;
23 | ASIAuthenticationType type;
24 | UITableView *tableView;
25 | UIViewController *presentingController;
26 | BOOL didEnableRotationNotifications;
27 | }
28 | + (void)presentAuthenticationDialogForRequest:(ASIHTTPRequest *)request;
29 | + (void)dismiss;
30 |
31 | @property (atomic, retain) ASIHTTPRequest *request;
32 | @property (atomic, assign) ASIAuthenticationType type;
33 | @property (atomic, assign) BOOL didEnableRotationNotifications;
34 | @property (retain, nonatomic) UIViewController *presentingController;
35 | @end
36 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | BuildMachineOSBuild
6 | 14F1021
7 | CFBundleDevelopmentRegion
8 | en
9 | CFBundleExecutable
10 | Sparkle
11 | CFBundleIdentifier
12 | org.andymatuschak.Sparkle
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | Sparkle
17 | CFBundlePackageType
18 | FMWK
19 | CFBundleShortVersionString
20 | 1.12.0 git-5e90d98
21 | CFBundleSignature
22 | ????
23 | CFBundleSupportedPlatforms
24 |
25 | MacOSX
26 |
27 | CFBundleVersion
28 | 1.12.0
29 | DTCompiler
30 | com.apple.compilers.llvm.clang.1_0
31 | DTPlatformBuild
32 | 7B91b
33 | DTPlatformVersion
34 | GM
35 | DTSDKBuild
36 | 15A278
37 | DTSDKName
38 | macosx10.11
39 | DTXcode
40 | 0710
41 | DTXcodeBuild
42 | 7B91b
43 |
44 |
45 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIHTTPRequestConfig.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIHTTPRequestConfig.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 14/12/2009.
6 | // Copyright 2009 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 |
10 | // ======
11 | // Debug output configuration options
12 | // ======
13 |
14 | // If defined will use the specified function for debug logging
15 | // Otherwise use NSLog
16 | #ifndef ASI_DEBUG_LOG
17 | #define ASI_DEBUG_LOG NSLog
18 | #endif
19 |
20 | // When set to 1 ASIHTTPRequests will print information about what a request is doing
21 | #ifndef DEBUG_REQUEST_STATUS
22 | #define DEBUG_REQUEST_STATUS 0
23 | #endif
24 |
25 | // When set to 1, ASIFormDataRequests will print information about the request body to the console
26 | #ifndef DEBUG_FORM_DATA_REQUEST
27 | #define DEBUG_FORM_DATA_REQUEST 0
28 | #endif
29 |
30 | // When set to 1, ASIHTTPRequests will print information about bandwidth throttling to the console
31 | #ifndef DEBUG_THROTTLING
32 | #define DEBUG_THROTTLING 0
33 | #endif
34 |
35 | // When set to 1, ASIHTTPRequests will print information about persistent connections to the console
36 | #ifndef DEBUG_PERSISTENT_CONNECTIONS
37 | #define DEBUG_PERSISTENT_CONNECTIONS 0
38 | #endif
39 |
40 | // When set to 1, ASIHTTPRequests will print information about HTTP authentication (Basic, Digest or NTLM) to the console
41 | #ifndef DEBUG_HTTP_AUTHENTICATION
42 | #define DEBUG_HTTP_AUTHENTICATION 0
43 | #endif
44 |
--------------------------------------------------------------------------------
/iTunesLyrics/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIconFile
10 | logo.icns
11 | CFBundleIdentifier
12 | com.penny.li.$(PRODUCT_NAME:rfc1034identifier)
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | $(PRODUCT_NAME)
17 | CFBundlePackageType
18 | APPL
19 | CFBundleShortVersionString
20 | 1.0
21 | CFBundleSignature
22 | ????
23 | CFBundleVersion
24 | 1
25 | LSMinimumSystemVersion
26 | $(MACOSX_DEPLOYMENT_TARGET)
27 | LSUIElement
28 |
29 | NSAppTransportSecurity
30 |
31 | NSAllowsArbitraryLoads
32 |
33 |
34 | NSHumanReadableCopyright
35 | Copyright © 2015 penny.li. All rights reserved.
36 | NSMainNibFile
37 | MainMenu
38 | NSPrincipalClass
39 | NSApplication
40 | SUFeedURL
41 | https://www.baidu.com
42 | SUPublicDSAKeyFile
43 | dsa_pub.pem
44 |
45 |
46 |
--------------------------------------------------------------------------------
/iTunesLyrics/Utils/Utils.m:
--------------------------------------------------------------------------------
1 | //
2 | // Utils.m
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/18/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import "Utils.h"
10 |
11 | @implementation NSImage(CGImageRef)
12 |
13 | - (CGImageRef)converte2CGImageRef
14 | {
15 | CGImageSourceRef source = CGImageSourceCreateWithData((__bridge CFDataRef)[self TIFFRepresentation], NULL);
16 | if (source) {
17 | CGImageRef maskRef = CGImageSourceCreateImageAtIndex(source, 0, NULL);
18 | CFRelease(source);
19 | return maskRef; // should release outside
20 | }
21 | return nil;
22 | }
23 |
24 | - (CGImageRef)CGImage
25 | {
26 | return [self converte2CGImageRef];
27 | }
28 |
29 | @end
30 |
31 | CGPathRef createRoundRectPathInRect(CGRect rect, CGFloat radius)
32 | {
33 | CGFloat mr = MIN(CGRectGetHeight(rect), CGRectGetWidth(rect));
34 |
35 | CGFloat _radius = MIN(radius, 0.5f * mr);
36 |
37 | CGRect innerRect = CGRectInset(rect, _radius, _radius);
38 |
39 | CGMutablePathRef path = CGPathCreateMutable();
40 |
41 | CGPathMoveToPoint(path, NULL, CGRectGetMinX(innerRect) - _radius, CGRectGetMinY(innerRect));
42 |
43 | CGPathAddArc(path, NULL, CGRectGetMinX(innerRect), CGRectGetMinY(innerRect), _radius, M_PI, 3 * M_PI_2, false);
44 | CGPathAddArc(path, NULL, CGRectGetMaxX(innerRect), CGRectGetMinY(innerRect), _radius, 3 * M_PI_2, 0, false);
45 | CGPathAddArc(path, NULL, CGRectGetMaxX(innerRect), CGRectGetMaxY(innerRect), _radius, 0, M_PI_2, false);
46 | CGPathAddArc(path, NULL, CGRectGetMinX(innerRect), CGRectGetMaxY(innerRect), _radius, M_PI_2, M_PI, false);
47 | CGPathCloseSubpath(path);
48 |
49 | return path;
50 | }
51 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Headers/SUAppcastItem.h:
--------------------------------------------------------------------------------
1 | //
2 | // SUAppcastItem.h
3 | // Sparkle
4 | //
5 | // Created by Andy Matuschak on 3/12/06.
6 | // Copyright 2006 Andy Matuschak. All rights reserved.
7 | //
8 |
9 | #ifndef SUAPPCASTITEM_H
10 | #define SUAPPCASTITEM_H
11 |
12 | #import
13 | #import "SUExport.h"
14 |
15 | SU_EXPORT @interface SUAppcastItem : NSObject
16 | @property (copy, readonly) NSString *title;
17 | @property (copy, readonly) NSDate *date;
18 | @property (copy, readonly) NSString *itemDescription;
19 | @property (strong, readonly) NSURL *releaseNotesURL;
20 | @property (copy, readonly) NSString *DSASignature;
21 | @property (copy, readonly) NSString *minimumSystemVersion;
22 | @property (copy, readonly) NSString *maximumSystemVersion;
23 | @property (strong, readonly) NSURL *fileURL;
24 | @property (copy, readonly) NSString *versionString;
25 | @property (copy, readonly) NSString *displayVersionString;
26 | @property (copy, readonly) NSDictionary *deltaUpdates;
27 | @property (strong, readonly) NSURL *infoURL;
28 |
29 | // Initializes with data from a dictionary provided by the RSS class.
30 | - (instancetype)initWithDictionary:(NSDictionary *)dict;
31 | - (instancetype)initWithDictionary:(NSDictionary *)dict failureReason:(NSString **)error;
32 |
33 | @property (getter=isDeltaUpdate, readonly) BOOL deltaUpdate;
34 | @property (getter=isCriticalUpdate, readonly) BOOL criticalUpdate;
35 | @property (getter=isInformationOnlyUpdate, readonly) BOOL informationOnlyUpdate;
36 |
37 | // Returns the dictionary provided in initWithDictionary; this might be useful later for extensions.
38 | @property (readonly, copy) NSDictionary *propertiesDictionary;
39 |
40 | - (NSURL *)infoURL;
41 |
42 | @end
43 |
44 | #endif
45 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIHTTPRequestDelegate.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIHTTPRequestDelegate.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 13/04/2010.
6 | // Copyright 2010 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | @class ASIHTTPRequest;
10 |
11 | @protocol ASIHTTPRequestDelegate
12 |
13 | @optional
14 |
15 | // These are the default delegate methods for request status
16 | // You can use different ones by setting didStartSelector / didFinishSelector / didFailSelector
17 | - (void)requestStarted:(ASIHTTPRequest *)request;
18 | - (void)request:(ASIHTTPRequest *)request didReceiveResponseHeaders:(NSDictionary *)responseHeaders;
19 | - (void)request:(ASIHTTPRequest *)request willRedirectToURL:(NSURL *)newURL;
20 | - (void)requestFinished:(ASIHTTPRequest *)request;
21 | - (void)requestFailed:(ASIHTTPRequest *)request;
22 | - (void)requestRedirected:(ASIHTTPRequest *)request;
23 |
24 | // When a delegate implements this method, it is expected to process all incoming data itself
25 | // This means that responseData / responseString / downloadDestinationPath etc are ignored
26 | // You can have the request call a different method by setting didReceiveDataSelector
27 | - (void)request:(ASIHTTPRequest *)request didReceiveData:(NSData *)data;
28 |
29 | // If a delegate implements one of these, it will be asked to supply credentials when none are available
30 | // The delegate can then either restart the request ([request retryUsingSuppliedCredentials]) once credentials have been set
31 | // or cancel it ([request cancelAuthentication])
32 | - (void)authenticationNeededForRequest:(ASIHTTPRequest *)request;
33 | - (void)proxyAuthenticationNeededForRequest:(ASIHTTPRequest *)request;
34 |
35 | @end
36 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/Sparkle.framework/Versions/A/Resources/Autoupdate.app/Contents/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | BuildMachineOSBuild
6 | 14F1021
7 | CFBundleDevelopmentRegion
8 | English
9 | CFBundleExecutable
10 | Autoupdate
11 | CFBundleIconFile
12 | AppIcon
13 | CFBundleIdentifier
14 | org.sparkle-project.Sparkle.Autoupdate
15 | CFBundleInfoDictionaryVersion
16 | 6.0
17 | CFBundlePackageType
18 | APPL
19 | CFBundleShortVersionString
20 | 1.12.0 git-5e90d98
21 | CFBundleSignature
22 | ????
23 | CFBundleSupportedPlatforms
24 |
25 | MacOSX
26 |
27 | CFBundleVersion
28 | 1.12.0
29 | DTCompiler
30 | com.apple.compilers.llvm.clang.1_0
31 | DTPlatformBuild
32 | 7B91b
33 | DTPlatformVersion
34 | GM
35 | DTSDKBuild
36 | 15A278
37 | DTSDKName
38 | macosx10.11
39 | DTXcode
40 | 0710
41 | DTXcodeBuild
42 | 7B91b
43 | LSBackgroundOnly
44 | 1
45 | LSMinimumSystemVersion
46 | 10.7
47 | LSUIElement
48 | 1
49 | NSMainNibFile
50 | MainMenu
51 | NSPrincipalClass
52 | NSApplication
53 |
54 |
55 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIProgressDelegate.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIProgressDelegate.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 13/04/2010.
6 | // Copyright 2010 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | @class ASIHTTPRequest;
10 |
11 | @protocol ASIProgressDelegate
12 |
13 | @optional
14 |
15 | // These methods are used to update UIProgressViews (iPhone OS) or NSProgressIndicators (Mac OS X)
16 | // If you are using a custom progress delegate, you may find it easier to implement didReceiveBytes / didSendBytes instead
17 | #if TARGET_OS_IPHONE
18 | - (void)setProgress:(float)newProgress;
19 | #else
20 | - (void)setDoubleValue:(double)newProgress;
21 | - (void)setMaxValue:(double)newMax;
22 | #endif
23 |
24 | // Called when the request receives some data - bytes is the length of that data
25 | - (void)request:(ASIHTTPRequest *)request didReceiveBytes:(long long)bytes;
26 |
27 | // Called when the request sends some data
28 | // The first 32KB (128KB on older platforms) of data sent is not included in this amount because of limitations with the CFNetwork API
29 | // bytes may be less than zero if a request needs to remove upload progress (probably because the request needs to run again)
30 | - (void)request:(ASIHTTPRequest *)request didSendBytes:(long long)bytes;
31 |
32 | // Called when a request needs to change the length of the content to download
33 | - (void)request:(ASIHTTPRequest *)request incrementDownloadSizeBy:(long long)newLength;
34 |
35 | // Called when a request needs to change the length of the content to upload
36 | // newLength may be less than zero when a request needs to remove the size of the internal buffer from progress tracking
37 | - (void)request:(ASIHTTPRequest *)request incrementUploadSizeBy:(long long)newLength;
38 | @end
39 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIDataDecompressor.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIDataDecompressor.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 17/08/2010.
6 | // Copyright 2010 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | // This is a helper class used by ASIHTTPRequest to handle inflating (decompressing) data in memory and on disk
10 | // You may also find it helpful if you need to inflate data and files yourself - see the class methods below
11 | // Most of the zlib stuff is based on the sample code by Mark Adler available at http://zlib.net
12 |
13 | #import
14 | #import
15 |
16 | @interface ASIDataDecompressor : NSObject {
17 | BOOL streamReady;
18 | z_stream zStream;
19 | }
20 |
21 | // Convenience constructor will call setupStream for you
22 | + (id)decompressor;
23 |
24 | // Uncompress the passed chunk of data
25 | - (NSData *)uncompressBytes:(Bytef *)bytes length:(NSUInteger)length error:(NSError **)err;
26 |
27 | // Convenience method - pass it some deflated data, and you'll get inflated data back
28 | + (NSData *)uncompressData:(NSData*)compressedData error:(NSError **)err;
29 |
30 | // Convenience method - pass it a file containing deflated data in sourcePath, and it will write inflated data to destinationPath
31 | + (BOOL)uncompressDataFromFile:(NSString *)sourcePath toFile:(NSString *)destinationPath error:(NSError **)err;
32 |
33 | // Sets up zlib to handle the inflating. You only need to call this yourself if you aren't using the convenience constructor 'decompressor'
34 | - (NSError *)setupStream;
35 |
36 | // Tells zlib to clean up. You need to call this if you need to cancel inflating part way through
37 | // If inflating finishes or fails, this method will be called automatically
38 | - (NSError *)closeStream;
39 |
40 | @property (atomic, assign, readonly) BOOL streamReady;
41 | @end
42 |
--------------------------------------------------------------------------------
/iTunesLyrics/pubilc_release_note.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | iTunesLyric App Changelog
5 | Most recent changes with links to updates.
6 | en
7 | -
8 | Version 2.0
9 |
10 |
12 | Lorem ipsum dolor sit amet, consectetur adipiscing elit.
13 | Suspendisse sed felis ac ante ultrices rhoncus. Etiam quis elit vel nibh placerat facilisis in id leo.
14 | Vestibulum nec tortor odio, nec malesuada libero. Cras vel convallis nunc.
15 | Suspendisse tristique massa eget velit consequat tincidunt. Praesent sodales hendrerit pretium.
16 |
17 | ]]>
18 |
19 | Sat, 26 Jul 2014 15:20:11 +0000
20 |
21 |
22 |
23 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIDataCompressor.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIDataCompressor.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 17/08/2010.
6 | // Copyright 2010 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | // This is a helper class used by ASIHTTPRequest to handle deflating (compressing) data in memory and on disk
10 | // You may also find it helpful if you need to deflate data and files yourself - see the class methods below
11 | // Most of the zlib stuff is based on the sample code by Mark Adler available at http://zlib.net
12 |
13 | #import
14 | #import
15 |
16 | @interface ASIDataCompressor : NSObject {
17 | BOOL streamReady;
18 | z_stream zStream;
19 | }
20 |
21 | // Convenience constructor will call setupStream for you
22 | + (id)compressor;
23 |
24 | // Compress the passed chunk of data
25 | // Passing YES for shouldFinish will finalize the deflated data - you must pass YES when you are on the last chunk of data
26 | - (NSData *)compressBytes:(Bytef *)bytes length:(NSUInteger)length error:(NSError **)err shouldFinish:(BOOL)shouldFinish;
27 |
28 | // Convenience method - pass it some data, and you'll get deflated data back
29 | + (NSData *)compressData:(NSData*)uncompressedData error:(NSError **)err;
30 |
31 | // Convenience method - pass it a file containing the data to compress in sourcePath, and it will write deflated data to destinationPath
32 | + (BOOL)compressDataFromFile:(NSString *)sourcePath toFile:(NSString *)destinationPath error:(NSError **)err;
33 |
34 | // Sets up zlib to handle the inflating. You only need to call this yourself if you aren't using the convenience constructor 'compressor'
35 | - (NSError *)setupStream;
36 |
37 | // Tells zlib to clean up. You need to call this if you need to cancel deflating part way through
38 | // If deflating finishes or fails, this method will be called automatically
39 | - (NSError *)closeStream;
40 |
41 | @property (atomic, assign, readonly) BOOL streamReady;
42 | @end
43 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIDownloadCache.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIDownloadCache.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 01/05/2010.
6 | // Copyright 2010 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "ASICacheDelegate.h"
11 |
12 | @interface ASIDownloadCache : NSObject {
13 |
14 | // The default cache policy for this cache
15 | // Requests that store data in the cache will use this cache policy if their cache policy is set to ASIUseDefaultCachePolicy
16 | // Defaults to ASIAskServerIfModifiedWhenStaleCachePolicy
17 | ASICachePolicy defaultCachePolicy;
18 |
19 | // The directory in which cached data will be stored
20 | // Defaults to a directory called 'ASIHTTPRequestCache' in the temporary directory
21 | NSString *storagePath;
22 |
23 | // Mediates access to the cache
24 | NSRecursiveLock *accessLock;
25 |
26 | // When YES, the cache will look for cache-control / pragma: no-cache headers, and won't reuse store responses if it finds them
27 | BOOL shouldRespectCacheControlHeaders;
28 | }
29 |
30 | // Returns a static instance of an ASIDownloadCache
31 | // In most circumstances, it will make sense to use this as a global cache, rather than creating your own cache
32 | // To make ASIHTTPRequests use it automatically, use [ASIHTTPRequest setDefaultCache:[ASIDownloadCache sharedCache]];
33 | + (id)sharedCache;
34 |
35 | // A helper function that determines if the server has requested data should not be cached by looking at the request's response headers
36 | + (BOOL)serverAllowsResponseCachingForRequest:(ASIHTTPRequest *)request;
37 |
38 | // A list of file extensions that we know won't be readable by a webview when accessed locally
39 | // If we're asking for a path to cache a particular url and it has one of these extensions, we change it to '.html'
40 | + (NSArray *)fileExtensionsToHandleAsHTML;
41 |
42 | @property (assign, nonatomic) ASICachePolicy defaultCachePolicy;
43 | @property (retain, nonatomic) NSString *storagePath;
44 | @property (atomic, retain) NSRecursiveLock *accessLock;
45 | @property (atomic, assign) BOOL shouldRespectCacheControlHeaders;
46 | @end
47 |
--------------------------------------------------------------------------------
/iTunesLyrics/dsa_pub.pem:
--------------------------------------------------------------------------------
1 | -----BEGIN PUBLIC KEY-----
2 | MIIGOjCCBC0GByqGSM44BAEwggQgAoICAQCUaJ1MEhmmlhixcVKyghtRNMQPMsEv
3 | ex3E/kElEoXNUQehXzRrxrUE0qJa6i9SYsgKVyfxJjV8N3tmAFV/rFoH1ieoTE4o
4 | N1+xGcFSzvpyVa+EE8j1yznhTerDTJ2uyanjzm/wgyDsegbo8/PzPm0vGbEoa8Q5
5 | cy/abMUUl5NFCI6GR6IprkpxEZb05GYtd3bNRsX+woEteGSZTXb7172ycSKyfdbx
6 | rumAcjchzFwGG/pLpDVv9jmiHB+iJwmD+ygWPlZs1v4a90n9p9SinnzCbavvFxpn
7 | XbixfE+NtPm2sCbYMJ8EExnBUdSxTrZCkA5XxCdXq97kv1YswX5AaqKtCdMcrL8t
8 | zuqj9TYYFGmTDN2FzXAOErHeFbQ2RwSyvJ/zzqBH4awK6rT+sFXy3B+oif42vi2S
9 | 6smC4Pm+Q9usCeJujD9r5KWQD0kNh8p/lhdCq6kLg8jmEggf4ZrAmxmK8YNV/ftc
10 | iNynpJW23q/QK8QeyyneuZrEMdTNlOXkFShm47mtFIe/eFG9CZo6z78HQoudthue
11 | XmO6FqQw/XQeDkOMI7qRuP8cfLyIZccQqUCxTW+/0/AIRdVEfqPb8P9d4jFINuNn
12 | Ma03e9nNN8WCWrpjzWfEk5M4ZqnknwhmJM907V+WUsUmrO8WS6v7qybJxr+l+Xcm
13 | kN1nOpkiQcRv+wIVALTyjfEEH/S/cBFEjG+CaudQynOtAoICAB4GYSZQsCeust1M
14 | wPXujiSo65dkXoYw54LvZroiT3x+Ko5aJz1FYwGZ3aCpN3tSG1UzXaYb7GHiqa9r
15 | DS3OxCN6K33l/ZEb8OTT1SccOv1EmXHW9dwm40mHoyYnwIQ0U+WwJt181VbRf7ZQ
16 | WFl12Lwyd15Rxp2SF0EvafugtUJmrAVGpfiUmBeuysMlij7glYRqQeok9FylqONc
17 | 5/ospPY3PyedfMVQbTc6D6KwZZuEKZw9oM94EpZ0sJIVUM7aipDa2zHyoFWiE4q9
18 | FphvspcXmWCGrXSamfAKO4IxJlI9bU3LYD1rW/QjxyfQGgngjaBOMECYo7bbKiDp
19 | hXn6F3u/dO8681N6/igp4EW488PJ0/FfZmYNJ+YWkQCvJoz5BBHbbeCBOYnmWilo
20 | bE+qTK9AnWFM5ABt7nzWGlb69J6CxY+9MnSDuZ1BfaOnJG7+enOOc0F51w0x2bll
21 | yepYe/QTdsZyeBsFQxKd6SorK4EetuNNnoD4O7chFdNkB6pT8ehI+eu3KKfCme7+
22 | SLUI8R1He022J50QAj2qNM8TfFJtQm3HUSPCsEbrWbx1JyyBoNJKjOlD+bQBMgpX
23 | CcT9RaJ+pMA35QgERydZChnVU4m4fmFq2QpJqcyUwqDo+pY7LDz5nsqltfM6n+c0
24 | WZs+CXjSymGGrprz6TdpkxT+Xh9/A4ICBQACggIATAtUnDEV40+04k8Re8GkGmBD
25 | DNHdMGzVIe0kMWC+gRdTn9FsleiZpslO4384xyT0F3GffAlKFJ9+/VwShKMxrM+9
26 | eoxqUbLHa/MGnwt8sPWUCxlUaMdC3EZhSGEeSBieLxl7ZRKmKXwsSkGO691PL5yn
27 | LRI1cA9en9vNk3kKw3p09X+HWuifzbnppfxaeyVma5KnLHtIeDN8T7TubU4HYvU9
28 | xyuTWC5eRUKP5f4WOqRo3RpTcAMSHR95S0dWCwxjZr8xKXirfszlw1yVUdFStayF
29 | 6cwTijL6kCoMJIfNlAgEfhsEIu7EFh+cuvdvBLJl69bEBNPN668GnbV2Xuse6hS1
30 | UfEv7WwWqYvXekUihnpgG+9BJ2dy0XaexWs6Qe1vR1U/1OhXp+A+xPfio9SUhmq1
31 | SgXEl/Gp4waC1u76t3f2gmePbl84lJcyh5aa0liNxOF9sf64KB4JTffXRu6RFU/J
32 | UfYlE5xJ9VwdL4U03NI9tH6Z/jyeUku4YKhBTy8/fSFMPPBhxqW28QQfcohneIvn
33 | eZsBaxttTNIb+aEeM4TEOpxwZWtfIR9qOV4Raz9J3Mzs5wxRtpcVb5VGIQaP00af
34 | QC83Q7SP3nEB/BjiN8TMmYY4lv1Gi0zf1AuuMuPDmgdbJOwGo3eI27aFJgmh2RTg
35 | wmUteiP/TohZ9XRY1AE=
36 | -----END PUBLIC KEY-----
37 |
--------------------------------------------------------------------------------
/iTunesLyrics/UI/Preference/AppDelegate+Preference.m:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate+Preference.m
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/18/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import "AppDelegate+Preference.h"
10 | #import "Marco.h"
11 | #import "StatusBarView.h"
12 | #import "SearchLyricWindowController.h"
13 |
14 | @implementation AppDelegate(Preference)
15 |
16 | - (IBAction)colorChanged:(id)sender
17 | {
18 | [[NSNotificationCenter defaultCenter] postNotificationName: kNotificaiton_ColorChanged object: nil];
19 | }
20 |
21 | - (IBAction)fontChanged:(id)sender
22 | {
23 | [[NSNotificationCenter defaultCenter] postNotificationName: kNotification_FontChanged object: nil];
24 | }
25 |
26 | - (IBAction)startupChanged:(id)sender
27 | {
28 |
29 | }
30 |
31 | - (void)preference:(NSNotification *)n
32 | {
33 | switch ([[n object] integerValue]) {
34 | case kStatusPreferenceTag: {
35 | [NSApp activateIgnoringOtherApps:YES];
36 | [self.prefWindow makeKeyAndOrderFront: nil];
37 | }
38 | break;
39 | case kStatusSearchLyricTag: {
40 | [NSApp activateIgnoringOtherApps:YES];
41 | if (self.searchViewController == nil) {
42 | self.searchViewController = [[SearchLyricWindowController alloc] initWithWindowNibName: @"SearchLyricWindowController" Song: self.song];
43 | self.searchViewController.searchLyricDelegate = self;
44 | [self.searchViewController.window makeKeyAndOrderFront: nil];
45 | } else {
46 | self.searchViewController.song = self.song;
47 | [self.searchViewController.window makeKeyAndOrderFront: nil];
48 | }
49 | }
50 | break;
51 | case kStatusFeedbackTag: {
52 | [[NSWorkspace sharedWorkspace] openURL: [NSURL URLWithString: @"http://penny.li/2015/12/07/iTunesLyricApp/"]];
53 | }
54 | break;
55 | case kStatusAboutTag: {
56 | [NSApp orderFrontStandardAboutPanel: nil];
57 | }
58 | break;
59 | case kStatusCheckUpdateTag: {
60 | [self.updater checkForUpdates: nil];
61 | }
62 | break;
63 | default:
64 | break;
65 | }
66 |
67 | }
68 |
69 | - (void)hideLyricPanel:(NSNotification *)n
70 | {
71 | BOOL needHide = [[n object] boolValue];
72 | if (needHide) {
73 | [self.lyricWindow orderOut: nil];
74 | } else {
75 | NSString *lyric = self.lyricWindow.lyric;
76 | [self.lyricWindow setLyric: @""];
77 | [self.lyricWindow makeKeyAndOrderFront: nil];
78 | [self.lyricWindow setLyric: lyric];
79 | }
80 | }
81 | @end
82 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIFormDataRequest.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASIFormDataRequest.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 07/11/2008.
6 | // Copyright 2008-2009 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "ASIHTTPRequest.h"
11 | #import "ASIHTTPRequestConfig.h"
12 |
13 | typedef enum _ASIPostFormat {
14 | ASIMultipartFormDataPostFormat = 0,
15 | ASIURLEncodedPostFormat = 1
16 |
17 | } ASIPostFormat;
18 |
19 | @interface ASIFormDataRequest : ASIHTTPRequest {
20 |
21 | // Parameters that will be POSTed to the url
22 | NSMutableArray *postData;
23 |
24 | // Files that will be POSTed to the url
25 | NSMutableArray *fileData;
26 |
27 | ASIPostFormat postFormat;
28 |
29 | NSStringEncoding stringEncoding;
30 |
31 | #if DEBUG_FORM_DATA_REQUEST
32 | // Will store a string version of the request body that will be printed to the console when ASIHTTPREQUEST_DEBUG is set in GCC_PREPROCESSOR_DEFINITIONS
33 | NSString *debugBodyString;
34 | #endif
35 |
36 | }
37 |
38 | #pragma mark utilities
39 | - (NSString*)encodeURL:(NSString *)string;
40 |
41 | #pragma mark setup request
42 |
43 | // Add a POST variable to the request
44 | - (void)addPostValue:(id )value forKey:(NSString *)key;
45 |
46 | // Set a POST variable for this request, clearing any others with the same key
47 | - (void)setPostValue:(id )value forKey:(NSString *)key;
48 |
49 | // Add the contents of a local file to the request
50 | - (void)addFile:(NSString *)filePath forKey:(NSString *)key;
51 |
52 | // Same as above, but you can specify the content-type and file name
53 | - (void)addFile:(NSString *)filePath withFileName:(NSString *)fileName andContentType:(NSString *)contentType forKey:(NSString *)key;
54 |
55 | // Add the contents of a local file to the request, clearing any others with the same key
56 | - (void)setFile:(NSString *)filePath forKey:(NSString *)key;
57 |
58 | // Same as above, but you can specify the content-type and file name
59 | - (void)setFile:(NSString *)filePath withFileName:(NSString *)fileName andContentType:(NSString *)contentType forKey:(NSString *)key;
60 |
61 | // Add the contents of an NSData object to the request
62 | - (void)addData:(NSData *)data forKey:(NSString *)key;
63 |
64 | // Same as above, but you can specify the content-type and file name
65 | - (void)addData:(id)data withFileName:(NSString *)fileName andContentType:(NSString *)contentType forKey:(NSString *)key;
66 |
67 | // Add the contents of an NSData object to the request, clearing any others with the same key
68 | - (void)setData:(NSData *)data forKey:(NSString *)key;
69 |
70 | // Same as above, but you can specify the content-type and file name
71 | - (void)setData:(id)data withFileName:(NSString *)fileName andContentType:(NSString *)contentType forKey:(NSString *)key;
72 |
73 | @property (atomic, assign) ASIPostFormat postFormat;
74 | @property (atomic, assign) NSStringEncoding stringEncoding;
75 | @end
76 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIInputStream.m:
--------------------------------------------------------------------------------
1 | //
2 | // ASIInputStream.m
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 10/08/2009.
6 | // Copyright 2009 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import "ASIInputStream.h"
10 | #import "ASIHTTPRequest.h"
11 |
12 | // Used to ensure only one request can read data at once
13 | static NSLock *readLock = nil;
14 |
15 | @implementation ASIInputStream
16 |
17 | + (void)initialize
18 | {
19 | if (self == [ASIInputStream class]) {
20 | readLock = [[NSLock alloc] init];
21 | }
22 | }
23 |
24 | + (id)inputStreamWithFileAtPath:(NSString *)path request:(ASIHTTPRequest *)theRequest
25 | {
26 | ASIInputStream *theStream = [[[self alloc] init] autorelease];
27 | [theStream setRequest:theRequest];
28 | [theStream setStream:[NSInputStream inputStreamWithFileAtPath:path]];
29 | return theStream;
30 | }
31 |
32 | + (id)inputStreamWithData:(NSData *)data request:(ASIHTTPRequest *)theRequest
33 | {
34 | ASIInputStream *theStream = [[[self alloc] init] autorelease];
35 | [theStream setRequest:theRequest];
36 | [theStream setStream:[NSInputStream inputStreamWithData:data]];
37 | return theStream;
38 | }
39 |
40 | - (void)dealloc
41 | {
42 | [stream release];
43 | [super dealloc];
44 | }
45 |
46 | // Called when CFNetwork wants to read more of our request body
47 | // When throttling is on, we ask ASIHTTPRequest for the maximum amount of data we can read
48 | - (NSInteger)read:(uint8_t *)buffer maxLength:(NSUInteger)len
49 | {
50 | [readLock lock];
51 | unsigned long toRead = len;
52 | if ([ASIHTTPRequest isBandwidthThrottled]) {
53 | toRead = [ASIHTTPRequest maxUploadReadLength];
54 | if (toRead > len) {
55 | toRead = len;
56 | } else if (toRead == 0) {
57 | toRead = 1;
58 | }
59 | [request performThrottling];
60 | }
61 | [readLock unlock];
62 | NSInteger rv = [stream read:buffer maxLength:toRead];
63 | if (rv > 0)
64 | [ASIHTTPRequest incrementBandwidthUsedInLastSecond:(NSUInteger)rv];
65 | return rv;
66 | }
67 |
68 | /*
69 | * Implement NSInputStream mandatory methods to make sure they are implemented
70 | * (necessary for MacRuby for example) and avoid the overhead of method
71 | * forwarding for these common methods.
72 | */
73 | - (void)open
74 | {
75 | [stream open];
76 | }
77 |
78 | - (void)close
79 | {
80 | [stream close];
81 | }
82 |
83 | - (id)delegate
84 | {
85 | return [stream delegate];
86 | }
87 |
88 | - (void)setDelegate:(id)delegate
89 | {
90 | [stream setDelegate:delegate];
91 | }
92 |
93 | - (void)scheduleInRunLoop:(NSRunLoop *)aRunLoop forMode:(NSString *)mode
94 | {
95 | [stream scheduleInRunLoop:aRunLoop forMode:mode];
96 | }
97 |
98 | - (void)removeFromRunLoop:(NSRunLoop *)aRunLoop forMode:(NSString *)mode
99 | {
100 | [stream removeFromRunLoop:aRunLoop forMode:mode];
101 | }
102 |
103 | - (id)propertyForKey:(NSString *)key
104 | {
105 | return [stream propertyForKey:key];
106 | }
107 |
108 | - (BOOL)setProperty:(id)property forKey:(NSString *)key
109 | {
110 | return [stream setProperty:property forKey:key];
111 | }
112 |
113 | - (NSStreamStatus)streamStatus
114 | {
115 | return [stream streamStatus];
116 | }
117 |
118 | - (NSError *)streamError
119 | {
120 | return [stream streamError];
121 | }
122 |
123 | // If we get asked to perform a method we don't have (probably internal ones),
124 | // we'll just forward the message to our stream
125 |
126 | - (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector
127 | {
128 | return [stream methodSignatureForSelector:aSelector];
129 | }
130 |
131 | - (void)forwardInvocation:(NSInvocation *)anInvocation
132 | {
133 | [anInvocation invokeWithTarget:stream];
134 | }
135 |
136 | @synthesize stream;
137 | @synthesize request;
138 | @end
139 |
--------------------------------------------------------------------------------
/iTunesLyrics.xcodeproj/xcuserdata/Penny.xcuserdatad/xcschemes/iTunesLyrics.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
29 |
35 |
36 |
37 |
38 |
39 |
44 |
45 |
47 |
53 |
54 |
55 |
56 |
57 |
63 |
64 |
65 |
66 |
75 |
77 |
83 |
84 |
85 |
86 |
87 |
88 |
94 |
96 |
102 |
103 |
104 |
105 |
107 |
108 |
111 |
112 |
113 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASINetworkQueue.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASINetworkQueue.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 07/11/2008.
6 | // Copyright 2008-2009 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "ASIHTTPRequestDelegate.h"
11 | #import "ASIProgressDelegate.h"
12 |
13 | @interface ASINetworkQueue : NSOperationQueue {
14 |
15 | // Delegate will get didFail + didFinish messages (if set)
16 | id delegate;
17 |
18 | // Will be called when a request starts with the request as the argument
19 | SEL requestDidStartSelector;
20 |
21 | // Will be called when a request receives response headers
22 | // Should take the form request:didRecieveResponseHeaders:, where the first argument is the request, and the second the headers dictionary
23 | SEL requestDidReceiveResponseHeadersSelector;
24 |
25 | // Will be called when a request is about to redirect
26 | // Should take the form request:willRedirectToURL:, where the first argument is the request, and the second the new url
27 | SEL requestWillRedirectSelector;
28 |
29 | // Will be called when a request completes with the request as the argument
30 | SEL requestDidFinishSelector;
31 |
32 | // Will be called when a request fails with the request as the argument
33 | SEL requestDidFailSelector;
34 |
35 | // Will be called when the queue finishes with the queue as the argument
36 | SEL queueDidFinishSelector;
37 |
38 | // Upload progress indicator, probably an NSProgressIndicator or UIProgressView
39 | id uploadProgressDelegate;
40 |
41 | // Total amount uploaded so far for all requests in this queue
42 | unsigned long long bytesUploadedSoFar;
43 |
44 | // Total amount to be uploaded for all requests in this queue - requests add to this figure as they work out how much data they have to transmit
45 | unsigned long long totalBytesToUpload;
46 |
47 | // Download progress indicator, probably an NSProgressIndicator or UIProgressView
48 | id downloadProgressDelegate;
49 |
50 | // Total amount downloaded so far for all requests in this queue
51 | unsigned long long bytesDownloadedSoFar;
52 |
53 | // Total amount to be downloaded for all requests in this queue - requests add to this figure as they receive Content-Length headers
54 | unsigned long long totalBytesToDownload;
55 |
56 | // When YES, the queue will cancel all requests when a request fails. Default is YES
57 | BOOL shouldCancelAllRequestsOnFailure;
58 |
59 | //Number of real requests (excludes HEAD requests created to manage showAccurateProgress)
60 | int requestsCount;
61 |
62 | // When NO, this request will only update the progress indicator when it completes
63 | // When YES, this request will update the progress indicator according to how much data it has received so far
64 | // When YES, the queue will first perform HEAD requests for all GET requests in the queue, so it can calculate the total download size before it starts
65 | // NO means better performance, because it skips this step for GET requests, and it won't waste time updating the progress indicator until a request completes
66 | // Set to YES if the size of a requests in the queue varies greatly for much more accurate results
67 | // Default for requests in the queue is NO
68 | BOOL showAccurateProgress;
69 |
70 | // Storage container for additional queue information.
71 | NSDictionary *userInfo;
72 |
73 | }
74 |
75 | // Convenience constructor
76 | + (id)queue;
77 |
78 | // Call this to reset a queue - it will cancel all operations, clear delegates, and suspend operation
79 | - (void)reset;
80 |
81 | // Used internally to manage HEAD requests when showAccurateProgress is YES, do not use!
82 | - (void)addHEADOperation:(NSOperation *)operation;
83 |
84 | // All ASINetworkQueues are paused when created so that total size can be calculated before the queue starts
85 | // This method will start the queue
86 | - (void)go;
87 |
88 | @property (assign, nonatomic, setter=setUploadProgressDelegate:) id uploadProgressDelegate;
89 | @property (assign, nonatomic, setter=setDownloadProgressDelegate:) id downloadProgressDelegate;
90 |
91 | @property (assign, atomic) SEL requestDidStartSelector;
92 | @property (assign, atomic) SEL requestDidReceiveResponseHeadersSelector;
93 | @property (assign, atomic) SEL requestWillRedirectSelector;
94 | @property (assign, atomic) SEL requestDidFinishSelector;
95 | @property (assign, atomic) SEL requestDidFailSelector;
96 | @property (assign, atomic) SEL queueDidFinishSelector;
97 | @property (assign, atomic) BOOL shouldCancelAllRequestsOnFailure;
98 | @property (assign, atomic) id delegate;
99 | @property (assign, atomic) BOOL showAccurateProgress;
100 | @property (assign, atomic, readonly) int requestsCount;
101 | @property (retain, atomic) NSDictionary *userInfo;
102 |
103 | @property (assign, atomic) unsigned long long bytesUploadedSoFar;
104 | @property (assign, atomic) unsigned long long totalBytesToUpload;
105 | @property (assign, atomic) unsigned long long bytesDownloadedSoFar;
106 | @property (assign, atomic) unsigned long long totalBytesToDownload;
107 |
108 | @end
109 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASICacheDelegate.h:
--------------------------------------------------------------------------------
1 | //
2 | // ASICacheDelegate.h
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 01/05/2010.
6 | // Copyright 2010 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import
10 | @class ASIHTTPRequest;
11 |
12 | // Cache policies control the behaviour of a cache and how requests use the cache
13 | // When setting a cache policy, you can use a combination of these values as a bitmask
14 | // For example: [request setCachePolicy:ASIAskServerIfModifiedCachePolicy|ASIFallbackToCacheIfLoadFailsCachePolicy|ASIDoNotWriteToCacheCachePolicy];
15 | // Note that some of the behaviours below are mutally exclusive - you cannot combine ASIAskServerIfModifiedWhenStaleCachePolicy and ASIAskServerIfModifiedCachePolicy, for example.
16 | typedef enum _ASICachePolicy {
17 |
18 | // The default cache policy. When you set a request to use this, it will use the cache's defaultCachePolicy
19 | // ASIDownloadCache's default cache policy is 'ASIAskServerIfModifiedWhenStaleCachePolicy'
20 | ASIUseDefaultCachePolicy = 0,
21 |
22 | // Tell the request not to read from the cache
23 | ASIDoNotReadFromCacheCachePolicy = 1,
24 |
25 | // The the request not to write to the cache
26 | ASIDoNotWriteToCacheCachePolicy = 2,
27 |
28 | // Ask the server if there is an updated version of this resource (using a conditional GET) ONLY when the cached data is stale
29 | ASIAskServerIfModifiedWhenStaleCachePolicy = 4,
30 |
31 | // Always ask the server if there is an updated version of this resource (using a conditional GET)
32 | ASIAskServerIfModifiedCachePolicy = 8,
33 |
34 | // If cached data exists, use it even if it is stale. This means requests will not talk to the server unless the resource they are requesting is not in the cache
35 | ASIOnlyLoadIfNotCachedCachePolicy = 16,
36 |
37 | // If cached data exists, use it even if it is stale. If cached data does not exist, stop (will not set an error on the request)
38 | ASIDontLoadCachePolicy = 32,
39 |
40 | // Specifies that cached data may be used if the request fails. If cached data is used, the request will succeed without error. Usually used in combination with other options above.
41 | ASIFallbackToCacheIfLoadFailsCachePolicy = 64
42 | } ASICachePolicy;
43 |
44 | // Cache storage policies control whether cached data persists between application launches (ASICachePermanentlyCacheStoragePolicy) or not (ASICacheForSessionDurationCacheStoragePolicy)
45 | // Calling [ASIHTTPRequest clearSession] will remove any data stored using ASICacheForSessionDurationCacheStoragePolicy
46 | typedef enum _ASICacheStoragePolicy {
47 | ASICacheForSessionDurationCacheStoragePolicy = 0,
48 | ASICachePermanentlyCacheStoragePolicy = 1
49 | } ASICacheStoragePolicy;
50 |
51 |
52 | @protocol ASICacheDelegate
53 |
54 | @required
55 |
56 | // Should return the cache policy that will be used when requests have their cache policy set to ASIUseDefaultCachePolicy
57 | - (ASICachePolicy)defaultCachePolicy;
58 |
59 | // Returns the date a cached response should expire on. Pass a non-zero max age to specify a custom date.
60 | - (NSDate *)expiryDateForRequest:(ASIHTTPRequest *)request maxAge:(NSTimeInterval)maxAge;
61 |
62 | // Updates cached response headers with a new expiry date. Pass a non-zero max age to specify a custom date.
63 | - (void)updateExpiryForRequest:(ASIHTTPRequest *)request maxAge:(NSTimeInterval)maxAge;
64 |
65 | // Looks at the request's cache policy and any cached headers to determine if the cache data is still valid
66 | - (BOOL)canUseCachedDataForRequest:(ASIHTTPRequest *)request;
67 |
68 | // Removes cached data for a particular request
69 | - (void)removeCachedDataForRequest:(ASIHTTPRequest *)request;
70 |
71 | // Should return YES if the cache considers its cached response current for the request
72 | // Should return NO is the data is not cached, or (for example) if the cached headers state the request should have expired
73 | - (BOOL)isCachedDataCurrentForRequest:(ASIHTTPRequest *)request;
74 |
75 | // Should store the response for the passed request in the cache
76 | // When a non-zero maxAge is passed, it should be used as the expiry time for the cached response
77 | - (void)storeResponseForRequest:(ASIHTTPRequest *)request maxAge:(NSTimeInterval)maxAge;
78 |
79 | // Removes cached data for a particular url
80 | - (void)removeCachedDataForURL:(NSURL *)url;
81 |
82 | // Should return an NSDictionary of cached headers for the passed URL, if it is stored in the cache
83 | - (NSDictionary *)cachedResponseHeadersForURL:(NSURL *)url;
84 |
85 | // Should return the cached body of a response for the passed URL, if it is stored in the cache
86 | - (NSData *)cachedResponseDataForURL:(NSURL *)url;
87 |
88 | // Returns a path to the cached response data, if it exists
89 | - (NSString *)pathToCachedResponseDataForURL:(NSURL *)url;
90 |
91 | // Returns a path to the cached response headers, if they url
92 | - (NSString *)pathToCachedResponseHeadersForURL:(NSURL *)url;
93 |
94 | // Returns the location to use to store cached response headers for a particular request
95 | - (NSString *)pathToStoreCachedResponseHeadersForRequest:(ASIHTTPRequest *)request;
96 |
97 | // Returns the location to use to store a cached response body for a particular request
98 | - (NSString *)pathToStoreCachedResponseDataForRequest:(ASIHTTPRequest *)request;
99 |
100 | // Clear cached data stored for the passed storage policy
101 | - (void)clearCachedResponsesForStoragePolicy:(ASICacheStoragePolicy)cachePolicy;
102 |
103 | @end
104 |
--------------------------------------------------------------------------------
/iTunesLyrics/UI/Search/SearchLyricWindowController.m:
--------------------------------------------------------------------------------
1 | //
2 | // SearchLyricWindowController.m
3 | // iTunesLyrics
4 | //
5 | // Created by 鹏 李 on 15/12/5.
6 | // Copyright © 2015年 Cocoamad. All rights reserved.
7 | //
8 |
9 | #import "SearchLyricWindowController.h"
10 | #import "iTunesLyricHelper.h"
11 | #import "Marco.h"
12 |
13 | @interface SearchLyricWindowController ()
14 |
15 | @end
16 |
17 | @implementation SearchLyricWindowController
18 |
19 | - (instancetype)initWithWindowNibName:(NSString *)windowNibName Song:(Song *)song
20 | {
21 | if (self = [super initWithWindowNibName: windowNibName]) {
22 | // set preference window
23 | self.window.appearance = [NSAppearance appearanceNamed: NSAppearanceNameVibrantDark];
24 | self.song = song;
25 | }
26 | return self;
27 | }
28 |
29 | - (void)setSong:(Song *)song
30 | {
31 | if (![song.name isEqualToString: self.song.name]) {
32 | _song = song;
33 | _songs = nil;
34 | [self.tableView reloadData];
35 | }
36 | [self updateCurrentPlayingSongInfoUI];
37 | }
38 |
39 | - (void)windowDidLoad {
40 | [super windowDidLoad];
41 |
42 | // Implement this method to handle any initialization after your window controller's window has been loaded from its nib file.
43 | self.indicator = [[NSProgressIndicator alloc] initWithFrame: NSMakeRect(0, 0, 20, 20)];
44 | self.indicator.style = NSProgressIndicatorSpinningStyle;
45 | self.indicator.frame = CGRectMake((CGRectGetWidth(self.tableView.frame) - 20) * .5, (CGRectGetHeight(self.tableView.frame) - 20) * .5, 20, 20);
46 | self.indicator.autoresizingMask = NSViewMinXMargin | NSViewMaxXMargin | NSViewMinYMargin | NSViewMaxYMargin;
47 | [self.tableView addSubview: self.indicator];
48 | self.indicator.hidden = YES;
49 |
50 | [self updateCurrentPlayingSongInfoUI];
51 |
52 | [self.tableView setDoubleAction: @selector(importLyric:)];
53 |
54 | }
55 |
56 | - (void)updateCurrentPlayingSongInfoUI
57 | {
58 | if (self.song.name.length) {
59 | self.searchField.stringValue = self.song.name;
60 | self.songNameLabel.stringValue = self.song.name;
61 | }
62 | if (self.song.artist.length) {
63 | self.singerNameLabel.stringValue = self.song.artist;
64 | }
65 |
66 | if (self.song.album.length) {
67 | self.albumLabel.stringValue = self.song.album;
68 | }
69 |
70 | self.durationLabel.stringValue = [NSString stringWithFormat:@"%.2ld:%.2ld",self.song.duration / 60,self.song.duration % 60];
71 | }
72 |
73 | - (BOOL)control:(NSControl *)control textView:(NSTextView *)textView doCommandBySelector:(SEL)commandSelector;
74 | {
75 | if ([@"insertNewline:" isEqualToString: NSStringFromSelector(commandSelector)]) {
76 | NSString *searchSongName = self.searchField.stringValue;
77 | if (searchSongName.length != 0) {
78 |
79 | [self lyricListFetchBegin];
80 | [[iTunesLyricHelper shareHelper] fetchLyricListWithName: searchSongName completeBlock:^(NSArray *songs) {
81 | [self lyricListFetchFinished: songs];
82 | }];
83 | }
84 | }
85 | return NO;
86 | }
87 |
88 | - (void)lyricListFetchBegin
89 | {
90 | self.indicator.hidden = NO;
91 | [self.indicator startAnimation: nil];
92 | }
93 |
94 | - (void)lyricListFetchFinished:(NSArray *)songs
95 | {
96 | [self.indicator stopAnimation: nil];
97 | self.indicator.hidden = YES;
98 |
99 | if (songs.count) {
100 | _songs = songs;
101 | [self.tableView reloadData];
102 | } else
103 | _songs = [NSArray array];
104 | }
105 |
106 | #pragma mark - TableView
107 | - (nullable NSView *)tableView:(NSTableView *)tableView viewForTableColumn:(nullable NSTableColumn *)tableColumn row:(NSInteger)row NS_AVAILABLE_MAC(10_7)
108 | {
109 | Song *song = _songs[row];
110 |
111 | NSTableCellView *view = [tableView makeViewWithIdentifier: tableColumn.identifier owner: self];
112 | NSString *identifier = tableColumn.identifier;
113 | NSString *value = @"";
114 |
115 | if ([identifier isEqualToString: @"duration"]) {
116 | value = [NSString stringWithFormat:@"%.2ld:%.2ld",song.duration / 60,song.duration % 60];;
117 | } if ([identifier isEqualToString: @"name"]) {
118 | value = song.name;
119 | } else if ([identifier isEqualToString: @"score"]) {
120 | value = [NSString stringWithFormat: @"%ld", (long)song.score];
121 | } else if ([identifier isEqualToString: @"album"]) {
122 | value = song.album;
123 | } else if ([identifier isEqualToString: @"artist"]) {
124 | value = song.artist;
125 | }
126 |
127 | view.textField.stringValue = value;
128 |
129 | return view;
130 | }
131 |
132 | - (CGFloat)tableView:(NSTableView *)tableView heightOfRow:(NSInteger)row
133 | {
134 | return 20;
135 | }
136 |
137 | - (NSInteger)numberOfRowsInTableView:(NSTableView *)tableView
138 | {
139 | return _songs.count;
140 | }
141 |
142 | #pragma mark -
143 | - (void)importLyric:(NSTableView *)tableView
144 | {
145 | NSInteger index = [tableView selectedRow];
146 | if (index != NSNotFound && index < _songs.count) {
147 |
148 | [self.searchLyricDelegate searchLyricWillBegin];
149 |
150 | Song *song = _songs[index];
151 | [[iTunesLyricHelper shareHelper] fetchLyricWithSong: song completeBlock:^(Song *final_song) {
152 | if (self.searchLyricDelegate && [self.searchLyricDelegate respondsToSelector: @selector(searchLyricDidImportLyricToSong:)]) {
153 | [self.searchLyricDelegate searchLyricDidImportLyricToSong: final_song];
154 | }
155 | }];
156 | }
157 | }
158 |
159 | @end
160 |
--------------------------------------------------------------------------------
/iTunesLyrics.xcodeproj/xcuserdata/Penny.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
8 |
20 |
21 |
22 |
24 |
36 |
37 |
38 |
40 |
52 |
53 |
54 |
56 |
68 |
69 |
70 |
72 |
84 |
85 |
86 |
88 |
100 |
101 |
102 |
104 |
116 |
117 |
118 |
120 |
132 |
133 |
134 |
135 |
136 |
--------------------------------------------------------------------------------
/iTunesLyrics/UI/StatusBar/StatusBarView.m:
--------------------------------------------------------------------------------
1 | //
2 | // StatusBarView.m
3 | // iTips
4 | //
5 | // Created by Penny on 12-9-22.
6 | // Copyright (c) 2012年 Penny. All rights reserved.
7 | //
8 |
9 | #import "StatusBarView.h"
10 | #import "Marco.h"
11 |
12 | @interface StatusBarView()
13 | -(void)initStatusMenu;
14 | @end
15 |
16 | @implementation StatusBarView
17 |
18 | - (id)initWithFrame:(NSRect)frame
19 | {
20 | // Initialization code here.
21 | statusItem = [[NSStatusBar systemStatusBar] statusItemWithLength: -2];
22 | CGFloat itemWidth = [statusItem length];
23 | CGFloat itemHeight = [[NSStatusBar systemStatusBar] thickness];
24 | NSRect itemRect = NSMakeRect(0.0, 0.0, itemWidth, itemHeight);
25 | [statusItem setHighlightMode: YES];
26 | [self initStatusMenu];
27 | if (self = [super initWithFrame: itemRect]) {
28 | [statusItem setView: self];
29 | [statusItem setHighlightMode: YES];
30 | NSImage *normalImage = [NSImage imageNamed:@"star"];
31 | normalIcon = [normalImage CGImage];
32 | }
33 |
34 | return self;
35 | }
36 |
37 | - (void)dealloc
38 | {
39 | CGImageRelease(normalIcon);
40 | [statusMenu removeAllItems];
41 | [[NSStatusBar systemStatusBar] removeStatusItem: statusItem];
42 | }
43 |
44 | - (void)drawRect:(NSRect)dirtyRect
45 | {
46 | [statusItem drawStatusBarBackgroundInRect: dirtyRect withHighlight: isHiLight];
47 | CGContextRef cxt = (CGContextRef)[[NSGraphicsContext currentContext] graphicsPort];
48 |
49 | NSSize iconSize = NSMakeSize(18, 18);
50 | NSRect bound = [self bounds];
51 | CGFloat iconX = roundf((float)(NSWidth(bound) - iconSize.width) / 2);
52 | CGFloat iconY = roundf((float)(NSHeight(bound) - iconSize.height) / 2);
53 | NSRect rect = NSMakeRect(iconX, iconY, 18, 18);
54 | CGContextDrawImage(cxt, rect, normalIcon);
55 | }
56 |
57 | #pragma mark Private Method
58 | - (void)initStatusMenu
59 | {
60 | statusMenu = [[NSMenu allocWithZone: [NSMenu menuZone]] initWithTitle: @"menu"];
61 | statusMenu.delegate = self;
62 | NSMenuItem *newItem = nil;
63 |
64 | newItem = [[NSMenuItem allocWithZone: [NSMenu menuZone]] initWithTitle: @"隐藏歌词" action: @selector(hideLyric:) keyEquivalent: @""];
65 | newItem.tag = kStatusShowLyricTag;
66 |
67 | [newItem setTarget: self];
68 | [newItem setEnabled: YES];
69 | [statusMenu addItem: newItem];
70 |
71 | newItem = [[NSMenuItem allocWithZone: [NSMenu menuZone]] initWithTitle: @"搜索歌词..." action: @selector(showPreference:) keyEquivalent: @""];
72 | newItem.tag = kStatusSearchLyricTag;
73 |
74 | [newItem setTarget: self];
75 | [newItem setEnabled: YES];
76 | [statusMenu addItem: newItem];
77 |
78 | [statusMenu addItem: [NSMenuItem separatorItem]];
79 |
80 | newItem = [[NSMenuItem allocWithZone: [NSMenu menuZone]] initWithTitle: @"偏好设置..." action: @selector(showPreference:) keyEquivalent: @""];
81 | newItem.tag = kStatusPreferenceTag;
82 | [newItem setTarget: self];
83 | [newItem setEnabled: YES];
84 | [statusMenu addItem: newItem];
85 |
86 | // newItem = [[NSMenuItem allocWithZone: [NSMenu menuZone]] initWithTitle: @"检查更新..." action: @selector(showPreference:) keyEquivalent: @""];
87 | // newItem.tag = kStatusCheckUpdateTag;
88 | // [newItem setTarget: self];
89 | // [newItem setEnabled: YES];
90 | // [statusMenu addItem: newItem];
91 |
92 | [statusMenu addItem: [NSMenuItem separatorItem]];
93 |
94 | newItem = [[NSMenuItem allocWithZone: [NSMenu menuZone]] initWithTitle: @"反馈..." action: @selector(showPreference:) keyEquivalent: @""];
95 | [newItem setTarget: self];
96 | [newItem setEnabled: YES];
97 | newItem.tag = kStatusFeedbackTag;
98 | [statusMenu addItem: newItem];
99 |
100 | newItem = [[NSMenuItem allocWithZone: [NSMenu menuZone]] initWithTitle: @"关于..." action: @selector(showPreference:) keyEquivalent: @""];
101 | [newItem setTarget: self];
102 | [newItem setEnabled: YES];
103 | newItem.tag = kStatusAboutTag;
104 | [statusMenu addItem: newItem];
105 |
106 | [statusMenu addItem: [NSMenuItem separatorItem]];
107 |
108 | newItem = [[NSMenuItem allocWithZone: [NSMenu menuZone]] initWithTitle: @"Quit" action: @selector(quit) keyEquivalent: @""];
109 | [newItem setTarget: self];
110 | [newItem setEnabled: YES];
111 | newItem.tag = kStatusQuitTag;
112 | [statusMenu addItem: newItem];
113 |
114 | }
115 | #pragma mark Mouse Event
116 |
117 | - (void)rightMouseDown:(NSEvent *)theEvent
118 | {
119 | isHiLight = YES;
120 | [self setNeedsDisplay: YES];
121 | [statusItem popUpStatusItemMenu: statusMenu];
122 | [super rightMouseDown: theEvent];
123 | }
124 |
125 | - (void)mouseDown:(NSEvent *)theEvent
126 | {
127 | isHiLight = YES;
128 | [self setNeedsDisplay: YES];
129 | [statusItem popUpStatusItemMenu: statusMenu];
130 | [super mouseDown: theEvent];
131 | }
132 |
133 | - (void)mouseUp:(NSEvent *)theEvent
134 | {
135 | isHiLight = NO;
136 | [self setNeedsDisplay: YES];
137 | [super mouseUp: theEvent];
138 | }
139 |
140 | #pragma mark NSMenu Delegate
141 | - (void)menuWillOpen:(NSMenu *)menu
142 | {
143 | isHiLight = YES;
144 | [self setNeedsDisplay: YES];
145 | }
146 |
147 | - (void)menuDidClose:(NSMenu *)menu
148 | {
149 | isHiLight = NO;
150 | [self setNeedsDisplay: YES];
151 | }
152 |
153 | #pragma mark NSMenu Action
154 |
155 | - (void)hideLyric:(NSMenuItem *)item
156 | {
157 | BOOL needHide = NO;
158 | if ([item.title isEqualToString: @"隐藏歌词"]) { // show lyric
159 | item.title = @"显示歌词";
160 | needHide = YES;
161 | } else { // hide lyric
162 | item.title = @"隐藏歌词";
163 | }
164 |
165 | [[NSNotificationCenter defaultCenter] postNotificationName: kNotification_HideLyric object: @(needHide)];
166 | }
167 |
168 | - (void)showPreference:(NSMenuItem *)item
169 | {
170 | [[NSNotificationCenter defaultCenter] postNotificationName: kNotification_ShowWindow object: @(item.tag)];
171 | }
172 |
173 | - (void)quit
174 | {
175 | [[NSApplication sharedApplication] terminate: nil];
176 | }
177 |
178 | @end
--------------------------------------------------------------------------------
/iTunesLyrics/UI/LyricWindow/LyricDisplayWindow.m:
--------------------------------------------------------------------------------
1 | //
2 | // LyricDisplayWindow.m
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/18/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import "LyricDisplayWindow.h"
10 | #import "Utils.h"
11 |
12 | @interface InnerView : NSView
13 | @property (nonatomic, strong) NSString *text;
14 | @property (nonatomic, strong) NSColor *color;
15 | @property (nonatomic, strong) NSFont *font;
16 |
17 | @property (nonatomic, assign) BOOL mouseIn;
18 |
19 | @property (nonatomic, strong) NSTrackingArea *trackingArea;
20 | @end
21 |
22 | @implementation InnerView
23 |
24 | - (id)initWithFrame:(NSRect)frameRect
25 | {
26 | if (self = [super initWithFrame: frameRect]) {
27 |
28 | [self updateTrackingAreas];
29 |
30 | [[NSNotificationCenter defaultCenter] addObserver: self selector: @selector(colorChanged:) name: kNotificaiton_ColorChanged object: nil];
31 | [[NSNotificationCenter defaultCenter] addObserver: self selector: @selector(fontChanged:) name: kNotification_FontChanged object: nil];
32 |
33 | NSData *data = [[NSUserDefaults standardUserDefaults] objectForKey: @"lyricColor"];
34 | if (data) {
35 | self.color = (NSColor *)[NSUnarchiver unarchiveObjectWithData: data];
36 | }
37 |
38 | if (self.color == nil) {
39 | self.color = [NSColor redColor];
40 | }
41 |
42 | NSInteger fontSize = [[[NSUserDefaults standardUserDefaults] objectForKey: @"lyricFont"] integerValue];
43 | if (data) {
44 | self.font = [NSFont boldSystemFontOfSize: fontSize];
45 | }
46 |
47 | if (self.font == nil) {
48 | self.font = [NSFont boldSystemFontOfSize: 35];
49 | }
50 |
51 | }
52 | return self;
53 | }
54 |
55 | - (void)dealloc
56 | {
57 | [[NSNotificationCenter defaultCenter] removeObserver: self];
58 | }
59 |
60 | -(void)mouseEntered:(NSEvent *)theEvent
61 | {
62 | self.mouseIn = YES;
63 | [self setNeedsDisplay: YES];
64 | [super mouseEntered: theEvent];
65 | }
66 |
67 | -(void)mouseExited:(NSEvent *)theEvent
68 | {
69 | self.mouseIn = NO;
70 | [self setNeedsDisplay: YES];
71 | [super mouseExited: theEvent];
72 | }
73 |
74 | - (void)updateTrackingAreas
75 | {
76 | if(self.trackingArea != nil) {
77 | [self removeTrackingArea: self.trackingArea];
78 | }
79 |
80 | int opts = (NSTrackingMouseEnteredAndExited | NSTrackingActiveAlways);
81 | self.trackingArea = [ [NSTrackingArea alloc] initWithRect:[self bounds]
82 | options:opts
83 | owner:self
84 | userInfo:nil];
85 | [self addTrackingArea: self.trackingArea];
86 | }
87 |
88 | - (void)setText:(NSString *)text
89 | {
90 | _text = text;
91 | [self setNeedsDisplay: YES];
92 | }
93 |
94 | - (void)colorChanged:(NSNotification *)n
95 | {
96 | NSData *data = [[NSUserDefaults standardUserDefaults] objectForKey: @"lyricColor"];
97 | if (data) {
98 | self.color = (NSColor *)[NSUnarchiver unarchiveObjectWithData: data];
99 | [self setNeedsDisplay: YES];
100 | }
101 | }
102 |
103 | - (void)fontChanged:(NSNotification *)n
104 | {
105 | NSInteger fontSize = [[[NSUserDefaults standardUserDefaults] objectForKey: @"lyricFont"] integerValue];
106 | self.font = [NSFont boldSystemFontOfSize: fontSize];
107 | [self setNeedsDisplay: YES];
108 | }
109 |
110 | #define LeftMargin 50
111 | #define TopMargin 10
112 |
113 | - (void)drawRect:(NSRect)dirtyRect
114 | {
115 | if (self.mouseIn) {
116 |
117 | CGContextRef ctx = [[NSGraphicsContext currentContext] graphicsPort];
118 |
119 | CGPathRef path = createRoundRectPathInRect(self.bounds, 5);
120 | CGContextSaveGState(ctx);
121 | CGContextSetRGBFillColor(ctx, 0, 0, 0, .6);
122 | CGContextAddPath(ctx, path);
123 | CGContextFillPath(ctx);
124 | CGPathRelease(path);
125 | CGContextRestoreGState(ctx);
126 | }
127 | [_text drawInRect: NSMakeRect(LeftMargin, TopMargin, NSWidth(self.bounds) - 2 * LeftMargin, NSHeight(self.bounds) - 2 * TopMargin) withAttributes: @{NSFontAttributeName : self.font, NSForegroundColorAttributeName : self.color}];
128 | }
129 |
130 | @end
131 |
132 | @implementation LyricDisplayWindow
133 |
134 | - (instancetype)initWithContentRect:(NSRect)contentRect styleMask:(NSUInteger)aStyle backing:(NSBackingStoreType)bufferingType defer:(BOOL)flag
135 | {
136 | if (self = [super initWithContentRect: contentRect styleMask: NSBorderlessWindowMask |NSNonactivatingPanelMask backing: NSBackingStoreBuffered defer: YES]) {
137 | _innerView = [[InnerView alloc] initWithFrame: contentRect];
138 | [self setContentView: _innerView];
139 | [self setLevel: NSStatusWindowLevel];
140 | [self setBackgroundColor: [NSColor clearColor]];
141 |
142 | [self setOpaque: NO];
143 | [self makeFirstResponder: _innerView];
144 |
145 | [[NSNotificationCenter defaultCenter] addObserver: self selector: @selector(fontChanged:) name: kNotification_FontChanged object: nil];
146 | }
147 | return self;
148 | }
149 |
150 | - (void)dealloc
151 | {
152 | [[NSNotificationCenter defaultCenter] removeObserver: self];
153 | }
154 |
155 | - (void)setLyric:(NSString *)lyric;
156 | {
157 | _lyric = lyric;
158 | NSRect frame = [self rectOfText: lyric font: _innerView.font];
159 | _innerView.frame = frame;
160 | [_innerView setText: lyric];
161 | }
162 |
163 | - (NSRect)rectOfText:(NSString *)text font:(NSFont *)font
164 | {
165 | NSSize size = [text sizeWithAttributes: @{NSFontAttributeName : font}];
166 | size.width += 2 * LeftMargin;
167 | size.height += 2 * TopMargin;
168 | NSRect rect = NSMakeRect((NSWidth(self.frame) - size.width) * .5, (NSHeight(self.frame) - size.height) * .5, size.width, size.height);
169 | return rect;
170 | }
171 |
172 | - (void)fontChanged:(NSNotification *)n
173 | {
174 | [self setLyric: _innerView.text];
175 | }
176 |
177 | #pragma mark MouseEvent
178 | NSPoint mouseDownInitPoint;
179 | - (void)mouseDown:(NSEvent *)theEvent
180 | {
181 | NSRect windowFrame = [self frame];
182 | mouseDownInitPoint = [self convertBaseToScreen: [theEvent locationInWindow]];
183 | mouseDownInitPoint.x -= windowFrame.origin.x;
184 | mouseDownInitPoint.y -= windowFrame.origin.y;
185 |
186 | [super mouseDown: theEvent];
187 | }
188 |
189 | - (void)mouseDragged:(NSEvent *)theEvent
190 | {
191 | NSPoint currentPonit = [self convertBaseToScreen: [self mouseLocationOutsideOfEventStream]];
192 | NSPoint newPonit;
193 | newPonit.x = currentPonit.x - mouseDownInitPoint.x;
194 | newPonit.y = currentPonit.y - mouseDownInitPoint.y;
195 | [self setFrameOrigin: newPonit];
196 |
197 | [super mouseDragged: theEvent];
198 | }
199 | @end
200 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIDataDecompressor.m:
--------------------------------------------------------------------------------
1 | //
2 | // ASIDataDecompressor.m
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 17/08/2010.
6 | // Copyright 2010 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import "ASIDataDecompressor.h"
10 | #import "ASIHTTPRequest.h"
11 |
12 | #define DATA_CHUNK_SIZE 262144 // Deal with gzipped data in 256KB chunks
13 |
14 | @interface ASIDataDecompressor ()
15 | + (NSError *)inflateErrorWithCode:(int)code;
16 | @end;
17 |
18 | @implementation ASIDataDecompressor
19 |
20 | + (id)decompressor
21 | {
22 | ASIDataDecompressor *decompressor = [[[self alloc] init] autorelease];
23 | [decompressor setupStream];
24 | return decompressor;
25 | }
26 |
27 | - (void)dealloc
28 | {
29 | if (streamReady) {
30 | [self closeStream];
31 | }
32 | [super dealloc];
33 | }
34 |
35 | - (NSError *)setupStream
36 | {
37 | if (streamReady) {
38 | return nil;
39 | }
40 | // Setup the inflate stream
41 | zStream.zalloc = Z_NULL;
42 | zStream.zfree = Z_NULL;
43 | zStream.opaque = Z_NULL;
44 | zStream.avail_in = 0;
45 | zStream.next_in = 0;
46 | int status = inflateInit2(&zStream, (15+32));
47 | if (status != Z_OK) {
48 | return [[self class] inflateErrorWithCode:status];
49 | }
50 | streamReady = YES;
51 | return nil;
52 | }
53 |
54 | - (NSError *)closeStream
55 | {
56 | if (!streamReady) {
57 | return nil;
58 | }
59 | // Close the inflate stream
60 | streamReady = NO;
61 | int status = inflateEnd(&zStream);
62 | if (status != Z_OK) {
63 | return [[self class] inflateErrorWithCode:status];
64 | }
65 | return nil;
66 | }
67 |
68 | - (NSData *)uncompressBytes:(Bytef *)bytes length:(NSUInteger)length error:(NSError **)err
69 | {
70 | if (length == 0) return nil;
71 |
72 | NSUInteger halfLength = length/2;
73 | NSMutableData *outputData = [NSMutableData dataWithLength:length+halfLength];
74 |
75 | int status;
76 |
77 | zStream.next_in = bytes;
78 | zStream.avail_in = (unsigned int)length;
79 | zStream.avail_out = 0;
80 |
81 | NSUInteger bytesProcessedAlready = zStream.total_out;
82 | while (zStream.avail_in != 0) {
83 |
84 | if (zStream.total_out-bytesProcessedAlready >= [outputData length]) {
85 | [outputData increaseLengthBy:halfLength];
86 | }
87 |
88 | zStream.next_out = (Bytef*)[outputData mutableBytes] + zStream.total_out-bytesProcessedAlready;
89 | zStream.avail_out = (unsigned int)([outputData length] - (zStream.total_out-bytesProcessedAlready));
90 |
91 | status = inflate(&zStream, Z_NO_FLUSH);
92 |
93 | if (status == Z_STREAM_END) {
94 | break;
95 | } else if (status != Z_OK) {
96 | if (err) {
97 | *err = [[self class] inflateErrorWithCode:status];
98 | }
99 | return nil;
100 | }
101 | }
102 |
103 | // Set real length
104 | [outputData setLength: zStream.total_out-bytesProcessedAlready];
105 | return outputData;
106 | }
107 |
108 |
109 | + (NSData *)uncompressData:(NSData*)compressedData error:(NSError **)err
110 | {
111 | NSError *theError = nil;
112 | NSData *outputData = [[ASIDataDecompressor decompressor] uncompressBytes:(Bytef *)[compressedData bytes] length:[compressedData length] error:&theError];
113 | if (theError) {
114 | if (err) {
115 | *err = theError;
116 | }
117 | return nil;
118 | }
119 | return outputData;
120 | }
121 |
122 | + (BOOL)uncompressDataFromFile:(NSString *)sourcePath toFile:(NSString *)destinationPath error:(NSError **)err
123 | {
124 | NSFileManager *fileManager = [[[NSFileManager alloc] init] autorelease];
125 |
126 | // Create an empty file at the destination path
127 | if (![fileManager createFileAtPath:destinationPath contents:[NSData data] attributes:nil]) {
128 | if (err) {
129 | *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of %@ failed because we were to create a file at %@",sourcePath,destinationPath],NSLocalizedDescriptionKey,nil]];
130 | }
131 | return NO;
132 | }
133 |
134 | // Ensure the source file exists
135 | if (![fileManager fileExistsAtPath:sourcePath]) {
136 | if (err) {
137 | *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of %@ failed the file does not exist",sourcePath],NSLocalizedDescriptionKey,nil]];
138 | }
139 | return NO;
140 | }
141 |
142 | UInt8 inputData[DATA_CHUNK_SIZE];
143 | NSData *outputData;
144 | NSInteger readLength;
145 | NSError *theError = nil;
146 |
147 |
148 | ASIDataDecompressor *decompressor = [ASIDataDecompressor decompressor];
149 |
150 | NSInputStream *inputStream = [NSInputStream inputStreamWithFileAtPath:sourcePath];
151 | [inputStream open];
152 | NSOutputStream *outputStream = [NSOutputStream outputStreamToFileAtPath:destinationPath append:NO];
153 | [outputStream open];
154 |
155 | while ([decompressor streamReady]) {
156 |
157 | // Read some data from the file
158 | readLength = [inputStream read:inputData maxLength:DATA_CHUNK_SIZE];
159 |
160 | // Make sure nothing went wrong
161 | if ([inputStream streamStatus] == NSStreamStatusError) {
162 | if (err) {
163 | *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of %@ failed because we were unable to read from the source data file",sourcePath],NSLocalizedDescriptionKey,[inputStream streamError],NSUnderlyingErrorKey,nil]];
164 | }
165 | [decompressor closeStream];
166 | return NO;
167 | }
168 | // Have we reached the end of the input data?
169 | if (!readLength) {
170 | break;
171 | }
172 |
173 | // Attempt to inflate the chunk of data
174 | outputData = [decompressor uncompressBytes:inputData length:(NSUInteger)readLength error:&theError];
175 | if (theError) {
176 | if (err) {
177 | *err = theError;
178 | }
179 | [decompressor closeStream];
180 | return NO;
181 | }
182 |
183 | // Write the inflated data out to the destination file
184 | [outputStream write:(Bytef*)[outputData bytes] maxLength:[outputData length]];
185 |
186 | // Make sure nothing went wrong
187 | if ([inputStream streamStatus] == NSStreamStatusError) {
188 | if (err) {
189 | *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of %@ failed because we were unable to write to the destination data file at %@",sourcePath,destinationPath],NSLocalizedDescriptionKey,[outputStream streamError],NSUnderlyingErrorKey,nil]];
190 | }
191 | [decompressor closeStream];
192 | return NO;
193 | }
194 |
195 | }
196 |
197 | [inputStream close];
198 | [outputStream close];
199 |
200 | NSError *error = [decompressor closeStream];
201 | if (error) {
202 | if (err) {
203 | *err = error;
204 | }
205 | return NO;
206 | }
207 |
208 | return YES;
209 | }
210 |
211 |
212 | + (NSError *)inflateErrorWithCode:(int)code
213 | {
214 | return [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Decompression of data failed with code %d",code],NSLocalizedDescriptionKey,nil]];
215 | }
216 |
217 | @synthesize streamReady;
218 | @end
219 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/ASIDataCompressor.m:
--------------------------------------------------------------------------------
1 | //
2 | // ASIDataCompressor.m
3 | // Part of ASIHTTPRequest -> http://allseeing-i.com/ASIHTTPRequest
4 | //
5 | // Created by Ben Copsey on 17/08/2010.
6 | // Copyright 2010 All-Seeing Interactive. All rights reserved.
7 | //
8 |
9 | #import "ASIDataCompressor.h"
10 | #import "ASIHTTPRequest.h"
11 |
12 | #define DATA_CHUNK_SIZE 262144 // Deal with gzipped data in 256KB chunks
13 | #define COMPRESSION_AMOUNT Z_DEFAULT_COMPRESSION
14 |
15 | @interface ASIDataCompressor ()
16 | + (NSError *)deflateErrorWithCode:(int)code;
17 | @end
18 |
19 | @implementation ASIDataCompressor
20 |
21 | + (id)compressor
22 | {
23 | ASIDataCompressor *compressor = [[[self alloc] init] autorelease];
24 | [compressor setupStream];
25 | return compressor;
26 | }
27 |
28 | - (void)dealloc
29 | {
30 | if (streamReady) {
31 | [self closeStream];
32 | }
33 | [super dealloc];
34 | }
35 |
36 | - (NSError *)setupStream
37 | {
38 | if (streamReady) {
39 | return nil;
40 | }
41 | // Setup the inflate stream
42 | zStream.zalloc = Z_NULL;
43 | zStream.zfree = Z_NULL;
44 | zStream.opaque = Z_NULL;
45 | zStream.avail_in = 0;
46 | zStream.next_in = 0;
47 | int status = deflateInit2(&zStream, COMPRESSION_AMOUNT, Z_DEFLATED, (15+16), 8, Z_DEFAULT_STRATEGY);
48 | if (status != Z_OK) {
49 | return [[self class] deflateErrorWithCode:status];
50 | }
51 | streamReady = YES;
52 | return nil;
53 | }
54 |
55 | - (NSError *)closeStream
56 | {
57 | if (!streamReady) {
58 | return nil;
59 | }
60 | // Close the deflate stream
61 | streamReady = NO;
62 | int status = deflateEnd(&zStream);
63 | if (status != Z_OK) {
64 | return [[self class] deflateErrorWithCode:status];
65 | }
66 | return nil;
67 | }
68 |
69 | - (NSData *)compressBytes:(Bytef *)bytes length:(NSUInteger)length error:(NSError **)err shouldFinish:(BOOL)shouldFinish
70 | {
71 | if (length == 0) return nil;
72 |
73 | NSUInteger halfLength = length/2;
74 |
75 | // We'll take a guess that the compressed data will fit in half the size of the original (ie the max to compress at once is half DATA_CHUNK_SIZE), if not, we'll increase it below
76 | NSMutableData *outputData = [NSMutableData dataWithLength:length/2];
77 |
78 | int status;
79 |
80 | zStream.next_in = bytes;
81 | zStream.avail_in = (unsigned int)length;
82 | zStream.avail_out = 0;
83 |
84 | NSUInteger bytesProcessedAlready = zStream.total_out;
85 | while (zStream.avail_out == 0) {
86 |
87 | if (zStream.total_out-bytesProcessedAlready >= [outputData length]) {
88 | [outputData increaseLengthBy:halfLength];
89 | }
90 |
91 | zStream.next_out = (Bytef*)[outputData mutableBytes] + zStream.total_out-bytesProcessedAlready;
92 | zStream.avail_out = (unsigned int)([outputData length] - (zStream.total_out-bytesProcessedAlready));
93 | status = deflate(&zStream, shouldFinish ? Z_FINISH : Z_NO_FLUSH);
94 |
95 | if (status == Z_STREAM_END) {
96 | break;
97 | } else if (status != Z_OK) {
98 | if (err) {
99 | *err = [[self class] deflateErrorWithCode:status];
100 | }
101 | return NO;
102 | }
103 | }
104 |
105 | // Set real length
106 | [outputData setLength: zStream.total_out-bytesProcessedAlready];
107 | return outputData;
108 | }
109 |
110 |
111 | + (NSData *)compressData:(NSData*)uncompressedData error:(NSError **)err
112 | {
113 | NSError *theError = nil;
114 | NSData *outputData = [[ASIDataCompressor compressor] compressBytes:(Bytef *)[uncompressedData bytes] length:[uncompressedData length] error:&theError shouldFinish:YES];
115 | if (theError) {
116 | if (err) {
117 | *err = theError;
118 | }
119 | return nil;
120 | }
121 | return outputData;
122 | }
123 |
124 |
125 |
126 | + (BOOL)compressDataFromFile:(NSString *)sourcePath toFile:(NSString *)destinationPath error:(NSError **)err
127 | {
128 | NSFileManager *fileManager = [[[NSFileManager alloc] init] autorelease];
129 |
130 | // Create an empty file at the destination path
131 | if (![fileManager createFileAtPath:destinationPath contents:[NSData data] attributes:nil]) {
132 | if (err) {
133 | *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of %@ failed because we were to create a file at %@",sourcePath,destinationPath],NSLocalizedDescriptionKey,nil]];
134 | }
135 | return NO;
136 | }
137 |
138 | // Ensure the source file exists
139 | if (![fileManager fileExistsAtPath:sourcePath]) {
140 | if (err) {
141 | *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of %@ failed the file does not exist",sourcePath],NSLocalizedDescriptionKey,nil]];
142 | }
143 | return NO;
144 | }
145 |
146 | UInt8 inputData[DATA_CHUNK_SIZE];
147 | NSData *outputData;
148 | NSInteger readLength;
149 | NSError *theError = nil;
150 |
151 | ASIDataCompressor *compressor = [ASIDataCompressor compressor];
152 |
153 | NSInputStream *inputStream = [NSInputStream inputStreamWithFileAtPath:sourcePath];
154 | [inputStream open];
155 | NSOutputStream *outputStream = [NSOutputStream outputStreamToFileAtPath:destinationPath append:NO];
156 | [outputStream open];
157 |
158 | while ([compressor streamReady]) {
159 |
160 | // Read some data from the file
161 | readLength = [inputStream read:inputData maxLength:DATA_CHUNK_SIZE];
162 |
163 | // Make sure nothing went wrong
164 | if ([inputStream streamStatus] == NSStreamStatusError) {
165 | if (err) {
166 | *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of %@ failed because we were unable to read from the source data file",sourcePath],NSLocalizedDescriptionKey,[inputStream streamError],NSUnderlyingErrorKey,nil]];
167 | }
168 | [compressor closeStream];
169 | return NO;
170 | }
171 | // Have we reached the end of the input data?
172 | if (!readLength) {
173 | break;
174 | }
175 |
176 | // Attempt to deflate the chunk of data
177 | outputData = [compressor compressBytes:inputData length:(NSUInteger)readLength error:&theError shouldFinish:readLength < DATA_CHUNK_SIZE];
178 | if (theError) {
179 | if (err) {
180 | *err = theError;
181 | }
182 | [compressor closeStream];
183 | return NO;
184 | }
185 |
186 | // Write the deflated data out to the destination file
187 | [outputStream write:(const uint8_t *)[outputData bytes] maxLength:[outputData length]];
188 |
189 | // Make sure nothing went wrong
190 | if ([inputStream streamStatus] == NSStreamStatusError) {
191 | if (err) {
192 | *err = [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of %@ failed because we were unable to write to the destination data file at %@",sourcePath,destinationPath],NSLocalizedDescriptionKey,[outputStream streamError],NSUnderlyingErrorKey,nil]];
193 | }
194 | [compressor closeStream];
195 | return NO;
196 | }
197 |
198 | }
199 | [inputStream close];
200 | [outputStream close];
201 |
202 | NSError *error = [compressor closeStream];
203 | if (error) {
204 | if (err) {
205 | *err = error;
206 | }
207 | return NO;
208 | }
209 |
210 | return YES;
211 | }
212 |
213 | + (NSError *)deflateErrorWithCode:(int)code
214 | {
215 | return [NSError errorWithDomain:NetworkRequestErrorDomain code:ASICompressionError userInfo:[NSDictionary dictionaryWithObjectsAndKeys:[NSString stringWithFormat:@"Compression of data failed with code %d",code],NSLocalizedDescriptionKey,nil]];
216 | }
217 |
218 | @synthesize streamReady;
219 | @end
220 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/Reachability.h:
--------------------------------------------------------------------------------
1 | /*
2 |
3 | File: Reachability.h
4 | Abstract: Basic demonstration of how to use the SystemConfiguration Reachablity APIs.
5 |
6 | Version: 2.0.4ddg
7 | */
8 |
9 | /*
10 | Significant additions made by Andrew W. Donoho, August 11, 2009.
11 | This is a derived work of Apple's Reachability v2.0 class.
12 |
13 | The below license is the new BSD license with the OSI recommended personalizations.
14 |
15 |
16 | Extensions Copyright (C) 2009 Donoho Design Group, LLC. All Rights Reserved.
17 |
18 | Redistribution and use in source and binary forms, with or without
19 | modification, are permitted provided that the following conditions are
20 | met:
21 |
22 | * Redistributions of source code must retain the above copyright notice,
23 | this list of conditions and the following disclaimer.
24 |
25 | * Redistributions in binary form must reproduce the above copyright
26 | notice, this list of conditions and the following disclaimer in the
27 | documentation and/or other materials provided with the distribution.
28 |
29 | * Neither the name of Andrew W. Donoho nor Donoho Design Group, L.L.C.
30 | may be used to endorse or promote products derived from this software
31 | without specific prior written permission.
32 |
33 | THIS SOFTWARE IS PROVIDED BY DONOHO DESIGN GROUP, L.L.C. "AS IS" AND ANY
34 | EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
35 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
36 | PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
37 | CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
38 | EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
39 | PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
40 | PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
41 | LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
42 | NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
43 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
44 |
45 | */
46 |
47 |
48 | /*
49 |
50 | Apple's Original License on Reachability v2.0
51 |
52 | Disclaimer: IMPORTANT: This Apple software is supplied to you by Apple Inc.
53 | ("Apple") in consideration of your agreement to the following terms, and your
54 | use, installation, modification or redistribution of this Apple software
55 | constitutes acceptance of these terms. If you do not agree with these terms,
56 | please do not use, install, modify or redistribute this Apple software.
57 |
58 | In consideration of your agreement to abide by the following terms, and subject
59 | to these terms, Apple grants you a personal, non-exclusive license, under
60 | Apple's copyrights in this original Apple software (the "Apple Software"), to
61 | use, reproduce, modify and redistribute the Apple Software, with or without
62 | modifications, in source and/or binary forms; provided that if you redistribute
63 | the Apple Software in its entirety and without modifications, you must retain
64 | this notice and the following text and disclaimers in all such redistributions
65 | of the Apple Software.
66 |
67 | Neither the name, trademarks, service marks or logos of Apple Inc. may be used
68 | to endorse or promote products derived from the Apple Software without specific
69 | prior written permission from Apple. Except as expressly stated in this notice,
70 | no other rights or licenses, express or implied, are granted by Apple herein,
71 | including but not limited to any patent rights that may be infringed by your
72 | derivative works or by other works in which the Apple Software may be
73 | incorporated.
74 |
75 | The Apple Software is provided by Apple on an "AS IS" basis. APPLE MAKES NO
76 | WARRANTIES, EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED
77 | WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS FOR A PARTICULAR
78 | PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS USE AND OPERATION ALONE OR IN
79 | COMBINATION WITH YOUR PRODUCTS.
80 |
81 | IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL OR
82 | CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
83 | GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
84 | ARISING IN ANY WAY OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR
85 | DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF
86 | CONTRACT, TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF
87 | APPLE HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
88 |
89 | Copyright (C) 2009 Apple Inc. All Rights Reserved.
90 |
91 | */
92 |
93 |
94 | /*
95 | DDG extensions include:
96 | Each reachability object now has a copy of the key used to store it in a
97 | dictionary. This allows each observer to quickly determine if the event is
98 | important to them.
99 |
100 | -currentReachabilityStatus also has a significantly different decision criteria than
101 | Apple's code.
102 |
103 | A multiple convenience test methods have been added.
104 | */
105 |
106 | #import
107 | #import
108 | #import
109 |
110 | #define USE_DDG_EXTENSIONS 1 // Use DDG's Extensions to test network criteria.
111 | // Since NSAssert and NSCAssert are used in this code,
112 | // I recommend you set NS_BLOCK_ASSERTIONS=1 in the release versions of your projects.
113 |
114 | enum {
115 |
116 | // DDG NetworkStatus Constant Names.
117 | kNotReachable = 0, // Apple's code depends upon 'NotReachable' being the same value as 'NO'.
118 | kReachableViaWWAN, // Switched order from Apple's enum. WWAN is active before WiFi.
119 | kReachableViaWiFi
120 |
121 | };
122 | typedef uint32_t NetworkStatus;
123 |
124 | enum {
125 |
126 | // Apple NetworkStatus Constant Names.
127 | NotReachable = kNotReachable,
128 | ReachableViaWiFi = kReachableViaWiFi,
129 | ReachableViaWWAN = kReachableViaWWAN
130 |
131 | };
132 |
133 |
134 | extern NSString *const kInternetConnection;
135 | extern NSString *const kLocalWiFiConnection;
136 | extern NSString *const kReachabilityChangedNotification;
137 |
138 | @interface Reachability: NSObject {
139 |
140 | @private
141 | NSString *key_;
142 | SCNetworkReachabilityRef reachabilityRef;
143 |
144 | }
145 |
146 | @property (atomic, copy) NSString *key; // Atomic because network operations are asynchronous.
147 |
148 | // Designated Initializer.
149 | - (Reachability *) initWithReachabilityRef: (SCNetworkReachabilityRef) ref;
150 |
151 | // Use to check the reachability of a particular host name.
152 | + (Reachability *) reachabilityWithHostName: (NSString*) hostName;
153 |
154 | // Use to check the reachability of a particular IP address.
155 | + (Reachability *) reachabilityWithAddress: (const struct sockaddr_in*) hostAddress;
156 |
157 | // Use to check whether the default route is available.
158 | // Should be used to, at minimum, establish network connectivity.
159 | + (Reachability *) reachabilityForInternetConnection;
160 |
161 | // Use to check whether a local wifi connection is available.
162 | + (Reachability *) reachabilityForLocalWiFi;
163 |
164 | //Start listening for reachability notifications on the current run loop.
165 | - (BOOL) startNotifier;
166 | - (void) stopNotifier;
167 |
168 | // Comparison routines to enable choosing actions in a notification.
169 | - (BOOL) isEqual: (Reachability *) r;
170 |
171 | // These are the status tests.
172 | - (NetworkStatus) currentReachabilityStatus;
173 |
174 | // The main direct test of reachability.
175 | - (BOOL) isReachable;
176 |
177 | // WWAN may be available, but not active until a connection has been established.
178 | // WiFi may require a connection for VPN on Demand.
179 | - (BOOL) isConnectionRequired; // Identical DDG variant.
180 | - (BOOL) connectionRequired; // Apple's routine.
181 |
182 | // Dynamic, on demand connection?
183 | - (BOOL) isConnectionOnDemand;
184 |
185 | // Is user intervention required?
186 | - (BOOL) isInterventionRequired;
187 |
188 | // Routines for specific connection testing by your app.
189 | - (BOOL) isReachableViaWWAN;
190 | - (BOOL) isReachableViaWiFi;
191 |
192 | - (SCNetworkReachabilityFlags) reachabilityFlags;
193 |
194 | @end
195 |
--------------------------------------------------------------------------------
/iTunesLyrics/AppDelegate.m:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.m
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/16/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import "AppDelegate.h"
10 | #import "ASIHTTPRequest.h"
11 | #import "iTunes.h"
12 | #import "iTunesLyricHelper.h"
13 | #import "Marco.h"
14 | #import "StatusBarView.h"
15 | #import "AppDelegate+Preference.h"
16 |
17 |
18 | @interface AppDelegate ()
19 |
20 | @property (weak) IBOutlet NSWindow *window;
21 | @property (nonatomic, strong) StatusBarView *barView;
22 | @property (nonatomic, strong) iTunesApplication *itunes;
23 | @property (nonatomic, strong) NSTimer *timer;
24 | @property (nonatomic, strong) NSMutableDictionary *lyricDict;
25 | @end
26 |
27 | @implementation AppDelegate
28 |
29 | - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
30 | // Insert code here to initialize your application
31 |
32 | [self createLyricWindow];
33 | [self registerNotification];
34 |
35 | // init status bar icon
36 | self.barView = [[StatusBarView alloc] initWithFrame: NSMakeRect(0, 0, 24, 18)];
37 |
38 | // set preference window
39 | self.prefWindow.appearance = [NSAppearance appearanceNamed: NSAppearanceNameVibrantDark];
40 |
41 | [self.updater checkForUpdatesInBackground];
42 |
43 | // set itunes instance
44 | NSArray *apps = [[NSWorkspace sharedWorkspace] runningApplications];
45 | apps = [apps objectsAtIndexes:[apps indexesOfObjectsPassingTest:^BOOL(NSRunningApplication* obj, NSUInteger idx, BOOL *stop) {
46 | if ([obj.bundleIdentifier isEqualToString: @"com.apple.iTunes"]) {
47 | *stop = YES;
48 | return YES;
49 | }
50 | return NO;
51 | }]];
52 |
53 | if (apps.count == 1)
54 | self.itunes = [SBApplication applicationWithBundleIdentifier: @"com.apple.iTunes"];
55 |
56 | // init itunes playing state
57 | if ([self.itunes playerState] == iTunesEPlSPlaying) {
58 | self.timer = [NSTimer scheduledTimerWithTimeInterval: .1 target: self selector: @selector(fetchProgress:) userInfo: nil repeats: YES];
59 | self.song = [self currentPlayingSong];
60 | if (self.song) {
61 | [self.lyricWindow setLyric: [NSString stringWithFormat: @"%@ - %@", self.song.name, self.song.artist]];
62 | [[iTunesLyricHelper shareHelper] smartFetchLyricWithSong: self.song completeBlock:^(Song *song) {
63 | [self iTunesLyricFetchFinished: song];
64 | }];
65 | } else
66 | [self.lyricWindow setLyric: @"没有检测到歌曲信息"];
67 |
68 |
69 | }
70 | }
71 |
72 | - (void)createLyricWindow
73 | {
74 | // create lyric window
75 | NSScreen *screen = [NSScreen mainScreen];
76 | self.lyricWindow = [[LyricDisplayWindow alloc] initWithContentRect: NSMakeRect(100, 100, CGRectGetWidth(screen.frame) - 2 * 100, 80) styleMask: NSBorderlessWindowMask backing: NSBackingStoreBuffered defer: NO];
77 | [self.lyricWindow setLyric: @""];
78 | [self.lyricWindow makeKeyAndOrderFront: nil];
79 | }
80 |
81 | - (void)registerNotification
82 | {
83 | // set notificaiton
84 | NSDistributedNotificationCenter *dnc = [NSDistributedNotificationCenter defaultCenter];
85 | [dnc addObserver:self selector:@selector(updateTrackInfo:) name: @"com.apple.iTunes.playerInfo" object:nil];
86 |
87 | [[NSNotificationCenter defaultCenter] addObserver: self selector: @selector(preference:) name:kNotification_ShowWindow object: nil];
88 | [[NSNotificationCenter defaultCenter] addObserver: self selector: @selector(hideLyricPanel:) name:kNotification_HideLyric object: nil];
89 | }
90 |
91 | #pragma mark - iTunes Song Playing
92 | // get current playing song
93 | - (Song *)currentPlayingSong
94 | {
95 | NSString *songName = [[self.itunes currentTrack] name];
96 | if (songName.length == 0) {
97 | return nil;
98 | }
99 |
100 | Song *song = [[Song alloc] init];
101 | song.artist = [self.itunes currentTrack].artist;
102 | song.album = [self.itunes currentTrack].album;
103 | song.duration = [self.itunes currentTrack].duration;
104 |
105 | NSArray *songNames = [songName componentsSeparatedByString:@"("];
106 | if (songNames.count > 1) {
107 | song.name = songNames[0];
108 | } else
109 | song.name = songName;
110 |
111 | return song;
112 | }
113 |
114 | - (void)updateTrackInfo:(NSNotification *)n
115 | {
116 | NSString *state = [n userInfo][@"Player State"];
117 | if ([state isEqualToString: @"Paused"]) {
118 | [self.timer invalidate];
119 | self.timer = nil;
120 | } else if ([state isEqualToString: @"Playing"]) {
121 | if (self.timer == nil) {
122 | self.timer = [NSTimer scheduledTimerWithTimeInterval: .1 target: self selector: @selector(fetchProgress:) userInfo: nil repeats: YES];
123 | }
124 |
125 | if (![self.song isEqual: [self currentPlayingSong]]) {
126 |
127 | self.song = [self currentPlayingSong];
128 | if (self.song) {
129 | [self.lyricWindow setLyric: [NSString stringWithFormat: @"%@ - %@", self.song.name, self.song.artist]];
130 | } else
131 | [self.lyricWindow setLyric: @"没有检测到歌曲信息"];
132 |
133 | [[iTunesLyricHelper shareHelper] smartFetchLyricWithSong: self.song completeBlock:^(Song *song) {
134 | [self iTunesLyricFetchFinished: song];
135 | }];
136 |
137 | if (![self.lyricWindow isVisible]) {
138 | [self.lyricWindow setLyric: @""];
139 | [self.lyricWindow makeKeyAndOrderFront: nil];
140 | }
141 | }
142 | }
143 | }
144 |
145 | // lyric fetch finished notficaiton
146 | - (void)iTunesLyricFetchFinished:(Song *)song
147 | {
148 | if (song.lyrics) {
149 | self.song.lyrics = song.lyrics;
150 | self.song.lyricId = song.lyricId;
151 |
152 | if (![song.name isEqualToString: self.song.name]) {
153 | self.song.name = song.name;
154 | self.song.artist = song.artist;
155 | [[iTunesLyricHelper shareHelper] saveSongLyricToLocal: self.song];
156 | }
157 | }
158 |
159 | if (song.lyrics) {
160 | [self.lyricWindow setLyric: [NSString stringWithFormat: @"%@ - %@", self.song.name, self.song.artist]];
161 | [self analyzeLyric: song.lyrics];
162 | } else {
163 | [self.lyricDict removeAllObjects];
164 | [self.lyricWindow setLyric: @"没有检测到歌词信息"];
165 | }
166 | }
167 |
168 | - (void)searchLyricWillBegin
169 | {
170 | [self.lyricDict removeAllObjects];
171 | [self.lyricWindow setLyric: @"正在导入中..."];
172 | }
173 |
174 | - (void)searchLyricDidImportLyricToSong:(Song *)song
175 | {
176 | if (song) {
177 | [self iTunesLyricFetchFinished: song];
178 | } else
179 | [self.lyricWindow setLyric: @"导入失败"];
180 |
181 | }
182 |
183 | // song playing timer call back
184 | - (void)fetchProgress:(NSTimer *)timer
185 | {
186 | double playerPosition = [self.itunes playerPosition];
187 | NSString *time = [self secs2String: playerPosition];
188 | NSString *lyricStr = self.lyricDict[time];
189 | if (lyricStr.length) {
190 | [self.lyricWindow setLyric: lyricStr];
191 | }
192 | }
193 |
194 | // util to convert sec to string
195 | - (NSString *)secs2String:(NSInteger)time
196 | {
197 | return [NSString stringWithFormat:@"%.2ld:%.2ld",time / 60,time % 60];
198 | }
199 |
200 | // analy lyric
201 | - (void)analyzeLyric:(NSString *)lyrics
202 | {
203 | if (self.lyricDict == nil) {
204 | self.lyricDict = [NSMutableDictionary dictionary];
205 | }
206 | [self.lyricDict removeAllObjects];
207 |
208 | NSArray *lyricsArray = [lyrics componentsSeparatedByString: @"\n"];
209 | for (NSString *lyric in lyricsArray) {
210 | if (lyric.length == 0) continue;
211 | NSArray *tmpArray = [lyric componentsSeparatedByString: @"]"];
212 | if ([tmpArray.firstObject length] < 1) continue;
213 | NSString *timeStr = [[tmpArray firstObject] substringFromIndex: 1];
214 | NSArray * timeArray = [timeStr componentsSeparatedByString:@"."];
215 | NSString * lyricTimeStr = timeArray.firstObject;
216 | NSString * lyricStr = tmpArray.lastObject;
217 |
218 | if (lyricTimeStr.length && lyricStr.length) {
219 | [self.lyricDict setValue: lyricStr forKey: lyricTimeStr];
220 | }
221 | }
222 | }
223 |
224 |
225 |
226 | - (void)applicationWillTerminate:(NSNotification *)aNotification {
227 | // Insert code here to tear down your application
228 | }
229 |
230 | @end
231 |
--------------------------------------------------------------------------------
/iTunesLyrics/Helper/iTunesLyricHelper.m:
--------------------------------------------------------------------------------
1 | //
2 | // iTunesLyricHelper.m
3 | // iTunesLyrics
4 | //
5 | // Created by pennyli on 10/17/15.
6 | // Copyright (c) 2015 penny.li. All rights reserved.
7 | //
8 |
9 | #import "iTunesLyricHelper.h"
10 | #import "ASIFormDataRequest.h"
11 | #import "JSONKit.h"
12 | #import "Marco.h"
13 |
14 | @implementation iTunesLyricHelper
15 |
16 | + (instancetype)shareHelper;
17 | {
18 | static iTunesLyricHelper *_helper = nil;
19 | static dispatch_once_t onceToken;
20 | dispatch_once(&onceToken, ^{
21 | if (_helper == nil) {
22 | _helper = [[iTunesLyricHelper alloc] init];
23 | }
24 | });
25 |
26 | return _helper;
27 | }
28 |
29 | - (instancetype)init
30 | {
31 | if (self = [super init]) {
32 | _requestsDict = [NSMutableDictionary dictionary];
33 | }
34 | return self;
35 | }
36 |
37 | - (void)smartFetchLyricWithSong:(Song *)song completeBlock:(FetchLyricCompleteBlock)block;
38 | {
39 | if ([self readSongLyricFromLocal: song]) {
40 | block(song);
41 | return;
42 | }
43 | NSString *key = [NSString stringWithFormat: @"fetchLyricWithSong-%@-%ld", song.name, (long)song.duration];
44 | if ([_requestsDict objectForKey: key]) {
45 | return;
46 | }
47 |
48 | __weak ASIFormDataRequest *request = [ASIFormDataRequest requestWithURL: [NSURL URLWithString: FETCH_SONG_ID_URL]];
49 | [request addPostValue: song.name forKey: @"s"];
50 | [request addPostValue: @(1) forKey: @"type"];
51 | [request addPostValue: @"true" forKey: @"total"];
52 | [request addPostValue: @(100) forKey: @"limit"];
53 | [request addPostValue: @(0) forKey: @"offset"];
54 | [request addPostValue: @"" forKey: @"hlpretag"];
55 | [request addPostValue: @"" forKey: @"hlposttag"];
56 | [request addRequestHeader: @"Cookie" value: ENET_COOKIE];
57 | [request addRequestHeader: @"User-Agent" value: ENET_UA];
58 | request.timeOutSeconds = 5;
59 |
60 | [_requestsDict setValue: request forKey: key];
61 |
62 | __weak iTunesLyricHelper *helper = self;
63 | [request setCompletionBlock:^{
64 |
65 | id obj = request.responseString.objectFromJSONString;
66 | NSMutableArray *referenceSongs = [NSMutableArray array];
67 | NSArray *songsArray = obj[@"result"][@"songs"];
68 | for (NSDictionary *songDict in songsArray) {
69 | Song *song = [[Song alloc] init];
70 | song.name = songDict[@"name"];
71 | song.duration = (NSInteger)([songDict[@"duration"] integerValue] / 1000);
72 | song.album = songDict[@"album"][@"name"];
73 | song.lyricId = [songDict[@"id"] integerValue];
74 | song.score = [songDict[@"score"]integerValue];
75 | NSArray *artists = songDict[@"artists"];
76 | for (NSInteger i = 0; i < artists.count; i++) {
77 | NSString *artistName = artists[i][@"name"];
78 | if ([artistName length]) {
79 | song.artist = artistName;
80 | break;
81 | }
82 | }
83 | [referenceSongs addObject: song];
84 | }
85 |
86 | // 如果歌曲名字和歌手名都一致则认为是同一首歌
87 | for (Song *fetchSong in referenceSongs) {
88 | if ([fetchSong.name isEqualToString: song.name] && [fetchSong.artist isEqualToString: song.artist]) {
89 | song.lyricId = fetchSong.lyricId;
90 | NSString *timeStr = [NSString stringWithFormat:@"%.2ld:%.2ld",song.duration / 60, song.duration % 60];
91 | NSLog(@"%@-%@,找到正确的歌曲信息, 时间一致,id=%ld,duration=%@", song.name, song.artist,(long)song.lyricId, timeStr);
92 | break;
93 | }
94 | }
95 |
96 | if (song.lyricId) {
97 | [helper fetchLyricWithSong: song completeBlock:^(Song *song) {
98 | block(song);
99 | }];
100 | } else {
101 | block(nil);
102 | }
103 | [helper.requestsDict removeObjectForKey: key];
104 | }];
105 |
106 | [request setFailedBlock:^{
107 | [helper.requestsDict removeObjectForKey: key];
108 | }];
109 |
110 | [request startAsynchronous];
111 | }
112 |
113 |
114 |
115 | - (void)fetchLyricListWithName:(NSString *)songName completeBlock:(FetchLyricListCompleteBlock)block
116 | {
117 | NSString *key = [NSString stringWithFormat: @"fetchLyricWithSong-%@", songName];
118 | if ([_requestsDict objectForKey: key]) {
119 | return;
120 | }
121 |
122 | __weak ASIFormDataRequest *request = [ASIFormDataRequest requestWithURL: [NSURL URLWithString: FETCH_SONG_ID_URL]];
123 | [request addPostValue: songName forKey: @"s"];
124 | [request addPostValue: @(1) forKey: @"type"];
125 | [request addPostValue: @"true" forKey: @"total"];
126 | [request addPostValue: @(100) forKey: @"limit"];
127 | [request addPostValue: @(0) forKey: @"offset"];
128 | [request addPostValue: @"" forKey: @"hlpretag"];
129 | [request addPostValue: @"" forKey: @"hlposttag"];
130 | [request addRequestHeader: @"Cookie" value: ENET_COOKIE];
131 | [request addRequestHeader: @"User-Agent" value: ENET_UA];
132 | request.timeOutSeconds = 5;
133 |
134 | [_requestsDict setValue: request forKey: key];
135 |
136 | __weak iTunesLyricHelper *helper = self;
137 | [request setCompletionBlock:^{
138 |
139 | id obj = request.responseString.objectFromJSONString;
140 | NSMutableArray *referenceSongs = [NSMutableArray array];
141 | NSArray *songsArray = obj[@"result"][@"songs"];
142 | for (NSDictionary *songDict in songsArray) {
143 | Song *song = [[Song alloc] init];
144 | song.name = songDict[@"name"];
145 | song.duration = (NSInteger)([songDict[@"duration"] integerValue] / 1000);
146 | song.album = songDict[@"album"][@"name"];
147 | song.lyricId = [songDict[@"id"] integerValue];
148 | song.score = [songDict[@"score"]integerValue];
149 | NSArray *artists = songDict[@"artists"];
150 | for (NSInteger i = 0; i < artists.count; i++) {
151 | NSString *artistName = artists[i][@"name"];
152 | if ([artistName length]) {
153 | song.artist = artistName;
154 | break;
155 | }
156 | }
157 | [referenceSongs addObject: song];
158 | }
159 |
160 | [referenceSongs sortUsingComparator:^NSComparisonResult(Song *song1, Song *song2) {
161 | return song1.score < song2.score;
162 | }];
163 |
164 | if (block) {
165 | block(referenceSongs);
166 | }
167 | [helper.requestsDict removeObjectForKey: key];
168 |
169 | }];
170 |
171 | [request setFailedBlock:^{
172 | if (block) {
173 | block(nil);
174 | }
175 | [helper.requestsDict removeObjectForKey: key];
176 | }];
177 |
178 | [request startAsynchronous];
179 | }
180 |
181 | - (void)fetchLyricWithSong:(Song *)song completeBlock:(FetchLyricCompleteBlock)block
182 | {
183 | NSString *url = [NSString stringWithFormat: @"%@&id=%ld", FETCH_SONG_LYRIC_URL, song.lyricId];
184 | __weak ASIHTTPRequest *request = [ASIHTTPRequest requestWithURL: [NSURL URLWithString: url]];
185 | [request addRequestHeader: @"Cookie" value: ENET_COOKIE];
186 | [request addRequestHeader: @"User-Agent" value: ENET_UA];
187 | NSString *key = [NSString stringWithFormat: @"_fetchLyricWithSong-%@-%ld", song.name, (long)song.duration];
188 | [self.requestsDict setValue: request forKey: key];
189 | __weak iTunesLyricHelper *helper = self;
190 | request.completionBlock = ^(void){
191 | [helper.requestsDict removeObjectForKey: key];
192 | id obj = request.responseString.objectFromJSONString;
193 | if ([obj[@"code"] integerValue] == 200) {
194 | NSString *lyric = obj[@"lrc"][@"lyric"];
195 | if (lyric.length) {
196 | song.lyrics = lyric;
197 | NSLog(@"%@-%@,找到正确的歌词信息", song.name, song.artist);
198 | [self saveSongLyricToLocal: song];
199 | block(song);
200 | } else {
201 | NSLog(@"%@-%@,没有找到正确的歌词信息", song.name, song.artist);
202 | block(nil);
203 | }
204 | } else {
205 | NSLog(@"_fetchLyricWithSong err code %ld, reason: %@", [obj[@"code"] integerValue], obj);
206 | block(nil);
207 | }
208 |
209 | [helper.requestsDict removeObjectForKey: key];
210 |
211 | };
212 | [request setFailedBlock:^{
213 | NSLog(@"fetch lyric with id error");
214 | block(nil);
215 | [helper.requestsDict removeObjectForKey: key];
216 | }];
217 |
218 | [request startAsynchronous];
219 | }
220 |
221 | - (void)saveSongLyricToLocal:(Song *)song
222 | {
223 | NSString *lyricPath = [self lyricCachePath];
224 | NSString *fileName = [NSString stringWithFormat: @"%@-%@.li", song.name, @(song.duration)];
225 | lyricPath = [lyricPath stringByAppendingPathComponent: fileName];
226 | NSMutableDictionary *dict = [NSMutableDictionary dictionary];
227 | [dict setValue: @(song.lyricId) forKey: @"lyricId"];
228 | [dict setValue: song.lyrics forKey: @"lyrics"];
229 |
230 | [dict writeToFile: lyricPath atomically: YES];
231 | }
232 |
233 | - (BOOL)readSongLyricFromLocal:(Song *)song
234 | {
235 | NSString *lyricPath = [self lyricCachePath];
236 | NSString *fileName = [NSString stringWithFormat: @"%@-%@.li", song.name, @(song.duration)];
237 | lyricPath = [lyricPath stringByAppendingPathComponent: fileName];
238 |
239 | NSDictionary *dict = [NSDictionary dictionaryWithContentsOfFile: lyricPath];
240 | if (dict) {
241 | song.lyricId = [dict[@"lyricId"] integerValue];
242 | song.lyrics = dict[@"lyrics"];
243 | return YES;
244 | }
245 | return NO;
246 | }
247 |
248 | - (NSString *)homePath
249 | {
250 | NSString *userInfoPath = [NSSearchPathForDirectoriesInDomains(NSApplicationSupportDirectory, NSUserDomainMask, YES) lastObject];
251 | userInfoPath = [userInfoPath stringByAppendingFormat:@"/iTunesLyrics/"];
252 | if ([[NSFileManager defaultManager] fileExistsAtPath: userInfoPath]) {
253 | return userInfoPath;
254 | } else {
255 | NSError *error = nil;
256 | BOOL success = [[NSFileManager defaultManager] createDirectoryAtPath: userInfoPath withIntermediateDirectories: YES attributes: nil error: &error];
257 | if (!success) {
258 | NSLog(@"home path create error; %@", [error description]);
259 | }
260 | return nil;
261 | }
262 | }
263 |
264 | - (NSString *)lyricCachePath
265 | {
266 | NSString *userHomePath = [self homePath];
267 | NSString *userCachePath = [userHomePath stringByAppendingPathComponent: @"lyrics"];
268 | if (![[NSFileManager defaultManager] fileExistsAtPath: userCachePath]) {
269 | NSError *error = nil;
270 | [[NSFileManager defaultManager] createDirectoryAtPath: userCachePath withIntermediateDirectories: YES attributes: nil error: &error];
271 | if (error) {
272 | NSLog(@"cache folder create failed");
273 | }
274 | return userCachePath;
275 | }
276 | return userCachePath;
277 | }
278 |
279 | @end
280 |
--------------------------------------------------------------------------------
/iTunesLyrics/Vendors/ASIHTTPRequest/JSONKit.h:
--------------------------------------------------------------------------------
1 | //
2 | // JSONKit.h
3 | // http://github.com/johnezang/JSONKit
4 | // Dual licensed under either the terms of the BSD License, or alternatively
5 | // under the terms of the Apache License, Version 2.0, as specified below.
6 | //
7 |
8 | /*
9 | Copyright (c) 2011, John Engelhart
10 |
11 | All rights reserved.
12 |
13 | Redistribution and use in source and binary forms, with or without
14 | modification, are permitted provided that the following conditions are met:
15 |
16 | * Redistributions of source code must retain the above copyright
17 | notice, this list of conditions and the following disclaimer.
18 |
19 | * Redistributions in binary form must reproduce the above copyright
20 | notice, this list of conditions and the following disclaimer in the
21 | documentation and/or other materials provided with the distribution.
22 |
23 | * Neither the name of the Zang Industries nor the names of its
24 | contributors may be used to endorse or promote products derived from
25 | this software without specific prior written permission.
26 |
27 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
28 | "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
29 | LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
30 | A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
31 | OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
32 | SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
33 | TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
34 | PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
35 | LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
36 | NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
37 | SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
38 | */
39 |
40 | /*
41 | Copyright 2011 John Engelhart
42 |
43 | Licensed under the Apache License, Version 2.0 (the "License");
44 | you may not use this file except in compliance with the License.
45 | You may obtain a copy of the License at
46 |
47 | http://www.apache.org/licenses/LICENSE-2.0
48 |
49 | Unless required by applicable law or agreed to in writing, software
50 | distributed under the License is distributed on an "AS IS" BASIS,
51 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
52 | See the License for the specific language governing permissions and
53 | limitations under the License.
54 | */
55 |
56 | #include
57 | #include
58 | #include
59 | #include
60 | #include
61 |
62 | #ifdef __OBJC__
63 | #import
64 | #import
65 | #import
66 | #import
67 | #import
68 | #import
69 | #endif // __OBJC__
70 |
71 | #ifdef __cplusplus
72 | extern "C" {
73 | #endif
74 |
75 |
76 | // For Mac OS X < 10.5.
77 | #ifndef NSINTEGER_DEFINED
78 | #define NSINTEGER_DEFINED
79 | #if defined(__LP64__) || defined(NS_BUILD_32_LIKE_64)
80 | typedef long NSInteger;
81 | typedef unsigned long NSUInteger;
82 | #define NSIntegerMin LONG_MIN
83 | #define NSIntegerMax LONG_MAX
84 | #define NSUIntegerMax ULONG_MAX
85 | #else // defined(__LP64__) || defined(NS_BUILD_32_LIKE_64)
86 | typedef int NSInteger;
87 | typedef unsigned int NSUInteger;
88 | #define NSIntegerMin INT_MIN
89 | #define NSIntegerMax INT_MAX
90 | #define NSUIntegerMax UINT_MAX
91 | #endif // defined(__LP64__) || defined(NS_BUILD_32_LIKE_64)
92 | #endif // NSINTEGER_DEFINED
93 |
94 |
95 | #ifndef _JSONKIT_H_
96 | #define _JSONKIT_H_
97 |
98 | #if defined(__GNUC__) && (__GNUC__ >= 4) && defined(__APPLE_CC__) && (__APPLE_CC__ >= 5465)
99 | #define JK_DEPRECATED_ATTRIBUTE __attribute__((deprecated))
100 | #else
101 | #define JK_DEPRECATED_ATTRIBUTE
102 | #endif
103 |
104 | #define JSONKIT_VERSION_MAJOR 1
105 | #define JSONKIT_VERSION_MINOR 4
106 |
107 | typedef NSUInteger JKFlags;
108 |
109 | /*
110 | JKParseOptionComments : Allow C style // and /_* ... *_/ (without a _, obviously) comments in JSON.
111 | JKParseOptionUnicodeNewlines : Allow Unicode recommended (?:\r\n|[\n\v\f\r\x85\p{Zl}\p{Zp}]) newlines.
112 | JKParseOptionLooseUnicode : Normally the decoder will stop with an error at any malformed Unicode.
113 | This option allows JSON with malformed Unicode to be parsed without reporting an error.
114 | Any malformed Unicode is replaced with \uFFFD, or "REPLACEMENT CHARACTER".
115 | */
116 |
117 | enum {
118 | JKParseOptionNone = 0,
119 | JKParseOptionStrict = 0,
120 | JKParseOptionComments = (1 << 0),
121 | JKParseOptionUnicodeNewlines = (1 << 1),
122 | JKParseOptionLooseUnicode = (1 << 2),
123 | JKParseOptionPermitTextAfterValidJSON = (1 << 3),
124 | JKParseOptionValidFlags = (JKParseOptionComments | JKParseOptionUnicodeNewlines | JKParseOptionLooseUnicode | JKParseOptionPermitTextAfterValidJSON),
125 | };
126 | typedef JKFlags JKParseOptionFlags;
127 |
128 | enum {
129 | JKSerializeOptionNone = 0,
130 | JKSerializeOptionPretty = (1 << 0),
131 | JKSerializeOptionEscapeUnicode = (1 << 1),
132 | JKSerializeOptionEscapeForwardSlashes = (1 << 4),
133 | JKSerializeOptionValidFlags = (JKSerializeOptionPretty | JKSerializeOptionEscapeUnicode | JKSerializeOptionEscapeForwardSlashes),
134 | };
135 | typedef JKFlags JKSerializeOptionFlags;
136 |
137 | #ifdef __OBJC__
138 |
139 | typedef struct JKParseState JKParseState; // Opaque internal, private type.
140 |
141 | // As a general rule of thumb, if you use a method that doesn't accept a JKParseOptionFlags argument, it defaults to JKParseOptionStrict
142 |
143 | @interface JSONDecoder : NSObject {
144 | JKParseState *parseState;
145 | }
146 | + (id)decoder;
147 | + (id)decoderWithParseOptions:(JKParseOptionFlags)parseOptionFlags;
148 | - (id)initWithParseOptions:(JKParseOptionFlags)parseOptionFlags;
149 | - (void)clearCache;
150 |
151 | // The parse... methods were deprecated in v1.4 in favor of the v1.4 objectWith... methods.
152 | - (id)parseUTF8String:(const unsigned char *)string length:(size_t)length JK_DEPRECATED_ATTRIBUTE; // Deprecated in JSONKit v1.4. Use objectWithUTF8String:length: instead.
153 | - (id)parseUTF8String:(const unsigned char *)string length:(size_t)length error:(NSError **)error JK_DEPRECATED_ATTRIBUTE; // Deprecated in JSONKit v1.4. Use objectWithUTF8String:length:error: instead.
154 | // The NSData MUST be UTF8 encoded JSON.
155 | - (id)parseJSONData:(NSData *)jsonData JK_DEPRECATED_ATTRIBUTE; // Deprecated in JSONKit v1.4. Use objectWithData: instead.
156 | - (id)parseJSONData:(NSData *)jsonData error:(NSError **)error JK_DEPRECATED_ATTRIBUTE; // Deprecated in JSONKit v1.4. Use objectWithData:error: instead.
157 |
158 | // Methods that return immutable collection objects.
159 | - (id)objectWithUTF8String:(const unsigned char *)string length:(NSUInteger)length;
160 | - (id)objectWithUTF8String:(const unsigned char *)string length:(NSUInteger)length error:(NSError **)error;
161 | // The NSData MUST be UTF8 encoded JSON.
162 | - (id)objectWithData:(NSData *)jsonData;
163 | - (id)objectWithData:(NSData *)jsonData error:(NSError **)error;
164 |
165 | // Methods that return mutable collection objects.
166 | - (id)mutableObjectWithUTF8String:(const unsigned char *)string length:(NSUInteger)length;
167 | - (id)mutableObjectWithUTF8String:(const unsigned char *)string length:(NSUInteger)length error:(NSError **)error;
168 | // The NSData MUST be UTF8 encoded JSON.
169 | - (id)mutableObjectWithData:(NSData *)jsonData;
170 | - (id)mutableObjectWithData:(NSData *)jsonData error:(NSError **)error;
171 |
172 | @end
173 |
174 | ////////////
175 | #pragma mark Deserializing methods
176 | ////////////
177 |
178 | @interface NSString (JSONKitDeserializing)
179 | - (id)objectFromJSONString;
180 | - (id)objectFromJSONStringWithParseOptions:(JKParseOptionFlags)parseOptionFlags;
181 | - (id)objectFromJSONStringWithParseOptions:(JKParseOptionFlags)parseOptionFlags error:(NSError **)error;
182 | - (id)mutableObjectFromJSONString;
183 | - (id)mutableObjectFromJSONStringWithParseOptions:(JKParseOptionFlags)parseOptionFlags;
184 | - (id)mutableObjectFromJSONStringWithParseOptions:(JKParseOptionFlags)parseOptionFlags error:(NSError **)error;
185 | @end
186 |
187 | @interface NSData (JSONKitDeserializing)
188 | // The NSData MUST be UTF8 encoded JSON.
189 | - (id)objectFromJSONData;
190 | - (id)objectFromJSONDataWithParseOptions:(JKParseOptionFlags)parseOptionFlags;
191 | - (id)objectFromJSONDataWithParseOptions:(JKParseOptionFlags)parseOptionFlags error:(NSError **)error;
192 | - (id)mutableObjectFromJSONData;
193 | - (id)mutableObjectFromJSONDataWithParseOptions:(JKParseOptionFlags)parseOptionFlags;
194 | - (id)mutableObjectFromJSONDataWithParseOptions:(JKParseOptionFlags)parseOptionFlags error:(NSError **)error;
195 | @end
196 |
197 | ////////////
198 | #pragma mark Serializing methods
199 | ////////////
200 |
201 | @interface NSString (JSONKitSerializing)
202 | // Convenience methods for those that need to serialize the receiving NSString (i.e., instead of having to serialize a NSArray with a single NSString, you can "serialize to JSON" just the NSString).
203 | // Normally, a string that is serialized to JSON has quotation marks surrounding it, which you may or may not want when serializing a single string, and can be controlled with includeQuotes:
204 | // includeQuotes:YES `a "test"...` -> `"a \"test\"..."`
205 | // includeQuotes:NO `a "test"...` -> `a \"test\"...`
206 | - (NSData *)JSONData; // Invokes JSONDataWithOptions:JKSerializeOptionNone includeQuotes:YES
207 | - (NSData *)JSONDataWithOptions:(JKSerializeOptionFlags)serializeOptions includeQuotes:(BOOL)includeQuotes error:(NSError **)error;
208 | - (NSString *)JSONString; // Invokes JSONStringWithOptions:JKSerializeOptionNone includeQuotes:YES
209 | - (NSString *)JSONStringWithOptions:(JKSerializeOptionFlags)serializeOptions includeQuotes:(BOOL)includeQuotes error:(NSError **)error;
210 | @end
211 |
212 | @interface NSArray (JSONKitSerializing)
213 | - (NSData *)JSONData;
214 | - (NSData *)JSONDataWithOptions:(JKSerializeOptionFlags)serializeOptions error:(NSError **)error;
215 | - (NSData *)JSONDataWithOptions:(JKSerializeOptionFlags)serializeOptions serializeUnsupportedClassesUsingDelegate:(id)delegate selector:(SEL)selector error:(NSError **)error;
216 | - (NSString *)JSONString;
217 | - (NSString *)JSONStringWithOptions:(JKSerializeOptionFlags)serializeOptions error:(NSError **)error;
218 | - (NSString *)JSONStringWithOptions:(JKSerializeOptionFlags)serializeOptions serializeUnsupportedClassesUsingDelegate:(id)delegate selector:(SEL)selector error:(NSError **)error;
219 | @end
220 |
221 | @interface NSDictionary (JSONKitSerializing)
222 | - (NSData *)JSONData;
223 | - (NSData *)JSONDataWithOptions:(JKSerializeOptionFlags)serializeOptions error:(NSError **)error;
224 | - (NSData *)JSONDataWithOptions:(JKSerializeOptionFlags)serializeOptions serializeUnsupportedClassesUsingDelegate:(id)delegate selector:(SEL)selector error:(NSError **)error;
225 | - (NSString *)JSONString;
226 | - (NSString *)JSONStringWithOptions:(JKSerializeOptionFlags)serializeOptions error:(NSError **)error;
227 | - (NSString *)JSONStringWithOptions:(JKSerializeOptionFlags)serializeOptions serializeUnsupportedClassesUsingDelegate:(id)delegate selector:(SEL)selector error:(NSError **)error;
228 | @end
229 |
230 | #ifdef __BLOCKS__
231 |
232 | @interface NSArray (JSONKitSerializingBlockAdditions)
233 | - (NSData *)JSONDataWithOptions:(JKSerializeOptionFlags)serializeOptions serializeUnsupportedClassesUsingBlock:(id(^)(id object))block error:(NSError **)error;
234 | - (NSString *)JSONStringWithOptions:(JKSerializeOptionFlags)serializeOptions serializeUnsupportedClassesUsingBlock:(id(^)(id object))block error:(NSError **)error;
235 | @end
236 |
237 | @interface NSDictionary (JSONKitSerializingBlockAdditions)
238 | - (NSData *)JSONDataWithOptions:(JKSerializeOptionFlags)serializeOptions serializeUnsupportedClassesUsingBlock:(id(^)(id object))block error:(NSError **)error;
239 | - (NSString *)JSONStringWithOptions:(JKSerializeOptionFlags)serializeOptions serializeUnsupportedClassesUsingBlock:(id(^)(id object))block error:(NSError **)error;
240 | @end
241 |
242 | #endif
243 |
244 |
245 | #endif // __OBJC__
246 |
247 | #endif // _JSONKIT_H_
248 |
249 | #ifdef __cplusplus
250 | } // extern "C"
251 | #endif
252 |
--------------------------------------------------------------------------------