diff --git a/Info.plist b/Info.plist
index bcbd505b..ac805ad8 100644
--- a/Info.plist
+++ b/Info.plist
@@ -2,12 +2,12 @@
+ ATSApplicationFontsPath
+
CFBundleDevelopmentRegion
en
CFBundleExecutable
$(EXECUTABLE_NAME)
- CFBundleIconFile
-
CFBundleIdentifier
$(PRODUCT_BUNDLE_IDENTIFIER)
CFBundleInfoDictionaryVersion
@@ -20,25 +20,23 @@
#VERSION#
CFBundleVersion
#VERSION#
+ FeedbackToken
+ #FEEDBACK_TOKEN#
LSMinimumSystemVersion
$(MACOSX_DEPLOYMENT_TARGET)
+ LSUIElement
+ true
NSHumanReadableCopyright
GPL-3.0 licence
NSPrincipalClass
NSApplication
- LSUIElement
- true
- ATSApplicationFontsPath
-
NSSupportsSuddenTermination
true
- SUFeedURL
- https://raw.githubusercontent.com/lwouis/alt-tab-macos/master/appcast.xml
SUEnableAutomaticChecks
true
+ SUFeedURL
+ https://raw.githubusercontent.com/lwouis/alt-tab-macos/master/appcast.xml
SUPublicEDKey
2e9SQOBoaKElchSa/4QDli/nvYkyuDNfynfzBF6vJK4=
- FeedbackToken
- #FEEDBACK_TOKEN#
diff --git a/alt-tab-macos.xcodeproj/project.pbxproj b/alt-tab-macos.xcodeproj/project.pbxproj
index b5dd10d2..9d41d8b4 100644
--- a/alt-tab-macos.xcodeproj/project.pbxproj
+++ b/alt-tab-macos.xcodeproj/project.pbxproj
@@ -8,6 +8,7 @@
/* Begin PBXBuildFile section */
4807A6C623A9CD190052A53E /* SkyLight.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 4807A6C523A9CD190052A53E /* SkyLight.framework */; };
+ 4858C9B323FBA80200A5BCD9 /* rasterized.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 4858C9B223FBA80200A5BCD9 /* rasterized.xcassets */; };
76D02BB22BFE7C9E0056008D /* Pods_alt_tab_macos.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = C0712B3BEA2B3780398C0999 /* Pods_alt_tab_macos.framework */; };
D04BA004884A273D4D2D3EF1 /* HelperExtensions.swift in Sources */ = {isa = PBXBuildFile; fileRef = D04BAD91161791D42FEC4A60 /* HelperExtensions.swift */; };
D04BA084CD1236EC78D90A01 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = D04BACCBE5F97BE9B6CA645B /* Localizable.strings */; };
@@ -65,6 +66,7 @@
/* Begin PBXFileReference section */
38C426DAE17708EDD4FDADBF /* Pods-alt-tab-macos.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-alt-tab-macos.release.xcconfig"; path = "Target Support Files/Pods-alt-tab-macos/Pods-alt-tab-macos.release.xcconfig"; sourceTree = ""; };
4807A6C523A9CD190052A53E /* SkyLight.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = SkyLight.framework; path = ../../../../System/Library/PrivateFrameworks/SkyLight.framework; sourceTree = ""; };
+ 4858C9B223FBA80200A5BCD9 /* rasterized.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = rasterized.xcassets; sourceTree = ""; };
BF12DEA89785CA78B0FE2706 /* Pods-alt-tab-macos.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-alt-tab-macos.debug.xcconfig"; path = "Target Support Files/Pods-alt-tab-macos/Pods-alt-tab-macos.debug.xcconfig"; sourceTree = ""; };
C0712B3BEA2B3780398C0999 /* Pods_alt_tab_macos.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_alt_tab_macos.framework; sourceTree = BUILT_PRODUCTS_DIR; };
D04BA015A45DE7AFDC9794FE /* Window.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Window.swift; sourceTree = ""; };
@@ -126,7 +128,7 @@
D04BA82F792DF53958D92572 /* AltTab.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = AltTab.app; sourceTree = BUILT_PRODUCTS_DIR; };
D04BA8DB8AA7E5570DAC568A /* Sysctl.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Sysctl.swift; sourceTree = ""; };
D04BA926AF41D226EA1ACBA1 /* CONTRIBUTING.md */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = net.daringfireball.markdown; path = CONTRIBUTING.md; sourceTree = ""; };
- D04BA92541D46EA4F6943A72 /* package-lock.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = "package-lock.json"; sourceTree = ""; };
+ D04BA97D4F5B72B3AB87A4A5 /* app-icon.svg */ = {isa = PBXFileReference; lastKnownFileType = file.svg; path = "app-icon.svg"; sourceTree = ""; };
D04BA9B93823398A542FF7A0 /* Preferences.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = Preferences.swift; sourceTree = ""; };
D04BA9EF65B2E7AF9E3ADCA3 /* 2 windows - 1 line.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = "2 windows - 1 line.jpg"; sourceTree = ""; };
D04BAA34E0CB00DED7C04B4F /* 2-rows.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = "2-rows.jpg"; sourceTree = ""; };
@@ -157,6 +159,7 @@
D04BAD91161791D42FEC4A60 /* HelperExtensions.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = HelperExtensions.swift; sourceTree = ""; };
D04BADB20AB31BF83593E0BE /* greetings.yml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.yaml; path = greetings.yml; sourceTree = ""; };
D04BAE1243C9B4BE3ED1B524 /* 7 windows - 2 lines - extra wide window.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = "7 windows - 2 lines - extra wide window.jpg"; sourceTree = ""; };
+ D04BAE31C445719E8F8C60E1 /* menubar-icon.svg */ = {isa = PBXFileReference; lastKnownFileType = file.svg; path = "menubar-icon.svg"; sourceTree = ""; };
D04BAE757BB2B605234FBF58 /* TabViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = TabViewController.swift; sourceTree = ""; };
D04BAE93A5854C501639C640 /* update_homebrew_cask.sh */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.sh; path = update_homebrew_cask.sh; sourceTree = ""; };
D04BAF076A30A1BAFEDBEA66 /* 5 windows - 2 lines.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = "5 windows - 2 lines.jpg"; sourceTree = ""; };
@@ -405,6 +408,15 @@
path = scripts;
sourceTree = "";
};
+ D04BA7568B7165A7726306A7 /* icons */ = {
+ isa = PBXGroup;
+ children = (
+ 4858C9B223FBA80200A5BCD9 /* rasterized.xcassets */,
+ D04BAAE3B28A88C49177414C /* originals */,
+ );
+ path = icons;
+ sourceTree = "";
+ };
D04BA85F16881B290C4A33CD /* de.lproj */ = {
isa = PBXGroup;
children = (
@@ -420,6 +432,7 @@
D04BA0CDCFF1F0B1A77E3E86 /* SF-Pro-Text-Regular.otf */,
D04BAC2FF99F629CD4ED20FC /* MainMenu.xib */,
D04BAC2B70BC798C57B0B492 /* l10n */,
+ D04BA7568B7165A7726306A7 /* icons */,
);
path = resources;
sourceTree = "";
@@ -455,6 +468,15 @@
path = img;
sourceTree = "";
};
+ D04BAAE3B28A88C49177414C /* originals */ = {
+ isa = PBXGroup;
+ children = (
+ D04BA97D4F5B72B3AB87A4A5 /* app-icon.svg */,
+ D04BAE31C445719E8F8C60E1 /* menubar-icon.svg */,
+ );
+ path = originals;
+ sourceTree = "";
+ };
D04BABCD12CA72B06290C248 /* preferences-window */ = {
isa = PBXGroup;
children = (
@@ -560,6 +582,7 @@
D04BA8D6055F6F2E42C976EA /* InfoPlist.strings in Resources */,
D04BAC3169D54014CBA9ACE5 /* Localizable.strings in Resources */,
D04BA100BD0F47828EB649FF /* InfoPlist.strings in Resources */,
+ 4858C9B323FBA80200A5BCD9 /* rasterized.xcassets in Resources */,
D04BA3C24F4F644EA91DE38C /* Localizable.strings in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
diff --git a/config/base.xcconfig b/config/base.xcconfig
index 2252d987..c1356795 100644
--- a/config/base.xcconfig
+++ b/config/base.xcconfig
@@ -10,3 +10,4 @@ IDEDerivedDataPathOverride = DerivedData
FRAMEWORK_SEARCH_PATHS[config=*] = $(inherited) /System/Library/PrivateFrameworks // for SkyLight.framework
ENABLE_HARDENED_RUNTIME = YES // for notarization
OTHER_CODE_SIGN_FLAGS = --timestamp --deep --options runtime // for notarization
+ASSETCATALOG_COMPILER_APPICON_NAME = app-icon
diff --git a/resources/icons/originals/app-icon.svg b/resources/icons/originals/app-icon.svg
new file mode 100644
index 00000000..07f5076a
--- /dev/null
+++ b/resources/icons/originals/app-icon.svg
@@ -0,0 +1,232 @@
+
diff --git a/resources/icons/originals/menubar-icon.svg b/resources/icons/originals/menubar-icon.svg
new file mode 100644
index 00000000..3e499400
--- /dev/null
+++ b/resources/icons/originals/menubar-icon.svg
@@ -0,0 +1,17 @@
+
diff --git a/resources/icons/rasterized.xcassets/Contents.json b/resources/icons/rasterized.xcassets/Contents.json
new file mode 100644
index 00000000..da4a164c
--- /dev/null
+++ b/resources/icons/rasterized.xcassets/Contents.json
@@ -0,0 +1,6 @@
+{
+ "info" : {
+ "version" : 1,
+ "author" : "xcode"
+ }
+}
\ No newline at end of file
diff --git a/resources/icons/rasterized.xcassets/app-icon.appiconset/Contents.json b/resources/icons/rasterized.xcassets/app-icon.appiconset/Contents.json
new file mode 100644
index 00000000..09056c40
--- /dev/null
+++ b/resources/icons/rasterized.xcassets/app-icon.appiconset/Contents.json
@@ -0,0 +1,59 @@
+{
+ "images" : [
+ {
+ "idiom" : "mac",
+ "size" : "16x16",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "mac",
+ "size" : "16x16",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "mac",
+ "size" : "32x32",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "mac",
+ "size" : "32x32",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "mac",
+ "size" : "128x128",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "mac",
+ "size" : "128x128",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "mac",
+ "size" : "256x256",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "mac",
+ "size" : "256x256",
+ "scale" : "2x"
+ },
+ {
+ "idiom" : "mac",
+ "size" : "512x512",
+ "scale" : "1x"
+ },
+ {
+ "size" : "512x512",
+ "idiom" : "mac",
+ "filename" : "icon_512x512@2x.png",
+ "scale" : "2x"
+ }
+ ],
+ "info" : {
+ "version" : 1,
+ "author" : "xcode"
+ }
+}
\ No newline at end of file
diff --git a/resources/icons/rasterized.xcassets/app-icon.appiconset/icon_512x512@2x.png b/resources/icons/rasterized.xcassets/app-icon.appiconset/icon_512x512@2x.png
new file mode 100644
index 00000000..fbec5b4d
Binary files /dev/null and b/resources/icons/rasterized.xcassets/app-icon.appiconset/icon_512x512@2x.png differ
diff --git a/resources/icons/rasterized.xcassets/menubar-icon.imageset/Contents.json b/resources/icons/rasterized.xcassets/menubar-icon.imageset/Contents.json
new file mode 100644
index 00000000..426059c5
--- /dev/null
+++ b/resources/icons/rasterized.xcassets/menubar-icon.imageset/Contents.json
@@ -0,0 +1,17 @@
+{
+ "images" : [
+ {
+ "idiom" : "mac",
+ "scale" : "1x"
+ },
+ {
+ "idiom" : "mac",
+ "filename" : "icon_16x16@2x.png",
+ "scale" : "2x"
+ }
+ ],
+ "info" : {
+ "version" : 1,
+ "author" : "xcode"
+ }
+}
\ No newline at end of file
diff --git a/resources/icons/rasterized.xcassets/menubar-icon.imageset/icon_16x16@2x.png b/resources/icons/rasterized.xcassets/menubar-icon.imageset/icon_16x16@2x.png
new file mode 100644
index 00000000..4088de40
Binary files /dev/null and b/resources/icons/rasterized.xcassets/menubar-icon.imageset/icon_16x16@2x.png differ
diff --git a/src/ui/Menubar.swift b/src/ui/Menubar.swift
index 27c83307..66bd57fd 100644
--- a/src/ui/Menubar.swift
+++ b/src/ui/Menubar.swift
@@ -3,7 +3,10 @@ import Cocoa
class Menubar {
static func make(_ app: App) -> NSStatusItem {
let item = NSStatusBar.system.statusItem(withLength: NSStatusItem.variableLength)
- item.button!.title = "AltTab"
+ let image = NSImage(named: "menubar-icon")
+ image!.isTemplate = true
+ item.button!.image = image
+ item.button!.imageScaling = .scaleProportionallyUpOrDown
item.menu = NSMenu()
item.menu!.addItem(
withTitle: NSLocalizedString("Show", comment: ""),