1 /*---------------------------------------------------------------------\
3 | __ __ ____ _____ ____ |
4 | \ \ / /_ _/ ___|_ _|___ \ |
5 | \ V / _` \___ \ | | __) | |
6 | | | (_| |___) || | / __/ |
7 | |_|\__,_|____/ |_| |_____| |
11 \----------------------------------------------------------------------/
15 Author: Mathias Kettner <kettner@suse.de>
16 Maintainer: Stefan Hundhammer <sh@suse.de>
25 #include "YQUIComponent.h"
26 #include <yui/Y2CCUI.h>
29 * @short Y2ComponentCreator that can create Qt user interfaces
30 * A Y2ComponentCreator is an object, that can create components.
31 * It is given a component name and - if it knows how to create
32 * such a component - returns a newly created component of this
33 * type. The Y2CCQt can create components with the name "qt".
35 class Y2CCQt : public Y2CCUI
39 * Creates a Qt component creator
41 Y2CCQt() : Y2CCUI() { };
44 * Returns true, since the qt component is a
47 bool isServerCreator() const { return true; };
50 * Creates a new Qt UI component.
52 Y2Component *create(const char * name) const
54 if (!strcmp(name, "qt4") )
56 Y2Component* ret = YUIComponent::uiComponent ();
57 if (!ret || ret->name () != name)
59 ret = new YQUIComponent();
68 #endif // ifndef _Y2CCQt_h