Added Add account menu item
This commit is contained in:
parent
825a61e061
commit
23bb4c1b41
|
@ -23,7 +23,7 @@ class MainWindow : View(messages["main.window.title"]) {
|
|||
prefHeight = 620.0
|
||||
prefWidth = 1150.0
|
||||
|
||||
top = MainMenuBar().root
|
||||
top = MainMenuBar(presenter).root
|
||||
|
||||
center {
|
||||
splitpane {
|
||||
|
|
|
@ -3,10 +3,11 @@ package net.dankito.banking.ui.javafx.dialogs.mainwindow.controls
|
|||
import javafx.scene.input.KeyCode
|
||||
import javafx.scene.input.KeyCodeCombination
|
||||
import javafx.scene.input.KeyCombination
|
||||
import net.dankito.banking.ui.presenter.MainWindowPresenter
|
||||
import tornadofx.*
|
||||
|
||||
|
||||
open class MainMenuBar : View() {
|
||||
open class MainMenuBar(protected val presenter: MainWindowPresenter) : View() {
|
||||
|
||||
override val root =
|
||||
menubar {
|
||||
|
@ -14,6 +15,13 @@ open class MainMenuBar : View() {
|
|||
maxHeight = 30.0
|
||||
|
||||
menu(messages["main.window.menu.file"]) {
|
||||
menu(messages["main.window.menu.file.new"]) {
|
||||
item(messages["main.window.menu.file.new.account"], KeyCodeCombination(KeyCode.A, KeyCombination.SHORTCUT_DOWN)) {
|
||||
action { presenter.showAddAccountDialog() }
|
||||
}
|
||||
}
|
||||
|
||||
separator()
|
||||
|
||||
item(messages["main.window.menu.file.quit"], KeyCodeCombination(KeyCode.Q, KeyCombination.SHORTCUT_DOWN)) {
|
||||
action { primaryStage.close() }
|
||||
|
|
|
@ -1,8 +1,5 @@
|
|||
main.window.title=Banking
|
||||
|
||||
main.window.menu.file=File
|
||||
main.window.menu.file.quit=Quit
|
||||
|
||||
|
||||
ok=OK
|
||||
cancel=Cancel
|
||||
|
@ -12,6 +9,12 @@ accounts=Accounts
|
|||
check=Check
|
||||
|
||||
|
||||
main.window.menu.file=File
|
||||
main.window.menu.file.new=New...
|
||||
main.window.menu.file.new.account=Account
|
||||
main.window.menu.file.quit=Quit
|
||||
|
||||
|
||||
accounts.view.context.menu.info=Info
|
||||
|
||||
|
||||
|
|
|
@ -1,8 +1,5 @@
|
|||
main.window.title=Banking
|
||||
|
||||
main.window.menu.file=Datei
|
||||
main.window.menu.file.quit=Beenden
|
||||
|
||||
|
||||
ok=OK
|
||||
cancel=Abbrechen
|
||||
|
@ -12,6 +9,12 @@ accounts=Konten
|
|||
check=Überprüfen
|
||||
|
||||
|
||||
main.window.menu.file=Datei
|
||||
main.window.menu.file.new=Neu...
|
||||
main.window.menu.file.new.account=Konto
|
||||
main.window.menu.file.quit=Beenden
|
||||
|
||||
|
||||
accounts.view.context.menu.info=Info
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue