Skip to content

Commit

Permalink
Preferences - Different labels for ARM.
Browse files Browse the repository at this point in the history
  • Loading branch information
macmade committed Sep 20, 2021
1 parent 31d2dfc commit 7dbe258
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 4 deletions.
13 changes: 13 additions & 0 deletions Hot/Classes/PreferencesWindowController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,21 @@ public class PreferencesWindowController: NSWindowController
}
}

@objc private dynamic var colorizeStatusItemTextLabel: String?

public override var windowNibName: NSNib.Name?
{
return "PreferencesWindowController"
}

public override func windowDidLoad()
{
super.windowDidLoad()

#if arch( arm64 )
self.colorizeStatusItemTextLabel = "Colorize the status item text if the thermal pressure is not nominal"
#else
self.colorizeStatusItemTextLabel = "Colorize the status item text if the CPU speed limit is below 60%"
#endif
}
}
4 changes: 2 additions & 2 deletions Hot/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
<key>CFBundlePackageType</key>
<string>$(PRODUCT_BUNDLE_PACKAGE_TYPE)</string>
<key>CFBundleShortVersionString</key>
<string>1.4.0</string>
<string>1.4.1</string>
<key>CFBundleVersion</key>
<string>70</string>
<string>72</string>
<key>LSApplicationCategoryType</key>
<string>public.app-category.utilities</string>
<key>LSMinimumSystemVersion</key>
Expand Down
5 changes: 3 additions & 2 deletions Hot/UI/Base.lproj/PreferencesWindowController.xib
Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,14 @@
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="Rog-WF-H8d">
<rect key="frame" x="18" y="160" width="197" height="18"/>
<buttonCell key="cell" type="check" title="Colorize the status item text" bezelStyle="regularSquare" imagePosition="left" state="on" inset="2" id="YMx-Az-Ken">
<rect key="frame" x="18" y="160" width="59" height="18"/>
<buttonCell key="cell" type="check" title="Label" bezelStyle="regularSquare" imagePosition="left" state="on" inset="2" id="YMx-Az-Ken">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="system"/>
</buttonCell>
<connections>
<binding destination="-2" name="value" keyPath="self.colorizeStatusItemText" id="1ic-wh-hQ8"/>
<binding destination="-2" name="title" keyPath="self.colorizeStatusItemTextLabel" id="04l-Uc-NeH"/>
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="HBx-Rv-VgA">
Expand Down

0 comments on commit 7dbe258

Please sign in to comment.