gtk/subclass/stack.rs
1// Take a look at the license at the top of the repository in the LICENSE file.
2
3use glib::subclass::prelude::*;
4
5use super::container::ContainerImpl;
6
7use crate::Stack;
8
9pub trait StackImpl: ContainerImpl {}
10
11unsafe impl<T: ContainerImpl> IsSubclassable<T> for Stack {
12 fn class_init(class: &mut ::glib::Class<Self>) {
13 Self::parent_class_init::<T>(class);
14
15 if !crate::rt::is_initialized() {
16 panic!("GTK has to be initialized first");
17 }
18 }
19}