binding: add ping() API call
[staging/windowmanager.git] / generate-binding-glue.py
index 7e003a5..db0b546 100644 (file)
@@ -49,7 +49,10 @@ def emit_func_impl(api, f):
 
 def emit_func(api, f):
     p('void %(impl_name)s(afb_req req) noexcept {' % f)
-    p('   std::lock_guard<std::mutex> guard(binding_m);')
+    #p('   std::lock_guard<std::mutex> guard(binding_m);')
+    p('   #ifdef ST')
+    p('   ST();')
+    p('   #endif')
     p('   if (g_afb_instance == nullptr) {',
       '      afb_req_fail(req, "failed", "Binding not initialized, did the compositor die?");',
       '      return;',
@@ -127,6 +130,7 @@ API = {
                 ],
             },
             { 'name': 'list_drawing_names', },
+            { 'name': 'ping' },
 
             { 'name': 'debug_status', },
             { 'name': 'debug_layers', },