Add mock notifications for terminal app
This commit adds two mock notifications for the terminal app:
1. VmLauncherService foreground notification
As a foreground service, VmLauncherService should display a
notification to indicate the service is running.
Terminal app should pass a Notification to the
VmLauncherService for the foreground notification
2. Port forwarding notification
When the VM opens a port, terminal app should send a
notification for user to allow or deny the request
Bug: 372170751
Test: Install on komodo
Change-Id: Iac0ae70354f984246abcb6af1d650a548d59387d
diff --git a/android/TerminalApp/res/values/strings.xml b/android/TerminalApp/res/values/strings.xml
index 1cbaee8..0cdb939 100644
--- a/android/TerminalApp/res/values/strings.xml
+++ b/android/TerminalApp/res/values/strings.xml
@@ -49,6 +49,14 @@
<string name="settings_port_forwarding_title">Port Forwarding</string>
<!-- Settings menu subtitle for 'port forwarding' [CHAR LIMIT=none] -->
<string name="settings_port_forwarding_sub_title">Configure port forwarding</string>
+ <!-- Notification title for new port forwarding [CHAR LIMIT=none] -->
+ <string name="settings_port_forwarding_notification_title">Terminal is trying to open a new port</string>
+ <!-- Notification content for new port forwarding [CHAR LIMIT=none] -->
+ <string name="settings_port_forwarding_notification_content">Port requested to be open: <xliff:g id="port_number" example="8080">%d</xliff:g></string>
+ <!-- Notification action accept [CHAR LIMIT=none] -->
+ <string name="settings_port_forwarding_notification_accept">Accept</string>
+ <!-- Notification action deny [CHAR LIMIT=none] -->
+ <string name="settings_port_forwarding_notification_deny">Deny</string>
<!-- Settings menu title for recoverying image [CHAR LIMIT=none] -->
<string name="settings_recovery_title">Recovery</string>
@@ -60,4 +68,13 @@
<string name="settings_recovery_reset_sub_title">Remove all</string>
<!-- Toast message for reset is completed [CHAR LIMIT=none] -->
<string name="settings_recovery_reset_message">VM reset</string>
+
+ <!-- Notification action button for settings [CHAR LIMIT=none] -->
+ <string name="service_notification_settings">Settings</string>
+ <!-- Notification title for foreground service notification [CHAR LIMIT=none] -->
+ <string name="service_notification_title">Terminal is running</string>
+ <!-- Notification content for foreground service notification [CHAR LIMIT=none] -->
+ <string name="service_notification_content">Click to open the terminal.</string>
+ <!-- Notification action button for closing the virtual machine [CHAR LIMIT=none] -->
+ <string name="service_notification_quit_action">Close</string>
</resources>