[add] initial notification stuff and .desktop file

This commit is contained in:
Tobias Bernard
2017-07-20 20:40:01 +02:00
parent 8ded8067c7
commit 49718f8516
2 changed files with 14 additions and 0 deletions

View File

@@ -0,0 +1,6 @@
[Desktop Entry]
Name=Teleport
Exec=/home/tobi/code/teleport/src/teleportapp
Icon=utilities-terminal
Type=Application
Categories=GTK;GNOME;Utility;

View File

@@ -58,6 +58,14 @@ teleport_app_activate (GApplication *app)
*/
run_avahi_publish_service("Angela's (self)");
run_avahi_service(peerList);
GNotification *notification = g_notification_new ("Hello world!");
g_notification_set_body (notification, "This is an example notification.");
GIcon *icon = g_themed_icon_new ("dialog-information");
g_notification_set_icon (notification, icon);
g_notification_add_button (notification, "5 minutes", "app.reply-5-minutes");
g_application_send_notification (app, NULL, notification);
g_object_unref (icon);
g_object_unref (notification);
}
static void