提交 0c98152c 编写于 作者: 指向BIOS的野指针's avatar 指向BIOS的野指针

add getPage and getFrame func:

only get their infomations but no buffers
上级 a3840ae2
......@@ -19,6 +19,22 @@ namespace bwl
*/
void initBadWayland(std::string __monitor_device);
/**
* @brief 获得一个页
* 此函数只能获取页的信息,背景缓冲指针是无效的(修改背景缓冲可能是致命的)
* @param pgid
* @return void*
*/
void *getPage(id_t pgid);
/**
* @brief 获得一个窗口
* 此函数只能获取窗口信息,窗口缓冲是无效的(修改窗口缓冲可能是致命的)
* @param fid
* @return void*
*/
void *getFrame(id_t fid);
};
#endif
......@@ -169,7 +169,7 @@ namespace bwl
return frame;
}
void deleteFrame(__frame * frame)
void deleteFrame(__frame *frame)
{
int fid = frame->fid;
std::munmap(frame->client_buf, frame->size[0] * frame->size[1] * frame->pixdepth);
......@@ -208,4 +208,13 @@ namespace bwl
return bad_wayland_server::pix_depth;
}
// TODO这两个getter没有实现
void *getPage(id_t pgid)
{
}
void *getFrame(id_t fid)
{
}
};
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册