From 34a9f87ed27b44d5f0337477605fc22306802eac Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Sat, 16 Nov 2002 13:52:13 +0000 Subject: [PATCH] print a warning if more than one main widget is set --- otk/application.cc | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/otk/application.cc b/otk/application.cc index 0a250ea3..29dc6bf4 100644 --- a/otk/application.cc +++ b/otk/application.cc @@ -69,7 +69,11 @@ void OtkApplication::exec(void) bool OtkApplication::setMainWidget(const OtkWidget *main_widget) { // ignore it if it has already been set - if (_main_widget) return false; + if (_main_widget) { + std::cerr << "More than one main OtkWidget being created for the " << + "OtkApplication!\n"; + return false; + } _main_widget = main_widget; -- 2.45.2