From 19d7844f040c0290e23efc2e756ff75ce844248e Mon Sep 17 00:00:00 2001 From: p4rfait <114553212+p4rfait@users.noreply.github.com> Date: Sun, 3 Mar 2024 16:55:27 -0600 Subject: [PATCH] hidden-input-field: add seed for random colors in hidden input field outline (#125) --- src/renderer/widgets/PasswordInputField.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/renderer/widgets/PasswordInputField.cpp b/src/renderer/widgets/PasswordInputField.cpp index a5b66e0..c5c33e5 100644 --- a/src/renderer/widgets/PasswordInputField.cpp +++ b/src/renderer/widgets/PasswordInputField.cpp @@ -241,6 +241,7 @@ void CPasswordInputField::updateHiddenInputState() { // randomize new thang hiddenInputState.lastPasswordLength = g_pHyprlock->getPasswordBufferLen(); + srand(std::chrono::system_clock::now().time_since_epoch().count()); float r1 = (rand() % 100) / 255.0; float r2 = (rand() % 100) / 255.0; int r3 = rand() % 3;