[yast-commit] r39146 - in /branches/tmp/sh/mod-ui/core/libyui/src: YWidget.h YWidget_OptimizeChanges.h
Author: sh-sh-sh Date: Tue Jul 3 16:48:52 2007 New Revision: 39146 URL: http://svn.opensuse.org/viewcvs/yast?rev=39146&view=rev Log: moved out-of-place stuff out Added: branches/tmp/sh/mod-ui/core/libyui/src/YWidget_OptimizeChanges.h Modified: branches/tmp/sh/mod-ui/core/libyui/src/YWidget.h Modified: branches/tmp/sh/mod-ui/core/libyui/src/YWidget.h URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/core/libyui/src/YWidget.h?rev=39146&r1=39145&r2=39146&view=diff ============================================================================== --- branches/tmp/sh/mod-ui/core/libyui/src/YWidget.h (original) +++ branches/tmp/sh/mod-ui/core/libyui/src/YWidget.h Tue Jul 3 16:48:52 2007 @@ -624,35 +624,28 @@ **/ void invalidate(); + /** + * Disable copy constructor. + **/ + YWidget( const YWidget & other ); + + /** + * Disable assignment operator. + **/ + const YWidget & operator=( const YWidget & other ); private: + // + // Data Members + // + ImplPtr<YWidgetPrivate> priv; static YPropertySet _propertySet; - - - // FIXME: Get this stuff out of here - it is utterly out of place - // FIXME: Get this stuff out of here - it is utterly out of place - // FIXME: Get this stuff out of here - it is utterly out of place - -public: - /** - * Helper class that calls startMultipleChanges() in its constructor - * and cares about the necessary call to doneMultipleChanges() when it goes - * out of scope. - **/ - class OptimizeChanges - { - public: - OptimizeChanges( YWidget & w ) : yw(w) { yw.startMultipleChanges(); } - ~OptimizeChanges() { yw.doneMultipleChanges(); } - private: - OptimizeChanges( const OptimizeChanges & ); // no copy - void operator=( const OptimizeChanges & ); // no assign - YWidget & yw; - }; + +#include "YWidget_OptimizeChanges.h" }; Added: branches/tmp/sh/mod-ui/core/libyui/src/YWidget_OptimizeChanges.h URL: http://svn.opensuse.org/viewcvs/yast/branches/tmp/sh/mod-ui/core/libyui/src/YWidget_OptimizeChanges.h?rev=39146&view=auto ============================================================================== --- branches/tmp/sh/mod-ui/core/libyui/src/YWidget_OptimizeChanges.h (added) +++ branches/tmp/sh/mod-ui/core/libyui/src/YWidget_OptimizeChanges.h Tue Jul 3 16:48:52 2007 @@ -0,0 +1,52 @@ +/*---------------------------------------------------------------------\ +| | +| __ __ ____ _____ ____ | +| \ \ / /_ _/ ___|_ _|___ \ | +| \ V / _` \___ \ | | __) | | +| | | (_| |___) || | / __/ | +| |_|\__,_|____/ |_| |_____| | +| | +| core system | +| (C) SuSE GmbH | +\----------------------------------------------------------------------/ + + File: YWidget_OptimizeChanges.h + + Author: Michael Andres <ma@suse.de> + +/-*/ + +#ifndef YWidget_OptimizeChanges_h +#define YWidget_OptimizeChanges_h + + +// Moved out of YWidget.h because it's really utterly out of place there. + +#ifndef YWidget_h +#error Do not include this file from anywhere outside YWidget.h! +#endif + +// class YWidget +// { + +public: + /** + * Helper class that calls startMultipleChanges() in its constructor + * and cares about the necessary call to doneMultipleChanges() when it goes + * out of scope. + **/ + class OptimizeChanges + { + public: + OptimizeChanges( YWidget & w ) : yw(w) { yw.startMultipleChanges(); } + ~OptimizeChanges() { yw.doneMultipleChanges(); } + private: + OptimizeChanges( const OptimizeChanges & ); // no copy + void operator=( const OptimizeChanges & ); // no assign + YWidget & yw; + }; + +// }; // class YWidget + + +#endif // YWidget_OptimizeChanges_h -- To unsubscribe, e-mail: yast-commit+unsubscribe@opensuse.org For additional commands, e-mail: yast-commit+help@opensuse.org
participants (1)
-
sh-sh-sh@svn.opensuse.org