Skip to content

Commit

Permalink
Updated layout and text
Browse files Browse the repository at this point in the history
  • Loading branch information
superhighfives committed Jan 28, 2023
1 parent da966b9 commit 7782242
Show file tree
Hide file tree
Showing 11 changed files with 35 additions and 26 deletions.
13 changes: 9 additions & 4 deletions Pika/AppDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -143,12 +143,19 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSMenuDelegate {
action: #selector(openAboutWindow(_:)),
keyEquivalent: ""
)

statusBarMenu.addItem(
withTitle: "\(PikaText.textMenuUpdates)...",
action: #selector(checkForUpdates(_:)),
keyEquivalent: ""
)

statusBarMenu.addItem(
withTitle: PikaText.textMenuGitHubIssue,
action: #selector(openGitHubIssue(_:)),
keyEquivalent: ""
)

let preferences = NSMenuItem(
title: PikaText.textMenuPreferences,
action: #selector(openPreferencesWindow(_:)),
Expand Down Expand Up @@ -306,13 +313,11 @@ class AppDelegate: NSObject, NSApplicationDelegate, NSMenuDelegate {
}

@IBAction func openWebsite(_: Any) {
let url = URL(string: PikaConstants.pikaWebsiteURL)!
NSWorkspace.shared.open(url)
NSWorkspace.shared.open(URL(string: PikaConstants.pikaWebsiteURL)!)
}

@IBAction func openGitHubIssue(_: Any) {
let url = URL(string: PikaConstants.gitHubIssueURL)!
NSWorkspace.shared.open(url)
NSWorkspace.shared.open(URL(string: PikaConstants.gitHubIssueURL)!)
}

@IBAction func terminatePika(_: Any) {
Expand Down
4 changes: 2 additions & 2 deletions Pika/Assets/Base.lproj/Main.storyboard
Original file line number Diff line number Diff line change
Expand Up @@ -139,12 +139,12 @@
<modifierMask key="keyEquivalentModifierMask"/>
<menu key="submenu" title="Help" systemMenu="help" id="F2S-fz-NVQ">
<items>
<menuItem title="Pika Website" keyEquivalent="?" id="FKE-Sm-Kum">
<menuItem title="Pika website" keyEquivalent="?" id="FKE-Sm-Kum">
<connections>
<action selector="openWebsite:" target="Voe-Tx-rLC" id="vQG-LA-1ix"/>
</connections>
</menuItem>
<menuItem title="Report Bug or Feedback" id="hxD-2G-mEq">
<menuItem title="Report feedback" id="hxD-2G-mEq">
<modifierMask key="keyEquivalentModifierMask"/>
<connections>
<action selector="openGitHubIssue:" target="Voe-Tx-rLC" id="7Ag-IO-qo8"/>
Expand Down
8 changes: 4 additions & 4 deletions Pika/Assets/de.lproj/Localizable.strings
Original file line number Diff line number Diff line change
Expand Up @@ -127,11 +127,11 @@
/* Preferences */
"menu.preferences" = "Einstellungen";

/* Pika Website */
"menu.website" = "Pika-Website";
/* Pika website */
"menu.website" = "Pika-website";

/* Report Bug or Feedback */
"menu.issue" = "Fehler oder Feedback melden";
/* Report feedback */
"menu.issue" = "Feedback melden";

/* Quit */
"menu.quit" = "Beenden";
Expand Down
8 changes: 4 additions & 4 deletions Pika/Assets/de.lproj/Main.strings
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
/* Class = "NSMenu"; title = "Help"; ObjectID = "F2S-fz-NVQ"; */
"F2S-fz-NVQ.title" = "Hilfe";

/* Class = "NSMenuItem"; title = "Pika Website"; ObjectID = "FKE-Sm-Kum"; */
"FKE-Sm-Kum.title" = "Website";
/* Class = "NSMenuItem"; title = "Pika website"; ObjectID = "FKE-Sm-Kum"; */
"FKE-Sm-Kum.title" = "Pika website";

/* Class = "NSMenu"; title = "Eyedroppers"; ObjectID = "KHB-9b-hO2"; */
"KHB-9b-hO2.title" = "Auswahl";
Expand Down Expand Up @@ -83,5 +83,5 @@
/* Class = "NSMenuItem"; title = "Copy foreground"; ObjectID = "x3v-GG-iWU"; */
"x3v-GG-iWU.title" = "Vordergrund kopieren";

/* Class = "NSMenuItem"; title = "Report Bug or Feedback"; ObjectID = "hxD-2G-mEq.title"; */
"hxD-2G-mEq.title" = "Fehler oder Feedback melden";
/* Class = "NSMenuItem"; title = "Report feedback"; ObjectID = "hxD-2G-mEq.title"; */
"hxD-2G-mEq.title" = "Feedback melden";
Binary file modified Pika/Assets/en.lproj/Localizable.strings
Binary file not shown.
8 changes: 4 additions & 4 deletions Pika/Assets/en.lproj/Main.strings
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
/* Class = "NSMenu"; title = "Help"; ObjectID = "F2S-fz-NVQ"; */
"F2S-fz-NVQ.title" = "Help";

/* Class = "NSMenuItem"; title = "Pika Website"; ObjectID = "FKE-Sm-Kum"; */
"FKE-Sm-Kum.title" = "Pika Website";
/* Class = "NSMenuItem"; title = "Pika website"; ObjectID = "FKE-Sm-Kum"; */
"FKE-Sm-Kum.title" = "Pika website";

/* Class = "NSMenu"; title = "Eyedroppers"; ObjectID = "KHB-9b-hO2"; */
"KHB-9b-hO2.title" = "Eyedroppers";
Expand Down Expand Up @@ -83,5 +83,5 @@
/* Class = "NSMenuItem"; title = "Copy foreground"; ObjectID = "x3v-GG-iWU"; */
"x3v-GG-iWU.title" = "Copy foreground";

/* Class = "NSMenuItem"; title = "Report Bug or Feedback"; ObjectID = "hxD-2G-mEq.title"; */
"hxD-2G-mEq.title" = "Report Bug or Feedback";
/* Class = "NSMenuItem"; title = "Report feedback"; ObjectID = "hxD-2G-mEq.title"; */
"hxD-2G-mEq.title" = "Report feedback";
Binary file modified Pika/Assets/fr.lproj/Localizable.strings
Binary file not shown.
6 changes: 3 additions & 3 deletions Pika/Assets/fr.lproj/Main.strings
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
/* Class = "NSMenu"; title = "Help"; ObjectID = "F2S-fz-NVQ"; */
"F2S-fz-NVQ.title" = "Aider";

/* Class = "NSMenuItem"; title = "Pika Website"; ObjectID = "FKE-Sm-Kum"; */
/* Class = "NSMenuItem"; title = "Pika website"; ObjectID = "FKE-Sm-Kum"; */
"FKE-Sm-Kum.title" = "Site web";

/* Class = "NSMenu"; title = "Eyedroppers"; ObjectID = "KHB-9b-hO2"; */
Expand Down Expand Up @@ -83,5 +83,5 @@
/* Class = "NSMenuItem"; title = "Copy foreground"; ObjectID = "x3v-GG-iWU"; */
"x3v-GG-iWU.title" = "Copier le premier plan";

/* Class = "NSMenuItem"; title = "Report Bug or Feedback"; ObjectID = "hxD-2G-mEq.title"; */
"hxD-2G-mEq.title" = "Signaler un bogue ou un commentaire";
/* Class = "NSMenuItem"; title = "Report feedback"; ObjectID = "hxD-2G-mEq.title"; */
"hxD-2G-mEq.title" = "Signaler des commentaires";
4 changes: 2 additions & 2 deletions Pika/Constants/Constants.swift
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,8 @@ enum PikaText {
static let textMenuAbout = NSLocalizedString("menu.about", comment: "About")
static let textMenuUpdates = NSLocalizedString("menu.updates", comment: "Check for updates")
static let textMenuPreferences = NSLocalizedString("menu.preferences", comment: "Preferences")
static let textMenuWebsite = NSLocalizedString("menu.website", comment: "Pika Website")
static let textMenuGitHubIssue = NSLocalizedString("menu.issue", comment: "Report Bug or Feedback")
static let textMenuWebsite = NSLocalizedString("menu.website", comment: "Pika website")
static let textMenuGitHubIssue = NSLocalizedString("menu.issue", comment: "Report feedback")
static let textMenuQuit = NSLocalizedString("menu.quit", comment: "Quit Pika")

// Navigation
Expand Down
4 changes: 4 additions & 0 deletions Pika/Views/AboutView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ struct AboutView: View {
title: PikaText.textAboutGitHub,
link: PikaConstants.gitHubRepoURL
)
LinkButton(
title: PikaText.textMenuGitHubIssue,
link: PikaConstants.gitHubIssueURL
)
}

VStack(spacing: 0) {
Expand Down
6 changes: 3 additions & 3 deletions Pika/Views/NavigationMenuItems.swift
Original file line number Diff line number Diff line change
Expand Up @@ -133,6 +133,9 @@ struct NavigationMenuItems: View {
Button("\(PikaText.textMenuUpdates)...", action: {
NSApp.sendAction(#selector(AppDelegate.checkForUpdates), to: nil, from: nil)
})
Button(PikaText.textMenuGitHubIssue, action: {
NSApp.sendAction(#selector(AppDelegate.openGitHubIssue), to: nil, from: nil)
})
Button(PikaText.textMenuPreferences, action: {
NSApp.sendAction(#selector(AppDelegate.openPreferencesWindow), to: nil, from: nil)
})
Expand All @@ -143,9 +146,6 @@ struct NavigationMenuItems: View {
$0
}
}
Button(PikaText.textMenuGitHubIssue, action: {
NSApp.sendAction(#selector(AppDelegate.openGitHubIssue), to: nil, from: nil)
})
}

VStack {
Expand Down

0 comments on commit 7782242

Please sign in to comment.