const SUIT_PreferenceMgr::PrefItemType type,
const QString& sect, const QString& param )
{
- QtxPreferenceItem* item = findItem( title, true );
+ QtxPreferenceItem* parent = pId == -1 ? this : findItem( pId, true );
+
+ if ( !parent )
+ return -1;
+
+ QtxPreferenceItem* item = parent->findItem( title, true );
+
if ( item )
return item->id();
- QtxPreferenceItem* parent = 0;
if ( pId == -1 )
{
if ( !myRoot )
myRoot = new QtxPagePrefListItem( QString( "root" ), this );
parent = myRoot;
}
- else
- parent = findItem( pId, true );
-
- if ( !parent )
- return -1;
switch( type )
{
case GroupBox:
item = new QtxPagePrefGroupItem( title, parent, sect, param );
break;
+ case Tab:
+ item = new QtxPagePrefTabsItem( title, parent, sect, param );
+ break;
+ case Frame:
+ item = new QtxPagePrefFrameItem( title, parent, sect, param );
+ break;
case Font:
item = new QtxPagePrefFontItem( title, parent, sect, param );
break;
public:
typedef enum { Auto, Space, Bool, Color, String, Selector,
DblSpin, IntSpin, Double, Integer,
- GroupBox, Font, DirList, File } PrefItemType;
+ GroupBox, Tab, Frame, Font, DirList, File } PrefItemType;
public:
SUIT_PreferenceMgr( QtxResourceMgr*, QWidget* = 0 );