[yast-commit] r39953 - in /branches/tmp/mvidner/ui-as-namespace/core/libyui/src: Y2CCUI.cc Y2CCUI.h

Author: mvidner Date: Fri Aug 3 17:43:29 2007 New Revision: 39953 URL: http://svn.opensuse.org/viewcvs/yast?rev=39953&view=rev Log: Make the default dummy UI instantiable only after a real one has been tried. Modified: branches/tmp/mvidner/ui-as-namespace/core/libyui/src/Y2CCUI.cc branches/tmp/mvidner/ui-as-namespace/core/libyui/src/Y2CCUI.h Modified: branches/tmp/mvidner/ui-as-namespace/core/libyui/src/Y2CCUI.cc URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/mvidner/ui-as-namespace/co... ============================================================================== --- branches/tmp/mvidner/ui-as-namespace/core/libyui/src/Y2CCUI.cc (original) +++ branches/tmp/mvidner/ui-as-namespace/core/libyui/src/Y2CCUI.cc Fri Aug 3 17:43:29 2007 @@ -28,7 +28,7 @@ #include "Y2CCUI.h" #include "YUIComponent.h" -Y2Component* Y2CCUI::provideNamespace(const char* name) +Y2Component* Y2CCDummyUI::provideNamespace(const char* name) { y2debug ("UI library namespace provider tries for '%s'", name); if (strcmp (name, "UI") == 0) @@ -49,4 +49,4 @@ } // Create global variable to register this component creator -Y2CCUI g_y2ccUI; +Y2CCDummyUI g_y2ccUI; Modified: branches/tmp/mvidner/ui-as-namespace/core/libyui/src/Y2CCUI.h URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/mvidner/ui-as-namespace/co... ============================================================================== --- branches/tmp/mvidner/ui-as-namespace/core/libyui/src/Y2CCUI.h (original) +++ branches/tmp/mvidner/ui-as-namespace/core/libyui/src/Y2CCUI.h Fri Aug 3 17:43:29 2007 @@ -35,10 +35,21 @@ { public: - Y2CCUI () : Y2ComponentCreator (Y2ComponentBroker::BUILTIN) {} + Y2CCUI (Y2ComponentBroker::order_t order = Y2ComponentBroker::BUILTIN) : Y2ComponentCreator (order) {} virtual bool isServerCreator () const { return true; }; +}; + +// Have this class implement the UI interface for ycpc, where we need +// only the type info and not the actual implementation. +// But let it stand after the real UIs +class Y2CCDummyUI : public Y2CCUI +{ + +public: + Y2CCDummyUI () : Y2CCUI (Y2ComponentBroker::PLUGIN) {} + /** * We provide the UI namespace */ -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
mvidner@svn.opensuse.org