Commit Graph

37 Commits

Author SHA1 Message Date
Genesis 7eb2a6b709
Add a configuration entry to disable auto_back_and_forth on Sway workspaces 2021-02-02 21:58:26 +01:00
Michael Rodler 006850ea5e Changed helper function for workspace->num assignment to a static method of Workspaces class
and adapted comments/method name to be consistent with the rest
2020-07-27 10:56:49 +02:00
Tudor Brindus 0080feb9af sway/workspaces: make clicking on workspaces idempotent
Previously, clicking on the same workspace you were on would throw you
to another workspace if `workspace_auto_back_and_forth yes` was
specified in your sway config. This also fixes workspace output moving
misbehaving and doing the same.
2020-06-09 20:43:43 -04:00
Jan Beich 1dc557456e Add missing includes for libc++
In file included from ../src/modules/custom.cpp:1:
In file included from ../include/modules/custom.hpp:7:
../include/util/command.hpp:15:25: error: implicit instantiation of undefined template 'std::__1::array<char, 128>'
  std::array<char, 128> buffer = {0};
                        ^
../src/modules/pulseaudio.cpp:175:41: error: implicit instantiation of undefined template 'std::__1::array<std::__1::basic_string<char>, 9>'
static const std::array<std::string, 9> ports = {
                                        ^
/usr/include/c++/v1/__tuple:223:64: note: template is declared here
template <class _Tp, size_t _Size> struct _LIBCPP_TEMPLATE_VIS array;
                                                               ^
In file included from ../src/factory.cpp:1:
In file included from ../include/factory.hpp:8:
../include/modules/sway/workspaces.hpp:39:8: error: no template named 'unordered_map' in namespace 'std'
  std::unordered_map<std::string, Gtk::Button> buttons_;
  ~~~~~^
../src/factory.cpp:20:14: error: cannot initialize return object of type 'waybar::AModule *' with an rvalue of type 'waybar::modules::sway::Workspaces *'
      return new waybar::modules::sway::Workspaces(id, bar_, config_[name]);
             ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2020-05-19 10:37:27 +00:00
Danilo Spinella e0c42ae415 fix(sway): add missing unordered_map include 2020-02-11 14:31:17 +01:00
Aleksei Bavshin ae6ca36fa7
fix(sway): resolve destruction dependency between Ipc and SleeperThread
Ipc destructor closes socket and thus wakes up SleeperThread which was
waiting for socket data in Ipc::handleEvent.
Ipc::handleEvent then proceeds with sending signal to already destroyed
object, causing heap-use-after-free Address Sanitizer error.
2020-02-04 23:22:43 -08:00
Alex ff9d598c16 fix: add proper mutex 2019-06-17 11:39:45 +02:00
Alex 340ec7be91 refactor: AModule 2019-06-15 14:57:52 +02:00
Patrick Hilhorst ed4521d113
Workspaces: fix twitchy scrolling on touchpads
Previously, any and all scroll events were interpreted as reason to switch
workspaces. This resulted in twitchy behaviour, where the scrolling was
practically unusable.

Now, we pool all scroll values, and only scroll if the value is larger than the
new config option "smooth-scrolling-threshold". If this option is not set, the
behaviour is unchanged.
2019-06-11 17:22:24 +02:00
Alex fcf2d18a01 refactor: destroy threads first 2019-05-29 17:53:22 +02:00
Alex 2a9fa1a4b9 refactor(bar): onRealize, onMap 2019-05-25 17:50:45 +02:00
Lucas Lazare 1a76aa0c8c Improving ordering 2019-05-18 11:58:01 -04:00
Alex 4d4cadb5ae refactor: simpler code 2019-05-17 09:59:37 +02:00
RX14 b45dcdf74e
Allow scrolling on the entire bar surface 2019-05-16 22:18:43 +01:00
Alex 362c393b1d refactor: try/catch, sigc trackable 2019-05-13 15:15:50 +02:00
Alex 5a44c8c6de refactor: avoid unneeded json parsing 2019-05-07 13:43:48 +02:00
Alex 311c34ecbc feat(Bar): handle widget size changes 2019-04-24 12:37:24 +02:00
Alex cccf60c30e fix(Workspaces): fix concurrence and move json parser to ipc client 2019-04-23 11:42:08 +02:00
Alex cbb6f2a307 refactor(Workspaces, IPC): no more mutex in the workspaces modules, moved to the IPC client for a proper handling 2019-04-19 16:48:02 +02:00
Alex e77c155ede fix(workspaces): avoid mutex block 2019-04-19 12:11:55 +02:00
Alex bb1cf7570e refactor(IPC): use sigc signal 2019-04-19 11:09:06 +02:00
Alex 6ed8f94dab refactor: format code 2019-04-18 17:52:00 +02:00
Alex bc9a49787a feat: enable pango markup on sway workspaces 2019-04-15 10:55:44 +02:00
Alex 22cddc5e26 refactor(workspaces): scroll output aware 2019-03-18 14:44:07 +01:00
John Doe 737da3615f resolves #205 2019-03-03 21:35:32 +11:00
Alex add9e925f4 fix(Workspaces): button order 2019-02-02 00:36:52 +01:00
Alexis 399f61df98 refactor: proper modules destruction 2019-01-13 22:22:22 +01:00
Robinhuett 29a2ee1744 refactor: Replace all occurencec of gtkmm.h and only use the necessary headers 2019-01-08 21:05:44 +01:00
Caleb Bassi 8ea0659ee2 Remove ws index from sway ws names 2018-12-28 09:36:02 -08:00
Alexis b554094c7e feat: args && class id 2018-12-18 17:30:54 +01:00
Alexis 691fb88057 refactor(modules): const bar 2018-12-01 00:10:41 +01:00
David96 168415440f Fix clicking and scrolling through workspaces
The way waybar used the workspace "num", clicking a workspace called "1:
something" resulted in going to a newly created workspace called "1",
because the workspace ipc command expects the workspace name, not its number.
2018-11-05 20:16:19 +01:00
Alexis 7020af7653
feat(Workspaces): urgent, visible, focused icons 2018-09-05 00:16:56 +02:00
Alex 49232eed8d
Clean (#31) 2018-08-20 14:50:45 +02:00
Alex 6705134034
Handle screens disconnection (#29) 2018-08-19 13:39:57 +02:00
Alex 6635548d3e
Style code (#25) 2018-08-16 14:29:41 +02:00
Alexis f94598c138 feat(sway): add focused window name 2018-08-15 20:17:17 +02:00
Renamed from include/modules/workspaces.hpp (Browse further)