From 6cdfee2bd7d0df191be555d3eb670a856a78e4c6 Mon Sep 17 00:00:00 2001 From: User Date: Tue, 12 Jan 2016 19:36:50 +0000 Subject: [PATCH] Initial connection monitor UI --- gnome-shell/firewall@subgraph.com/extension.js | 5 +++++ .../schemas/com.subgraph.firewall.gschema.xml | 1 - gnome-shell/firewall@subgraph.com/stylesheet.css | 9 +++++++++ 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/gnome-shell/firewall@subgraph.com/extension.js b/gnome-shell/firewall@subgraph.com/extension.js index 6bcecb7..976ffa7 100644 --- a/gnome-shell/firewall@subgraph.com/extension.js +++ b/gnome-shell/firewall@subgraph.com/extension.js @@ -4,6 +4,8 @@ const Gio = imports.gi.Gio; const Extension = imports.misc.extensionUtils.getCurrentExtension(); const Dialog = Extension.imports.dialog; const Menu = Extension.imports.menu; +const ConnectionMonitor = Extension.imports.cmonitor; + function init() { return new FirewallSupport(); @@ -14,6 +16,7 @@ const FirewallSupport = new Lang.Class({ _init: function() { this.menu = new Menu.FirewallMenu(); + this.cmon = new ConnectionMonitor.ConnectionMonitor(); this.handler = null; }, @@ -26,10 +29,12 @@ const FirewallSupport = new Lang.Class({ enable: function() { this._destroyHandler(); this.handler = new FirewallPromptHandler(); + this.cmon.install(); this.menu.install(); }, disable: function() { this.menu.destroy(); + this.cmon.remove(); this._destroyHandler(); } }); diff --git a/gnome-shell/firewall@subgraph.com/schemas/com.subgraph.firewall.gschema.xml b/gnome-shell/firewall@subgraph.com/schemas/com.subgraph.firewall.gschema.xml index 2daee70..559b079 100644 --- a/gnome-shell/firewall@subgraph.com/schemas/com.subgraph.firewall.gschema.xml +++ b/gnome-shell/firewall@subgraph.com/schemas/com.subgraph.firewall.gschema.xml @@ -4,7 +4,6 @@ space']]]> Key to open connection monitor - \ No newline at end of file diff --git a/gnome-shell/firewall@subgraph.com/stylesheet.css b/gnome-shell/firewall@subgraph.com/stylesheet.css index df3b38e..6452dbf 100644 --- a/gnome-shell/firewall@subgraph.com/stylesheet.css +++ b/gnome-shell/firewall@subgraph.com/stylesheet.css @@ -1,3 +1,12 @@ + +.connection-monitor { + background-color: rgba(0, 0, 0, 0.8); + spacing: 4px; + padding: 4px; + border: 2px solid grey; + border-radius: 4px; +} + .fw-prompt-dialog { min-width: 450px; max-width: 500px;