Inspector: Add a missing event type
authorMatthias Clasen <mclasen@redhat.com>
Tue, 15 Nov 2022 06:18:41 +0000 (07:18 +0100)
committerMatthias Clasen <mclasen@redhat.com>
Tue, 15 Nov 2022 06:18:41 +0000 (07:18 +0100)
We did not have a name for the new touchpad hold
events.

To prevent this from happening again in the future,
add a static assertion.

gtk/inspector/recorder.c

index e0920365ca7e406d15cb109f4b0db39ed83f73c5..8d960411d64cbbb637ec7838d8f6fefa2098ba99 100644 (file)
@@ -1443,9 +1443,12 @@ event_type_name (GdkEventType type)
     "Pad Button Release",
     "Pad Rind",
     "Pad Strip",
-    "Pad Group Mode"
+    "Pad Group Mode",
+    "Touchpad Hold",
   };
 
+  G_STATIC_ASSERT (G_N_ELEMENTS (event_name) == GDK_EVENT_LAST);
+
   return event_name[type];
 }