mirror of
https://github.com/hyprwm/hyprlock.git
synced 2025-05-12 21:30:37 +01:00
core: remove CSeatManager::getActiveKbLayoutName
This commit is contained in:
parent
2597a94c07
commit
8ea3fc4256
2 changed files with 0 additions and 20 deletions
|
@ -134,25 +134,6 @@ void CSeatManager::registerCursorShape(SP<CCWpCursorShapeManagerV1> shape) {
|
|||
m_pCursorShape = makeUnique<CCursorShape>(shape);
|
||||
}
|
||||
|
||||
std::string CSeatManager::getActiveKbLayoutName() {
|
||||
if (!m_pXKBState || !m_pXKBKeymap)
|
||||
return "error";
|
||||
|
||||
const auto LAYOUTSNUM = xkb_keymap_num_layouts(m_pXKBKeymap);
|
||||
|
||||
for (uint32_t i = 0; i < LAYOUTSNUM; ++i) {
|
||||
if (xkb_state_layout_index_is_active(m_pXKBState, i, XKB_STATE_LAYOUT_EFFECTIVE) == 1) {
|
||||
const auto LAYOUTNAME = xkb_keymap_layout_get_name(m_pXKBKeymap, i);
|
||||
|
||||
if (LAYOUTNAME)
|
||||
return std::string{LAYOUTNAME};
|
||||
return "error";
|
||||
}
|
||||
}
|
||||
|
||||
return "none";
|
||||
}
|
||||
|
||||
bool CSeatManager::registered() {
|
||||
return m_pSeat;
|
||||
}
|
||||
|
|
|
@ -14,7 +14,6 @@ class CSeatManager {
|
|||
void registerSeat(SP<CCWlSeat> seat);
|
||||
void registerCursorShape(SP<CCWpCursorShapeManagerV1> shape);
|
||||
bool registered();
|
||||
std::string getActiveKbLayoutName();
|
||||
|
||||
SP<CCWlKeyboard> m_pKeeb;
|
||||
SP<CCWlPointer> m_pPointer;
|
||||
|
|
Loading…
Reference in a new issue