SVN commit 488736 by staniek: - possible crash fixed - minor GUI fixes; fixed broken slot M +6 -1 KoPageLayoutSize.cpp M +1 -0 KoPageLayoutSize.h M +6 -0 koPageLayoutDia.cc --- trunk/koffice/lib/kofficeui/KoPageLayoutSize.cpp #488735:488736 @@ -51,10 +51,11 @@ // combo unit cpgUnit = new QComboBox( false, unitFrame, "cpgUnit" ); + lpgUnit->setBuddy( cpgUnit ); cpgUnit->insertStringList( KoUnit::listOfUnitName() ); cpgUnit->setCurrentItem( unit ); unitLayout->addWidget( cpgUnit, 0, Qt::AlignLeft | Qt::AlignVCenter ); - connect( cpgUnit, SIGNAL( activated( int ) ), this, SLOT( setUnit( int ) ) ); + connect( cpgUnit, SIGNAL( activated( int ) ), this, SLOT( setUnitInt( int ) ) ); } else { QString str=KoUnit::unitDescription(unit); @@ -234,6 +235,10 @@ emit propertyChange(m_layout); } +void KoPageLayoutSize::setUnitInt( int unit ) { + setUnit((KoUnit::Unit)unit); +} + void KoPageLayoutSize::formatChanged( int format ) { if ( ( KoFormat )format == m_layout.format ) return; --- trunk/koffice/lib/kofficeui/KoPageLayoutSize.h #488735:488736 @@ -102,6 +102,7 @@ void topChanged( double ); void bottomChanged( double ); void orientationChanged( int ); + void setUnitInt( int unit ); private: void updatePreview(); --- trunk/koffice/lib/kofficeui/koPageLayoutDia.cc #488735:488736 @@ -139,6 +139,9 @@ flags = tabs; m_layout = layout; m_unit = unit; + m_pageSizeTab = 0; + m_columnsTab = 0; + m_headerTab = 0; m_column.columns = 1; @@ -164,6 +167,9 @@ m_layout = layout; m_column = columns; m_unit = unit; + m_pageSizeTab = 0; + m_columnsTab = 0; + m_headerTab = 0; if ( tabs & FORMAT_AND_BORDERS ) setupTab1( !( tabs & DISABLE_BORDERS ) ); if ( tabs & HEADER_AND_FOOTER ) setupTab2( hf );