Skip to content

Commit

Permalink
whitespace trim monitor szShortDescription
Browse files Browse the repository at this point in the history
  • Loading branch information
spikespaz committed Feb 9, 2024
1 parent 16987e5 commit 76e96cf
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/helpers/Monitor.cpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#include "Monitor.hpp"

#include "MiscFunctions.hpp"

#include "../Compositor.hpp"

int ratHandler(void* data) {
Expand Down Expand Up @@ -55,7 +57,8 @@ void CMonitor::onConnect(bool noRule) {
szDescription.erase(std::remove(szDescription.begin(), szDescription.end(), ','), szDescription.end());

// field is backwards-compatible with intended usage of `szDescription` but excludes the parenthesized DRM node name suffix
szShortDescription = std::format("{} {} {}", output->make ? output->make : "", output->model ? output->model : "", output->serial ? output->serial : "");
szShortDescription =
removeBeginEndSpacesTabs(std::format("{} {} {}", output->make ? output->make : "", output->model ? output->model : "", output->serial ? output->serial : ""));

if (!wlr_backend_is_drm(output->backend))
createdByUser = true; // should be true. WL, X11 and Headless backends should be addable / removable
Expand Down

0 comments on commit 76e96cf

Please sign in to comment.