widget: Use the correct template in dispose_template()
authorAlexander Mikhaylenko <alexm@gnome.org>
Mon, 6 Mar 2023 01:36:16 +0000 (05:36 +0400)
committerAlexander Mikhaylenko <alexm@gnome.org>
Mon, 6 Mar 2023 01:37:53 +0000 (05:37 +0400)
commit9b3fb66bd4568c05f4bd10bda7f6cc1d2ed6919e
tree6a932878636b1a81047a75168dcb05fc77547064
parentdbaaa59758303aad1bfeaddcbe3e86baf8b4b0ba
widget: Use the correct template in dispose_template()

In derivable classes, the widget's class can be different from the one
dispose_template() was called for, which can lead to failing the
template != NULL check at best, undefined behavior at worst.

Since we already pass the correct GType into the function, just use that
instead.
gtk/gtkwidget.c