Merge pull request #1417 from evyatark2/master

This commit is contained in:
Alex 2022-02-01 22:00:29 +01:00 committed by GitHub
commit 2b42872b6c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6,7 +6,9 @@ namespace waybar {
AModule::AModule(const Json::Value& config, const std::string& name, const std::string& id, AModule::AModule(const Json::Value& config, const std::string& name, const std::string& id,
bool enable_click, bool enable_scroll) bool enable_click, bool enable_scroll)
: name_(std::move(name)), config_(std::move(config)) { : name_(std::move(name)), config_(std::move(config))
, distance_scrolled_y_(0.0)
, distance_scrolled_x_(0.0) {
// configure events' user commands // configure events' user commands
if (config_["on-click"].isString() || config_["on-click-middle"].isString() || if (config_["on-click"].isString() || config_["on-click-middle"].isString() ||
config_["on-click-backward"].isString() || config_["on-click-forward"].isString() || config_["on-click-backward"].isString() || config_["on-click-forward"].isString() ||