|
|
@ -166,7 +166,7 @@ bool Resource::load( FormFile *ff )
|
|
|
|
TQFile f( ff->absFileName() );
|
|
|
|
TQFile f( ff->absFileName() );
|
|
|
|
f.open( IO_ReadOnly );
|
|
|
|
f.open( IO_ReadOnly );
|
|
|
|
|
|
|
|
|
|
|
|
bool b = load( ff, TQT_TQIODEVICE(&f) );
|
|
|
|
bool b = load( ff, &f );
|
|
|
|
f.close();
|
|
|
|
f.close();
|
|
|
|
|
|
|
|
|
|
|
|
return b;
|
|
|
|
return b;
|
|
|
@ -413,7 +413,7 @@ bool Resource::save( const TQString& filename, bool formCodeOnly )
|
|
|
|
TQFile f( filename );
|
|
|
|
TQFile f( filename );
|
|
|
|
if ( !f.open( IO_WriteOnly | IO_Translate ) )
|
|
|
|
if ( !f.open( IO_WriteOnly | IO_Translate ) )
|
|
|
|
return false;
|
|
|
|
return false;
|
|
|
|
bool b = save( TQT_TQIODEVICE(&f) );
|
|
|
|
bool b = save( &f );
|
|
|
|
f.close();
|
|
|
|
f.close();
|
|
|
|
return b;
|
|
|
|
return b;
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -1099,9 +1099,9 @@ void Resource::saveProperty( TQObject *w, const TQString &name, const TQVariant
|
|
|
|
num = value.toInt();
|
|
|
|
num = value.toInt();
|
|
|
|
if ( w && w->inherits( "TQLayout" ) ) {
|
|
|
|
if ( w && w->inherits( "TQLayout" ) ) {
|
|
|
|
if ( name == "spacing" )
|
|
|
|
if ( name == "spacing" )
|
|
|
|
num = MetaDataBase::spacing( WidgetFactory::containerOfWidget( WidgetFactory::layoutParent( TQT_TQLAYOUT(w) ) ) );
|
|
|
|
num = MetaDataBase::spacing( WidgetFactory::containerOfWidget( WidgetFactory::layoutParent( w ) ) );
|
|
|
|
else if ( name == "margin" )
|
|
|
|
else if ( name == "margin" )
|
|
|
|
num = MetaDataBase::margin( WidgetFactory::containerOfWidget( WidgetFactory::layoutParent( TQT_TQLAYOUT(w) ) ) );
|
|
|
|
num = MetaDataBase::margin( WidgetFactory::containerOfWidget( WidgetFactory::layoutParent( w ) ) );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
ts << makeIndent( indent ) << "<number>" << TQString::number( num ) << "</number>" << endl;
|
|
|
|
ts << makeIndent( indent ) << "<number>" << TQString::number( num ) << "</number>" << endl;
|
|
|
|
break;
|
|
|
|
break;
|
|
|
@ -1117,9 +1117,9 @@ void Resource::saveProperty( TQObject *w, const TQString &name, const TQVariant
|
|
|
|
unum = value.toUInt();
|
|
|
|
unum = value.toUInt();
|
|
|
|
if ( w && w->inherits( "TQLayout" ) ) {
|
|
|
|
if ( w && w->inherits( "TQLayout" ) ) {
|
|
|
|
if ( name == "spacing" )
|
|
|
|
if ( name == "spacing" )
|
|
|
|
num = MetaDataBase::spacing( WidgetFactory::layoutParent( TQT_TQLAYOUT(w) ) );
|
|
|
|
num = MetaDataBase::spacing( WidgetFactory::layoutParent( w ) );
|
|
|
|
else if ( name == "margin" )
|
|
|
|
else if ( name == "margin" )
|
|
|
|
num = MetaDataBase::margin( WidgetFactory::layoutParent( TQT_TQLAYOUT(w) ) );
|
|
|
|
num = MetaDataBase::margin( WidgetFactory::layoutParent( w ) );
|
|
|
|
}
|
|
|
|
}
|
|
|
|
ts << makeIndent( indent ) << "<number>" << TQString::number( unum ) << "</number>" << endl;
|
|
|
|
ts << makeIndent( indent ) << "<number>" << TQString::number( unum ) << "</number>" << endl;
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|