widget_factory.h

00001 /*
00002  * widget_factory.h
00003  * This file is part of dbPager Classes Library (DCL)
00004  *
00005  * Copyright (c) 2008 Dennis Prochko <wolfsoft@mail.ru>
00006  *
00007  * DCL is free software; you can redistribute it and/or modify
00008  * it under the terms of the GNU General Public License as published by
00009  * the Free Software Foundation version 3.
00010  *
00011  * DCL is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  * GNU General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU General Public License
00017  * along with DCL; if not, write to the Free Software
00018  * Foundation, Inc., 51 Franklin St, Fifth Floor,
00019  * Boston, MA  02110-1301  USA
00020  */
00021 
00022 #ifndef _WIDGET_FACTORY_H_
00023 #define _WIDGET_FACTORY_H_
00024 
00025 #include <memory>
00026 
00027 #include <dcl/dialogs.h>
00028 #include <dcl/plugin.h>
00029 
00030 namespace dbp {
00031 
00032 class application_int;
00033 
00035 
00040 class widget_factory: public disposable {
00041 public:
00042         typedef std::auto_ptr<application_int> gui_application_ptr;
00044         virtual gui_application_ptr create_application() = 0;
00045         typedef std::auto_ptr<message_box> message_box_ptr;
00047         virtual message_box_ptr create_message_box(
00048           const std::string &title, const std::string &message,
00049           message_type::message_type type = message_type::error,
00050           message_buttons::message_buttons buttons = message_buttons::ok) = 0;
00051 };
00052 
00053 } //namespace
00054 
00055 #endif /*_WIDGET_FACTORY_H_*/

 
Support This Project
SourceForge.net Logo