mirror of
				https://github.com/Swordfish90/cool-retro-term.git
				synced 2025-10-30 14:44:16 +00:00 
			
		
		
		
	Improvements in menus
This commit is contained in:
		| @@ -50,6 +50,12 @@ Item{ | ||||
|     function unloadKTerminal(){ | ||||
|         kterminal.active = false; | ||||
|     } | ||||
|     function pasteClipboard(){ | ||||
|         kterminal.item.pasteClipboard(); | ||||
|     } | ||||
|     function copyClipboard(){ | ||||
|         kterminal.item.copyClipboard(); | ||||
|     } | ||||
|  | ||||
|     Loader{ | ||||
|         id: kterminal | ||||
| @@ -85,14 +91,8 @@ Item{ | ||||
|     } | ||||
|     Menu{ | ||||
|         id: contextmenu | ||||
|         MenuItem{ | ||||
|             text: qsTr("Copy") | ||||
|             onTriggered: kterminal.item.copyClipboard() | ||||
|         } | ||||
|         MenuItem{ | ||||
|             text: qsTr("Paste") | ||||
|             onTriggered: kterminal.item.pasteClipboard() | ||||
|         } | ||||
|         MenuItem{action: copyAction} | ||||
|         MenuItem{action: pasteAction} | ||||
|     } | ||||
|     MouseArea{ | ||||
|  | ||||
|   | ||||
							
								
								
									
										25
									
								
								app/main.qml
									
									
									
									
									
								
							
							
						
						
									
										25
									
								
								app/main.qml
									
									
									
									
									
								
							| @@ -36,21 +36,33 @@ ApplicationWindow{ | ||||
|  | ||||
|     Action { | ||||
|         id: fullscreenAction | ||||
|         text: "&Fullscreen" | ||||
|         text: qsTr("&Fullscreen") | ||||
|         shortcut: "Alt+F11" | ||||
|         onTriggered: shadersettings.fullscreen = !shadersettings.fullscreen; | ||||
|     } | ||||
|     Action { | ||||
|         id: quitAction | ||||
|         text: "&Quit" | ||||
|         text: qsTr("&Quit") | ||||
|         shortcut: "Ctrl+Q" | ||||
|         onTriggered: terminalWindow.close(); | ||||
|     } | ||||
|     Action{ | ||||
|         id: showsettingsAction | ||||
|         text: "&Settings" | ||||
|         text: qsTr("&Settings") | ||||
|         onTriggered: settingswindowloader.active = true; | ||||
|     } | ||||
|     Action{ | ||||
|         id: copyAction | ||||
|         text: qsTr("&Copy") | ||||
|         shortcut: "Ctrl+Shift+C" | ||||
|         onTriggered: terminal.copyClipboard() | ||||
|     } | ||||
|     Action{ | ||||
|         id: pasteAction | ||||
|         text: qsTr("&Paste") | ||||
|         shortcut: "Ctrl+Shift+V" | ||||
|         onTriggered: terminal.pasteClipboard() | ||||
|     } | ||||
|  | ||||
|     menuBar: MenuBar { | ||||
|         id: menubar | ||||
| @@ -62,7 +74,14 @@ ApplicationWindow{ | ||||
|         Menu { | ||||
|             title: qsTr("Edit") | ||||
|             visible: shadersettings.fullscreen ? false : true | ||||
|             MenuItem {action: copyAction} | ||||
|             MenuItem {action: pasteAction} | ||||
|             MenuSeparator{} | ||||
|             MenuItem {action: showsettingsAction} | ||||
|         } | ||||
|         Menu{ | ||||
|             title: qsTr("View") | ||||
|             visible: shadersettings.fullscreen ? false : true | ||||
|             MenuItem {action: fullscreenAction} | ||||
|         } | ||||
|     } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user