[kwin] Use XCB Atom enum definition instead of XLib's one
This commit is contained in:
parent
7e368e1ef3
commit
2c9e21a983
2 changed files with 5 additions and 5 deletions
|
@ -1723,7 +1723,7 @@ QString Client::readName() const
|
|||
if (info->name() && info->name()[0] != '\0')
|
||||
return QString::fromUtf8(info->name());
|
||||
else
|
||||
return KWindowSystem::readNameProperty(window(), XA_WM_NAME);
|
||||
return KWindowSystem::readNameProperty(window(), XCB_ATOM_WM_NAME);
|
||||
}
|
||||
|
||||
KWIN_COMPARE_PREDICATE(FetchNameInternalPredicate, Client, const Client*, (!cl->isSpecialWindow() || cl->isToolbar()) && cl != value && cl->caption() == value->caption());
|
||||
|
@ -1815,7 +1815,7 @@ void Client::fetchIconicName()
|
|||
if (info->iconName() && info->iconName()[0] != '\0')
|
||||
s = QString::fromUtf8(info->iconName());
|
||||
else
|
||||
s = KWindowSystem::readNameProperty(window(), XA_WM_ICON_NAME);
|
||||
s = KWindowSystem::readNameProperty(window(), XCB_ATOM_WM_ICON_NAME);
|
||||
if (s != cap_iconic) {
|
||||
bool was_set = !cap_iconic.isEmpty();
|
||||
cap_iconic = s;
|
||||
|
@ -2120,7 +2120,7 @@ void Client::getSyncCounter()
|
|||
int formatRet;
|
||||
unsigned char* propRet;
|
||||
int ret = XGetWindowProperty(display(), window(), atoms->net_wm_sync_request_counter,
|
||||
0, 1, false, XA_CARDINAL, &retType, &formatRet, &nItemRet, &byteRet, &propRet);
|
||||
0, 1, false, XCB_ATOM_CARDINAL, &retType, &formatRet, &nItemRet, &byteRet, &propRet);
|
||||
|
||||
if (ret == Success && formatRet == 32) {
|
||||
syncRequest.counter = *(xcb_sync_counter_t*)(propRet);
|
||||
|
|
|
@ -399,10 +399,10 @@ void Toplevel::getWmOpaqueRegion()
|
|||
int rformat;
|
||||
unsigned long nitems;
|
||||
if (XGetWindowProperty(display(), m_client,
|
||||
atoms->net_wm_opaque_region, 0, length, false, XA_CARDINAL,
|
||||
atoms->net_wm_opaque_region, 0, length, false, XCB_ATOM_CARDINAL,
|
||||
&type, &rformat, &nitems, &bytes_after_return,
|
||||
reinterpret_cast< unsigned char** >(&data)) == Success) {
|
||||
if (type != XA_CARDINAL || rformat != 32 || nitems%4) {
|
||||
if (type != XCB_ATOM_CARDINAL || rformat != 32 || nitems%4) {
|
||||
// it can happen, that the window does not provide this property
|
||||
XFree(data);
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue