-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit cfb8772
Showing
47 changed files
with
3,079 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
.DS_Store |
Large diffs are not rendered by default.
Oops, something went wrong.
7 changes: 7 additions & 0 deletions
7
Space HUD.xcodeproj/project.xcworkspace/contents.xcworkspacedata
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
8 changes: 8 additions & 0 deletions
8
Space HUD.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>IDEDidComputeMac32BitWarning</key> | ||
<true/> | ||
</dict> | ||
</plist> |
50 changes: 50 additions & 0 deletions
50
Space HUD.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
{ | ||
"pins" : [ | ||
{ | ||
"identity" : "alamofire", | ||
"kind" : "remoteSourceControl", | ||
"location" : "https://github.com/Alamofire/Alamofire", | ||
"state" : { | ||
"branch" : "master", | ||
"revision" : "7884a65c6c251088c95eae70acd9adfd08fa7c68" | ||
} | ||
}, | ||
{ | ||
"identity" : "defaults", | ||
"kind" : "remoteSourceControl", | ||
"location" : "https://github.com/sindresorhus/Defaults", | ||
"state" : { | ||
"branch" : "main", | ||
"revision" : "35943225a081e26b6ef5126312198e884512cbb6" | ||
} | ||
}, | ||
{ | ||
"identity" : "keychainaccess", | ||
"kind" : "remoteSourceControl", | ||
"location" : "https://github.com/kishikawakatsumi/KeychainAccess", | ||
"state" : { | ||
"branch" : "master", | ||
"revision" : "6299daec1d74be12164fec090faf9ed14d0da9d6" | ||
} | ||
}, | ||
{ | ||
"identity" : "skeletonui", | ||
"kind" : "remoteSourceControl", | ||
"location" : "https://github.com/CSolanaM/SkeletonUI", | ||
"state" : { | ||
"branch" : "develop", | ||
"revision" : "98225dbb0459477dfeac063e1c7d0750102325d1" | ||
} | ||
}, | ||
{ | ||
"identity" : "swift-snapshot-testing", | ||
"kind" : "remoteSourceControl", | ||
"location" : "https://github.com/pointfreeco/swift-snapshot-testing", | ||
"state" : { | ||
"revision" : "f29e2014f6230cf7d5138fc899da51c7f513d467", | ||
"version" : "1.10.0" | ||
} | ||
} | ||
], | ||
"version" : 2 | ||
} |
Binary file added
BIN
+68.1 KB
...proj/project.xcworkspace/xcuserdata/caseyjones.xcuserdatad/UserInterfaceState.xcuserstate
Binary file not shown.
14 changes: 14 additions & 0 deletions
14
Space HUD.xcodeproj/xcuserdata/caseyjones.xcuserdatad/xcschemes/xcschememanagement.plist
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>SchemeUserState</key> | ||
<dict> | ||
<key>Space HUD.xcscheme_^#shared#^_</key> | ||
<dict> | ||
<key>orderHint</key> | ||
<integer>0</integer> | ||
</dict> | ||
</dict> | ||
</dict> | ||
</plist> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
// | ||
// AppDelegate.swift | ||
// Space HUD | ||
// | ||
// Created by Pavel Makhov on 2022-11-18. | ||
// | ||
|
||
import Cocoa | ||
import SwiftUI | ||
|
||
@main | ||
class AppDelegate: NSObject, NSApplicationDelegate { | ||
|
||
var popover: NSPopover! | ||
var statusBarItem: NSStatusItem! | ||
@ObservedObject var model = Model() | ||
let client = SpaceClient() | ||
var contentView: ContentView? | ||
|
||
func applicationDidFinishLaunching(_ aNotification: Notification) { | ||
|
||
contentView = ContentView(model: self.model) | ||
|
||
let popover = NSPopover() | ||
popover.contentSize = NSSize(width: 600, height: 400) | ||
popover.behavior = .transient | ||
popover.contentViewController = NSHostingController(rootView: contentView) | ||
self.popover = popover | ||
|
||
self.statusBarItem = NSStatusBar.system.statusItem(withLength: CGFloat(NSStatusItem.variableLength)) | ||
|
||
if let button = self.statusBarItem.button { | ||
let logo = NSImage(named: "space-logo") | ||
logo?.size = NSSize(width: 18, height: 18) | ||
button.image = NSImage(named: "space-logo") | ||
button.action = #selector(togglePopover(_:)) | ||
} | ||
|
||
client.getIssueStatuses{ resp in | ||
Constants.issueStatuses = resp | ||
} | ||
|
||
|
||
NSApp.setActivationPolicy(.accessory) | ||
} | ||
|
||
@objc func togglePopover(_ sender: AnyObject?) { | ||
if let button = self.statusBarItem.button { | ||
if self.popover.isShown { | ||
self.popover.performClose(sender) | ||
} else { | ||
self.model.refresh(); | ||
self.popover.show(relativeTo: button.bounds, of: button, preferredEdge: NSRectEdge.minY) | ||
} | ||
} | ||
} | ||
|
||
func applicationWillTerminate(_ aNotification: Notification) { | ||
// Insert code here to tear down your application | ||
} | ||
|
||
func applicationSupportsSecureRestorableState(_ app: NSApplication) -> Bool { | ||
return true | ||
} | ||
|
||
@objc | ||
func quit() { | ||
NSLog("User click Quit") | ||
NSApplication.shared.terminate(self) | ||
} | ||
|
||
} | ||
|
11 changes: 11 additions & 0 deletions
11
Space HUD/Assets.xcassets/AccentColor.colorset/Contents.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"colors" : [ | ||
{ | ||
"idiom" : "universal" | ||
} | ||
], | ||
"info" : { | ||
"author" : "xcode", | ||
"version" : 1 | ||
} | ||
} |
68 changes: 68 additions & 0 deletions
68
Space HUD/Assets.xcassets/AppIcon.appiconset/Contents.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
{ | ||
"images" : [ | ||
{ | ||
"filename" : "spacebar-16.png", | ||
"idiom" : "mac", | ||
"scale" : "1x", | ||
"size" : "16x16" | ||
}, | ||
{ | ||
"filename" : "spacebar-32.png", | ||
"idiom" : "mac", | ||
"scale" : "2x", | ||
"size" : "16x16" | ||
}, | ||
{ | ||
"filename" : "spacebar-33.png", | ||
"idiom" : "mac", | ||
"scale" : "1x", | ||
"size" : "32x32" | ||
}, | ||
{ | ||
"filename" : "spacebar-64.png", | ||
"idiom" : "mac", | ||
"scale" : "2x", | ||
"size" : "32x32" | ||
}, | ||
{ | ||
"filename" : "spacebar-128.png", | ||
"idiom" : "mac", | ||
"scale" : "1x", | ||
"size" : "128x128" | ||
}, | ||
{ | ||
"filename" : "spacebar-256.png", | ||
"idiom" : "mac", | ||
"scale" : "2x", | ||
"size" : "128x128" | ||
}, | ||
{ | ||
"filename" : "spacebar-257.png", | ||
"idiom" : "mac", | ||
"scale" : "1x", | ||
"size" : "256x256" | ||
}, | ||
{ | ||
"filename" : "spacebar-512.png", | ||
"idiom" : "mac", | ||
"scale" : "2x", | ||
"size" : "256x256" | ||
}, | ||
{ | ||
"filename" : "spacebar-513.png", | ||
"idiom" : "mac", | ||
"scale" : "1x", | ||
"size" : "512x512" | ||
}, | ||
{ | ||
"filename" : "spacebar-1024.png", | ||
"idiom" : "mac", | ||
"scale" : "2x", | ||
"size" : "512x512" | ||
} | ||
], | ||
"info" : { | ||
"author" : "xcode", | ||
"version" : 1 | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"info" : { | ||
"author" : "xcode", | ||
"version" : 1 | ||
} | ||
} |
12 changes: 12 additions & 0 deletions
12
Space HUD/Assets.xcassets/space-logo.imageset/Contents.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"images" : [ | ||
{ | ||
"filename" : "space-logo.png", | ||
"idiom" : "universal" | ||
} | ||
], | ||
"info" : { | ||
"author" : "xcode", | ||
"version" : 1 | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 12 additions & 0 deletions
12
Space HUD/Assets.xcassets/space-man.imageset/Contents.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
{ | ||
"images" : [ | ||
{ | ||
"filename" : "Untitled.png", | ||
"idiom" : "universal" | ||
} | ||
], | ||
"info" : { | ||
"author" : "xcode", | ||
"version" : 1 | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.