fix: 修复任务栏应用需要点击两次才能active的问题
修复任务栏应用需要点击两次才能active的问题 Log: Task: https://pms.uniontech.com/task-view-142531.html Influence: 任务栏应用一次点击就可以打开 Change-Id: I792202025a155a21ad7133887c17289b9a653c6f
This commit is contained in:
@ -170,7 +170,9 @@ void XCBUtils::setActiveWindow(XWindow xid)
|
||||
|
||||
void XCBUtils::changeActiveWindow(XWindow newActiveXid)
|
||||
{
|
||||
xcb_ewmh_request_change_active_window(&m_ewmh, m_screenNum, newActiveXid, XCB_EWMH_CLIENT_SOURCE_TYPE_OTHER, 0, 0);
|
||||
xcb_ewmh_request_change_active_window(&m_ewmh, m_screenNum, newActiveXid, XCB_EWMH_CLIENT_SOURCE_TYPE_OTHER, XCB_CURRENT_TIME, XCB_WINDOW_NONE);
|
||||
// 此处getActiveWindow作用是触发缓冲机制,执行设置活动窗口动作
|
||||
getActiveWindow();
|
||||
}
|
||||
|
||||
void XCBUtils::restackWindow(XWindow xid)
|
||||
@ -370,6 +372,11 @@ void XCBUtils::setCurrentWMDesktop(uint32_t desktop)
|
||||
xcb_ewmh_set_current_desktop(&m_ewmh, m_screenNum, desktop);
|
||||
}
|
||||
|
||||
void XCBUtils::changeCurrentDesktop(uint32_t newDesktop, uint32_t timestamp)
|
||||
{
|
||||
xcb_ewmh_request_change_current_desktop(&m_ewmh, m_screenNum, newDesktop, timestamp);
|
||||
}
|
||||
|
||||
uint32_t XCBUtils::getCurrentWMDesktop()
|
||||
{
|
||||
uint32_t ret;
|
||||
|
Reference in New Issue
Block a user