mirror of
https://github.com/hyprwm/Hyprland.git
synced 2024-12-25 00:31:39 +03:00
fix layout refresh on config and keybinds doubling
This commit is contained in:
parent
7b7ce638f4
commit
2e5435fe91
@ -217,6 +217,7 @@ void CConfigManager::loadConfigLoadVars() {
|
||||
currentCategory = ""; // reset the category
|
||||
|
||||
m_dMonitorRules.clear();
|
||||
g_pKeybindManager->clearKeybinds();
|
||||
|
||||
const char* const ENVHOME = getenv("HOME");
|
||||
const std::string CONFIGPATH = ENVHOME + (ISDEBUG ? (std::string) "/.config/hypr/hyprlandd.conf" : (std::string) "/.config/hypr/hyprland.conf");
|
||||
@ -255,6 +256,9 @@ void CConfigManager::loadConfigLoadVars() {
|
||||
|
||||
ifs.close();
|
||||
}
|
||||
|
||||
for (auto& m : g_pCompositor->m_lMonitors)
|
||||
g_pLayoutManager->getCurrentLayout()->recalculateMonitor(m.ID);
|
||||
}
|
||||
|
||||
void CConfigManager::tick() {
|
||||
|
@ -59,4 +59,8 @@ void CKeybindManager::spawn(std::string args) {
|
||||
void CKeybindManager::killActive(std::string args) {
|
||||
if (g_pCompositor->m_pLastFocus && g_pCompositor->windowValidMapped(g_pCompositor->m_pLastFocus))
|
||||
g_pXWaylandManager->sendCloseWindow(g_pCompositor->m_pLastFocus);
|
||||
}
|
||||
|
||||
void CKeybindManager::clearKeybinds() {
|
||||
m_dKeybinds.clear();
|
||||
}
|
@ -16,6 +16,7 @@ public:
|
||||
void handleKeybinds(const uint32_t&, const xkb_keysym_t&);
|
||||
void addKeybind(SKeybind);
|
||||
uint32_t stringToModMask(std::string);
|
||||
void clearKeybinds();
|
||||
|
||||
private:
|
||||
std::deque<SKeybind> m_dKeybinds;
|
||||
|
Loading…
Reference in New Issue
Block a user