mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-23 05:45:58 +01:00
fix dwindle + minor logs and comments
This commit is contained in:
parent
53388ad8a4
commit
f82fdb012e
3 changed files with 8 additions and 2 deletions
|
@ -56,7 +56,6 @@ void Events::listener_unmapWindow(wl_listener* listener, void* data) {
|
||||||
g_pCompositor->m_pLastFocus = nullptr;
|
g_pCompositor->m_pLastFocus = nullptr;
|
||||||
|
|
||||||
PWINDOW->m_bMappedX11 = false;
|
PWINDOW->m_bMappedX11 = false;
|
||||||
PWINDOW->m_bIsMapped = false;
|
|
||||||
|
|
||||||
// remove the fullscreen window status from workspace if we closed it
|
// remove the fullscreen window status from workspace if we closed it
|
||||||
const auto PWORKSPACE = g_pCompositor->getWorkspaceByID(PWINDOW->m_iWorkspaceID);
|
const auto PWORKSPACE = g_pCompositor->getWorkspaceByID(PWINDOW->m_iWorkspaceID);
|
||||||
|
@ -66,6 +65,9 @@ void Events::listener_unmapWindow(wl_listener* listener, void* data) {
|
||||||
|
|
||||||
g_pLayoutManager->getCurrentLayout()->onWindowRemoved(PWINDOW);
|
g_pLayoutManager->getCurrentLayout()->onWindowRemoved(PWINDOW);
|
||||||
|
|
||||||
|
// do this after onWindowRemoved because otherwise it'll think the window is invalid
|
||||||
|
PWINDOW->m_bIsMapped = false;
|
||||||
|
|
||||||
// refocus on a new window
|
// refocus on a new window
|
||||||
// TODO: investigate.
|
// TODO: investigate.
|
||||||
// If a parent window has focus, any popups (XWayland) will be broken (they will disappear instantly)
|
// If a parent window has focus, any popups (XWayland) will be broken (they will disappear instantly)
|
||||||
|
|
|
@ -186,6 +186,8 @@ void CInputManager::onKeyboardKey(wlr_event_keyboard_key* e, SKeyboard* pKeyboar
|
||||||
|
|
||||||
bool found = false;
|
bool found = false;
|
||||||
if (e->state == WL_KEYBOARD_KEY_STATE_PRESSED) {
|
if (e->state == WL_KEYBOARD_KEY_STATE_PRESSED) {
|
||||||
|
Debug::log(LOG, "Pressed key %i, with the MODMASK being %i", e->keycode, MODS);
|
||||||
|
|
||||||
for (int i = 0; i < syms; ++i)
|
for (int i = 0; i < syms; ++i)
|
||||||
found = g_pKeybindManager->handleKeybinds(MODS, keysyms[i]) || found;
|
found = g_pKeybindManager->handleKeybinds(MODS, keysyms[i]) || found;
|
||||||
} else if (e->state == WL_KEYBOARD_KEY_STATE_RELEASED) {
|
} else if (e->state == WL_KEYBOARD_KEY_STATE_RELEASED) {
|
||||||
|
|
|
@ -35,6 +35,8 @@ bool CKeybindManager::handleKeybinds(const uint32_t& modmask, const xkb_keysym_t
|
||||||
// oMg such performance hit!!11!
|
// oMg such performance hit!!11!
|
||||||
// this little maneouver is gonna cost us 4µs
|
// this little maneouver is gonna cost us 4µs
|
||||||
const auto KBKEY = xkb_keysym_from_name(k.key.c_str(), XKB_KEYSYM_CASE_INSENSITIVE);
|
const auto KBKEY = xkb_keysym_from_name(k.key.c_str(), XKB_KEYSYM_CASE_INSENSITIVE);
|
||||||
|
// TODO: fix this with shift, shift makes all the keys uppercase
|
||||||
|
// if (shift) KBKEY -= someindex
|
||||||
|
|
||||||
if (key != KBKEY)
|
if (key != KBKEY)
|
||||||
continue;
|
continue;
|
||||||
|
|
Loading…
Reference in a new issue