Commit Graph

37 Commits

Author SHA1 Message Date
3b6a950380 Remove unused factory.hpp imports 2021-09-21 21:43:27 +02:00
523e4d6313 fix(fs): Only add spacing between shown mountpoints
Fixes #2458
2021-07-11 14:51:15 +02:00
529843b6ba Remove undefined behaviors and clean code (#1769)
* fix: avoid memory leaks in case of exceptions.

* fix(fs): remove undefined behavior when removing mounts in m_mounts

* cleanup: remove double checks

* fix: remove memory leaks

* cleanup(xresources): capture exception by reference

Co-authored-by: Patrick Ziegler <p.ziegler96@gmail.com>
2021-02-15 23:32:56 +01:00
1c554dd0e0 Merge branch 'hotfix/3.5.1' 2020-12-12 13:28:57 +01:00
ae1c6ca1b7 Fix 2283: Replace tokens at build() instread of update() 2020-12-12 12:33:21 +01:00
82ebad5e7a fix(timer_module): Ensure that interval > 0 (#2274)
Since 3.5.0, we use m_interval for a modulo operation, this crashes the
bar if the interval is 0. A non-positive interval shouldn't be allowed
anyway, so we now throw an exception in that case.

Fixes #2273
2020-12-05 22:58:38 +01:00
39c73a8234 feat: Warn state for cpu, memory, fs, battery modules (#2199)
* [Temperature, Ramp] fix wrong icon for temperatures near base and warn temps

* [Temperature, Ramp] fix wrong icon for temperatures near base and warn temps

* Fix minor error

* Added WARN state for cpu module

* Implement WARN state for CPU, Memory modules, working on fs module

* Implement WARN state for fs module

* Simplify WARN state implementation for cpu and memory

* explicitly check percentage in get_by_percentage_with_borders

* Fixed silly error

* implement warn state on battery module, standardize the implementation on other modules

* minor fixes

* fix annoying error

* use more intuitive param name

* Fix percentage with borders bug

* Make requested changes
Hide the effect of warn states when unused

* Backward Compat: use no format instead of fallback label

* Reformat

* Refactor

* Reformat

* Reformat: convert tabs to spaces

* Reformat
2020-12-02 15:55:13 +01:00
5a695c7065 doc: Update links to https (#2012) 2020-02-21 15:39:39 +01:00
51f9f35599 cleanup(logger): use universal references to avoid useless copies 2020-01-24 16:32:26 +01:00
82b9ea8a09 fs: Fix incorrect size report on 32bit machines (#1699)
Cast before multiplication to avoid overflow.

Fixes #743
2019-03-18 18:16:42 +01:00
a0b888b5e6 fix(fs): Calculate free bytes properly
Seems this was missed in a682d2af91

This is now also consistent with what df does

Closes #743
2019-01-17 08:31:48 +01:00
a682d2af91 fix(fs): Use f_frsize in filesystem calculations
This is consistent with the documentation of
std::experimental::filesystem, so I think it is the more "correct"
thing to be doing here.
2017-09-14 19:02:55 -05:00
138f5faed8 fix(fs): Calculate used, percentages according to df
Fixes #710.
2017-09-06 17:20:10 -07:00
82d360e634 fix(fs): Use available bytes to calculate free disk space
Refs #396
2017-01-30 14:39:06 +01:00
0f87d37137 fix(fs): Set bytes_avail
Refs #343
2017-01-17 15:20:46 +01:00
3292cea786 refactor(tokens): Move token suffix to configuration 2017-01-14 18:00:35 +01:00
6dd72aa6f7 refactor(fs): Read /proc/self/mountinfo
Refs #271
2017-01-12 23:33:32 +01:00
c2ac7fde67 refactor: Filesize strings 2017-01-12 20:28:44 +01:00
ef6f649579 fix(fs): Make sure to match with correct mtab entry
Fixes #321
2017-01-12 15:30:47 +01:00
35f441cdde fix(fs): Mounted state
Fixes #271
2017-01-08 20:42:59 +01:00
5c55beed7b fix(fs): Value type 2017-01-02 02:50:22 +01:00
14958bdd23 fix: Correct type for module interval 2016-12-31 03:04:01 +01:00
78bb3695e6 refactor(config): Deduce return type from default value 2016-12-30 23:32:05 +01:00
53f781f527 feat(fs): Add option to remove invalid/unmounted endpoints 2016-12-30 22:44:28 +01:00
4bc203dd1f fix(fs): Output error if statvfs() fails
Refs #271
2016-12-27 02:03:15 +01:00
55934c12a3 fix(fs): Use avail bytes to calculate percentage
Refs #271
2016-12-27 01:32:33 +01:00
788a7ca3a3 refactor(modules): Get rid of .inl files 2016-12-21 09:21:35 +01:00
c01f111e34 refactor(modules): Move setup to constructor 2016-12-21 08:00:09 +01:00
a0d485f79d refactor: Initialize data 2016-12-15 09:30:31 +01:00
1a2a6e5fab refactor: Construction methods 2016-12-14 11:01:44 +01:00
ff9be848c7 refactor(clang-tidy): Apply fixes 2016-11-25 21:58:49 +01:00
c6d85b2b92 refactor: Optimize build 2016-11-20 23:04:31 +01:00
88c8bbd940 refactor: Fwd declare drawtypes
Ref #164
2016-11-19 15:49:06 +01:00
fd57ab0f3d fix: project rename 2016-11-19 06:26:07 +01:00
c8f2a934b1 refactor(fs): Update naming to reflect actual usage
The module currently only handle mounted filesystem
and not block devices or partitions. Change naming
to be more clear.
2016-11-13 08:50:14 +01:00
d2a6773c26 fix(fs): Remove unmounted format tags 2016-11-13 06:40:35 +01:00
9a0df75a91 feat(fs): New filesystem module
Module that displays details about
mounted filesystems, #84

Closes #153
2016-11-13 06:14:34 +01:00