From: stv Date: Mon, 30 Oct 2006 12:46:35 +0000 (+0000) Subject: Method rgbSet() modified. X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=f8f41171c4cc95d72f7e43976fa84b7307992061;p=modules%2Fgui.git Method rgbSet() modified. --- diff --git a/src/Qtx/Qtx.cxx b/src/Qtx/Qtx.cxx index de0b55f3c..ae3cb9d02 100755 --- a/src/Qtx/Qtx.cxx +++ b/src/Qtx/Qtx.cxx @@ -502,11 +502,11 @@ int Qtx::rgbSet( const int r, const int g, const int b ) Name: rgbSet [static public] Desc: Unpack the specified integer RGB set into the color. */ -void Qtx::rgbSet( const int rgb, QColor& c ) +QColor Qtx::rgbSet( const int rgb ) { int r, g, b; rgbSet( rgb, r, g, b ); - c = QColor( r, g, b ); + return QColor( r, g, b ); } /*! diff --git a/src/Qtx/Qtx.h b/src/Qtx/Qtx.h index 0d5cb3a40..976893f5f 100755 --- a/src/Qtx/Qtx.h +++ b/src/Qtx/Qtx.h @@ -46,6 +46,7 @@ #define INCLUDE_MENUITEM_DEF #endif +#include #include #ifndef QT_VERSION @@ -129,7 +130,7 @@ public: static int rgbSet( const QColor& ); static int rgbSet( const int, const int, const int ); - static void rgbSet( const int, QColor& ); + static QColor rgbSet( const int ); static void rgbSet( const int, int&, int&, int& ); static QColor scaleColor( const int, const int, const int ); diff --git a/src/Qtx/QtxResourceMgr.cxx b/src/Qtx/QtxResourceMgr.cxx index 02b3a1c65..c659c7b19 100644 --- a/src/Qtx/QtxResourceMgr.cxx +++ b/src/Qtx/QtxResourceMgr.cxx @@ -1086,7 +1086,7 @@ bool QtxResourceMgr::value( const QString& sect, const QString& name, QColor& cV { int pack = val.toInt( &res ); if ( res ) - Qtx::rgbSet( pack, cVal ); + cVal = Qtx::rgbSet( pack ); } return res;