DLL_LOCAL bool check_window(VALUE self,VALUE hash, VALUE window, wxWindow*& w) { if(rb_obj_is_kind_of(window,rb_cClass) && rb_class_inherited(window,rb_cWXWindow)) { VALUE argv2[] = {self, hash }; w = unwrap<wxWindow*>(rb_class_new_instance(2,argv2,window)); return true; #if wxUSE_TREEBOOK }else if(nil_check(window,!rb_obj_is_kind_of(self,rb_cWXTreebook))) //TODO Tree Ctrl allows nil page, but i can't check that #else }else if(nil_check(window))
bool nil_check(VALUE window, bool raise) { return nil_check(window,"window",raise); }
bool nil_check(VALUE window,VALUE klass, bool raise) { return nil_check(window,rb_class2name(klass),raise); }