Giorgos Keramidas avatar Giorgos Keramidas committed 480e8eb

Share the same systray widget between multiple screens

When focus moves from one screen to the next the shared systray
will appear in the currently active screen. This is still not
perfect, as it may be required to temporarily switch to a new tag
to let awesome notice that 'screen' is now different, and move
the system tray. I'll try to hack something better in the
upcoming days.

Comments (0)

Files changed (2)

.config/awesome/rc.lua

             end
         end))
 
+-- Create one system tray that will be shared by multiple screens if we
+-- have more than one (e.g. in multiheaded display setups).
+mytray = wibox.widget.systray()
+
 for s = 1, screen.count() do
     -- Create an imagebox widget which will contains an icon indicating
     -- which layout we're using.  We need one layoutbox per screen.
 
     -- Widgets that are aligned to the right
     local right_layout = wibox.layout.fixed.horizontal()
-    if s == 1 then right_layout:add(wibox.widget.systray()) end
+    -- Share one systray between all active screens.
+    right_layout:add(mytray)
     right_layout:add(mytextclock)
     right_layout:add(mylayoutbox[s])
 
+2011-11-30  Giorgos Keramidas  <keramida@ceid.upatras.gr>
+
+	* .config/awesome/rc.lua: Share the same systray widget
+	between multiple screens.
+
+	When focus moves from one screen to the next the shared
+	systray will appear in the currently active screen. This
+	is still not perfect, as it may be required to
+	temporarily switch to a new tag to let awesome notice
+	that 'screen' is now different, and move the system tray.
+	I'll try to hack something better in the upcoming days.
+
 2011-11-28  Giorgos Keramidas  <keramida@ceid.upatras.gr>
 
 	* .config/awesome/rc.lua: Add a rule that floats 'gedit'
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.