mirror of
https://github.com/danbulant/node-x11
synced 2026-05-21 05:19:14 +00:00
hash instead of array in GetWindowAttributes result
This commit is contained in:
parent
3f1b8e5442
commit
07cbcea4d7
1 changed files with 12 additions and 3 deletions
|
|
@ -190,11 +190,20 @@ module.exports = {
|
|||
|
||||
GetWindowAttributes: [
|
||||
['CxSL', [3, 2]],
|
||||
function(buf)
|
||||
function(buf, backingStore)
|
||||
{
|
||||
// TODO: change from array to named object fields
|
||||
var res = buf.unpack('LSCCLLCCCCCLLLS');
|
||||
return res;
|
||||
var res = buf.unpack('LSCCLLCCCCLLLS');
|
||||
var ret = {
|
||||
backingStore: backingStore
|
||||
};
|
||||
( "visual klass bitGravity winGravity backingPlanes backingPixel" +
|
||||
" saveUnder mapIsInstalled mapState overrideRedirect colormap" +
|
||||
" allEventMasks myEventMasks doNotPropogateMask" )
|
||||
.split(' ').forEach(function(field, index) {
|
||||
ret[field] = res[index];
|
||||
});
|
||||
return ret;
|
||||
}
|
||||
],
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue