Skip to content

Commit 5ab22b3

Browse files
committed
add logging
1 parent 133e76e commit 5ab22b3

2 files changed

Lines changed: 13 additions & 4 deletions

File tree

src/ruisapp/glue/linux/wayland/xdg_surface.hxx

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,15 +28,19 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
2828

2929
namespace {
3030
struct xdg_surface_wrapper {
31-
xdg_surface* surface;
31+
xdg_surface* const surface;
3232

3333
constexpr static const xdg_surface_listener listener = {
3434
.configure =
3535
[](void* data, //
36-
xdg_surface* xdg_surface,
36+
xdg_surface* surface,
3737
uint32_t serial) {
38+
utki::log_debug([&](auto& o) {
39+
auto id = wl_proxy_get_id(reinterpret_cast<wl_proxy*>(surface));
40+
o << "xgd_surface: CONFIGURE for surface id = " << id << std::endl;
41+
});
3842
xdg_surface_ack_configure(
39-
xdg_surface, //
43+
surface, //
4044
serial
4145
);
4246
}, //
@@ -55,6 +59,11 @@ struct xdg_surface_wrapper {
5559
throw std::runtime_error("could not create wayland xdg surface");
5660
}
5761

62+
utki::log_debug([&](auto& o) {
63+
auto id = wl_proxy_get_id(reinterpret_cast<wl_proxy*>(this->surface));
64+
o << "xgd_surface: CREATED, id = " << id << std::endl;
65+
});
66+
5867
xdg_surface_add_listener(
5968
this->surface, //
6069
&listener,

src/ruisapp/glue/linux/wayland/xdg_toplevel.cxx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ void xdg_toplevel_wrapper::xdg_toplevel_configure(
6262
)
6363
{
6464
utki::log_debug([](auto& o) {
65-
o << "window CONFIGURE" << std::endl;
65+
o << "toplevel CONFIGURE" << std::endl;
6666
});
6767

6868
utki::log_debug([&](auto& o) {

0 commit comments

Comments
 (0)