/ Published in: Lisp
All the menu's being displayed
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
;;;; Anything that's showed to the user (defparameter line-sep "===========================") ;;; Menus (defun show_interface_selection (inter-list) "Show interface selection" (ext:run-shell-command "netsh interface ipv4 show subinterfaces") (let ((selection 1)) (dolist (inter inter-list) (format t "~a - ~a | ~{~a ~}~%" selection (car inter) (cdr inter)) (setf selection (1+ selection)))) (format t ">> ")) (defun show_main_menu (&optional preset) "Display appropriate menu" (format t " ~a Main Menu ~a 0 - exit 1 - Show current MTU 2 - Edit MTU 3 - Create Preset MTU~%" line-sep line-sep) (when preset (format t "4 - Load Preset MTU 5 - Edit Preset MTU 6 - Delete preset MTU~%")) (format t "9 - Settings~%>> ")) (defun show_settings_menu () (format t " ~a Settings Menu ~a 0 - back 1 - Change Interface~%>> " line-sep line-sep)) (defun edit_mtu () (format t "Selected edit MTU")) (defun create_preset_mtu () (format t "Selected create preset mtu")) (defun load_preset_mtu () (format t "Selected load preset MTU")) (defun edit_preset_mtu () (format t "Selected edit preset MTU")) (defun delete_preset_mtu () (format t "Selected delete preset MTU"))