mirror of
https://github.com/danbee/persephone
synced 2025-03-04 08:39:11 +00:00
Compare commits
3 Commits
caf7f990e0
...
d79fd4f8e6
| Author | SHA1 | Date | |
|---|---|---|---|
| d79fd4f8e6 | |||
| d41faeb71e | |||
| 357cc794bf |
12
CHANGELOG.md
12
CHANGELOG.md
@ -1,5 +1,17 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 0.11.2-alpha - 2019-04-09
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- Fixed image scaling so it retains the original image aspect ratio
|
||||||
|
|
||||||
|
## 0.11.1-alpha - 2019-04-01
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- Tweaked the QoS of the artwork queue for better performance
|
||||||
|
|
||||||
## 0.11.0-alpha - 2019-04-01
|
## 0.11.0-alpha - 2019-04-01
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|||||||
@ -665,6 +665,9 @@
|
|||||||
CreatedOnToolsVersion = 9.4.1;
|
CreatedOnToolsVersion = 9.4.1;
|
||||||
LastSwiftMigration = 1020;
|
LastSwiftMigration = 1020;
|
||||||
SystemCapabilities = {
|
SystemCapabilities = {
|
||||||
|
com.apple.HardenedRuntime = {
|
||||||
|
enabled = 1;
|
||||||
|
};
|
||||||
com.apple.Sandbox = {
|
com.apple.Sandbox = {
|
||||||
enabled = 0;
|
enabled = 0;
|
||||||
};
|
};
|
||||||
@ -980,11 +983,11 @@
|
|||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CODE_SIGN_ENTITLEMENTS = Persephone/Persephone.entitlements;
|
CODE_SIGN_IDENTITY = "3rd Party Mac Developer Application";
|
||||||
CODE_SIGN_IDENTITY = "-";
|
|
||||||
CODE_SIGN_STYLE = Manual;
|
CODE_SIGN_STYLE = Manual;
|
||||||
COMBINE_HIDPI_IMAGES = YES;
|
COMBINE_HIDPI_IMAGES = YES;
|
||||||
DEVELOPMENT_TEAM = BDEE7ZBFZ3;
|
DEVELOPMENT_TEAM = 8E7TQ638ZD;
|
||||||
|
ENABLE_HARDENED_RUNTIME = YES;
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
FRAMEWORK_SEARCH_PATHS = (
|
||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"$(PROJECT_DIR)/Carthage/Build/Mac",
|
"$(PROJECT_DIR)/Carthage/Build/Mac",
|
||||||
@ -1011,11 +1014,11 @@
|
|||||||
isa = XCBuildConfiguration;
|
isa = XCBuildConfiguration;
|
||||||
buildSettings = {
|
buildSettings = {
|
||||||
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
|
||||||
CODE_SIGN_ENTITLEMENTS = Persephone/Persephone.entitlements;
|
CODE_SIGN_IDENTITY = "3rd Party Mac Developer Application";
|
||||||
CODE_SIGN_IDENTITY = "-";
|
|
||||||
CODE_SIGN_STYLE = Manual;
|
CODE_SIGN_STYLE = Manual;
|
||||||
COMBINE_HIDPI_IMAGES = YES;
|
COMBINE_HIDPI_IMAGES = YES;
|
||||||
DEVELOPMENT_TEAM = BDEE7ZBFZ3;
|
DEVELOPMENT_TEAM = 8E7TQ638ZD;
|
||||||
|
ENABLE_HARDENED_RUNTIME = YES;
|
||||||
FRAMEWORK_SEARCH_PATHS = (
|
FRAMEWORK_SEARCH_PATHS = (
|
||||||
"$(inherited)",
|
"$(inherited)",
|
||||||
"$(PROJECT_DIR)/Carthage/Build/Mac",
|
"$(PROJECT_DIR)/Carthage/Build/Mac",
|
||||||
|
|||||||
@ -15,7 +15,17 @@ extension NSImage {
|
|||||||
static let defaultCoverArt = NSImage(named: "blankAlbum")
|
static let defaultCoverArt = NSImage(named: "blankAlbum")
|
||||||
|
|
||||||
func toFitBox(size: NSSize) -> NSImage {
|
func toFitBox(size: NSSize) -> NSImage {
|
||||||
let newImage = NSImage(size: size)
|
var newSize: NSSize = NSSize.zero
|
||||||
|
let aspectRatio = self.size.width / self.size.height
|
||||||
|
let boxAspectRatio = size.width / size.height
|
||||||
|
|
||||||
|
if aspectRatio > boxAspectRatio {
|
||||||
|
newSize = NSSize(width: size.width, height: size.width / aspectRatio)
|
||||||
|
} else {
|
||||||
|
newSize = NSSize(width: size.height * aspectRatio, height: size.height)
|
||||||
|
}
|
||||||
|
|
||||||
|
let newImage = NSImage(size: newSize)
|
||||||
newImage.lockFocus()
|
newImage.lockFocus()
|
||||||
self.draw(in: newImage.alignmentRect)
|
self.draw(in: newImage.alignmentRect)
|
||||||
newImage.unlockFocus()
|
newImage.unlockFocus()
|
||||||
|
|||||||
@ -17,7 +17,7 @@
|
|||||||
<key>CFBundlePackageType</key>
|
<key>CFBundlePackageType</key>
|
||||||
<string>APPL</string>
|
<string>APPL</string>
|
||||||
<key>CFBundleShortVersionString</key>
|
<key>CFBundleShortVersionString</key>
|
||||||
<string>0.11.1-alpha</string>
|
<string>0.11.2-alpha</string>
|
||||||
<key>CFBundleVersion</key>
|
<key>CFBundleVersion</key>
|
||||||
<string>1</string>
|
<string>1</string>
|
||||||
<key>LSApplicationCategoryType</key>
|
<key>LSApplicationCategoryType</key>
|
||||||
|
|||||||
@ -1,8 +1,8 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="14460.31" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
|
<document type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="3.0" toolsVersion="14490.70" targetRuntime="MacOSX.Cocoa" propertyAccessControl="none" useAutolayout="YES" customObjectInstantitationMethod="direct">
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<deployment identifier="macosx"/>
|
<deployment identifier="macosx"/>
|
||||||
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="14460.31"/>
|
<plugIn identifier="com.apple.InterfaceBuilder.CocoaPlugin" version="14490.70"/>
|
||||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
<objects>
|
<objects>
|
||||||
@ -37,7 +37,7 @@
|
|||||||
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
|
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
|
||||||
</textFieldCell>
|
</textFieldCell>
|
||||||
</textField>
|
</textField>
|
||||||
<imageView identifier="albumArtwork" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="Kfb-8f-ean">
|
<imageView identifier="albumArtwork" horizontalHuggingPriority="251" verticalHuggingPriority="251" horizontalCompressionResistancePriority="250" verticalCompressionResistancePriority="250" translatesAutoresizingMaskIntoConstraints="NO" id="Kfb-8f-ean">
|
||||||
<rect key="frame" x="0.0" y="39" width="128" height="128"/>
|
<rect key="frame" x="0.0" y="39" width="128" height="128"/>
|
||||||
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyUpOrDown" image="blankAlbum" id="FsA-JX-BFh"/>
|
<imageCell key="cell" refusesFirstResponder="YES" alignment="left" imageScaling="proportionallyUpOrDown" image="blankAlbum" id="FsA-JX-BFh"/>
|
||||||
</imageView>
|
</imageView>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user