equal
deleted
inserted
replaced
73 } |
73 } |
74 |
74 |
75 void FmFindWidget::on_resultModel_finished() |
75 void FmFindWidget::on_resultModel_finished() |
76 { |
76 { |
77 emit finished(); |
77 emit finished(); |
78 //Since layout problem is found, refresh it |
|
79 on_resultModel_refresh(); |
|
80 } |
78 } |
81 |
79 |
82 void FmFindWidget::on_resultModel_modelCountChanged( int count ) |
80 void FmFindWidget::on_resultModel_modelCountChanged( int count ) |
83 { |
81 { |
84 if( count > 0 ) { |
82 if( count > 0 ) { |
138 connect( mModel, SIGNAL(finished()), this, SLOT( on_resultModel_finished()) ); |
136 connect( mModel, SIGNAL(finished()), this, SLOT( on_resultModel_finished()) ); |
139 |
137 |
140 connect( mModel, SIGNAL( modelCountChanged( int )), |
138 connect( mModel, SIGNAL( modelCountChanged( int )), |
141 this, SLOT( on_resultModel_modelCountChanged( int )) ); |
139 this, SLOT( on_resultModel_modelCountChanged( int )) ); |
142 |
140 |
143 connect( mModel, SIGNAL( refresh()), |
|
144 this, SLOT( on_resultModel_refresh()) ); |
|
145 |
|
146 mListView = new HbListView( this ); |
141 mListView = new HbListView( this ); |
147 mListView->setModel( mModel ); |
142 mListView->setModel( mModel ); |
148 |
143 |
149 mEmptyTipWidget = new HbWidget( this ); |
144 mEmptyTipWidget = new HbWidget( this ); |
150 QGraphicsLinearLayout *emptyTipLayout = new QGraphicsLinearLayout( mEmptyTipWidget ); |
145 QGraphicsLinearLayout *emptyTipLayout = new QGraphicsLinearLayout( mEmptyTipWidget ); |
202 mSearchPanel->hide(); |
197 mSearchPanel->hide(); |
203 mLayout->removeItem( mSearchPanel ); |
198 mLayout->removeItem( mSearchPanel ); |
204 |
199 |
205 } |
200 } |
206 |
201 |
207 void FmFindWidget::on_resultModel_refresh() |
202 |
208 { |
203 |
209 mListView->setModel( 0 ); |
|
210 mListView->setModel( mModel ); |
|
211 } |
|
212 |
|
213 |
|
214 |
|