summary refs log tree commit diff
diff options
context:
space:
mode:
authorworldofpeace <worldofpeace@protonmail.ch>2019-12-20 11:46:15 -0500
committerworldofpeace <worldofpeace@protonmail.ch>2019-12-21 23:08:13 -0500
commit96e711bcd1c60ec4eabbfc14b5ab3c0fc49799b1 (patch)
tree4fb8e91d27abf412899783c8cc1867c569fa6534
parent4ed65a891c682a85eec5cc6d4f7f5004e52d0fdf (diff)
downloadnixpkgs-96e711bcd1c60ec4eabbfc14b5ab3c0fc49799b1.tar
nixpkgs-96e711bcd1c60ec4eabbfc14b5ab3c0fc49799b1.tar.gz
nixpkgs-96e711bcd1c60ec4eabbfc14b5ab3c0fc49799b1.tar.bz2
nixpkgs-96e711bcd1c60ec4eabbfc14b5ab3c0fc49799b1.tar.lz
nixpkgs-96e711bcd1c60ec4eabbfc14b5ab3c0fc49799b1.tar.xz
nixpkgs-96e711bcd1c60ec4eabbfc14b5ab3c0fc49799b1.tar.zst
nixpkgs-96e711bcd1c60ec4eabbfc14b5ab3c0fc49799b1.zip
pantheon.wingpanel-with-indicators: have indicators argument only append to defaults
Wingpanel was designed firstly as an indicator renderer,
and as such just a container for indicators that are distributed
outside itself. Being able to control which and each indicator with
`indicators` is confusing, ideally each of the default indicators
would be shipped with wingpanel itself. I don't see how this
kind of extensibility would be useful to a user so we're going
to append to the expected defaults. The `useDefaultIndicators`
argument is there to development test a single indicator/s.
-rw-r--r--pkgs/desktops/pantheon/desktop/wingpanel/wrapper.nix6
1 files changed, 5 insertions, 1 deletions
diff --git a/pkgs/desktops/pantheon/desktop/wingpanel/wrapper.nix b/pkgs/desktops/pantheon/desktop/wingpanel/wrapper.nix
index 253c61b7790..a46a26cc9ea 100644
--- a/pkgs/desktops/pantheon/desktop/wingpanel/wrapper.nix
+++ b/pkgs/desktops/pantheon/desktop/wingpanel/wrapper.nix
@@ -6,10 +6,14 @@
 , wingpanelIndicators
 , switchboard-with-plugs
 , indicators ? null
+  # Only useful to disable for development testing.
+, useDefaultIndicators ? true
 }:
 
 let
-  selectedIndicators = if indicators == null then wingpanelIndicators else indicators;
+  selectedIndicators =
+    if indicators == null then wingpanelIndicators
+    else indicators ++ (lib.optional useDefaultIndicators wingpanelIndicators);
 in
 symlinkJoin {
   name = "${wingpanel.name}-with-indicators";