Diffstat (limited to 'libopie/big-screen/omodalhelper.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | libopie/big-screen/omodalhelper.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libopie/big-screen/omodalhelper.cpp b/libopie/big-screen/omodalhelper.cpp index e3d1c70..c5a47b3 100644 --- a/libopie/big-screen/omodalhelper.cpp +++ b/libopie/big-screen/omodalhelper.cpp | |||
@@ -67,25 +67,25 @@ void OModalHelperControler::setTransactionID( TransactionID id ) { | |||
67 | QDialog* OModalHelperControler::dialog()const { | 67 | QDialog* OModalHelperControler::dialog()const { |
68 | return m_dia; | 68 | return m_dia; |
69 | } | 69 | } |
70 | 70 | ||
71 | /* | 71 | /* |
72 | * If we're in the New mode we will map the QDialog | 72 | * If we're in the New mode we will map the QDialog |
73 | * to the TransactionID | 73 | * to the TransactionID |
74 | */ | 74 | */ |
75 | void OModalHelperControler::done( int result ) { | 75 | void OModalHelperControler::done( int result ) { |
76 | if ( sender() && !sender()->isA("OModalQueuedDialog") ) | 76 | if ( sender() && !sender()->isA("OModalQueuedDialog") ) |
77 | m_dia = static_cast<QDialog*>( sender() ); | 77 | m_dia = static_cast<QDialog*>( sender() ); |
78 | 78 | ||
79 | m_base->done( m_id ); | 79 | m_base->done( result, m_id ); |
80 | } | 80 | } |
81 | 81 | ||
82 | void OModalHelperControler::next() { | 82 | void OModalHelperControler::next() { |
83 | m_base->next( m_id ); | 83 | m_base->next( m_id ); |
84 | } | 84 | } |
85 | 85 | ||
86 | void OModalHelperControler::prev() { | 86 | void OModalHelperControler::prev() { |
87 | m_base->prev( m_id ); | 87 | m_base->prev( m_id ); |
88 | } | 88 | } |
89 | 89 | ||
90 | /* The Queued Dialog inclusive QueuedBar */ | 90 | /* The Queued Dialog inclusive QueuedBar */ |
91 | struct OModalQueueBar : public QHBox { | 91 | struct OModalQueueBar : public QHBox { |
@@ -146,15 +146,20 @@ void OModalQueuedDialog::setQueueBarEnabled( bool b) { | |||
146 | m_bar->show(); | 146 | m_bar->show(); |
147 | else | 147 | else |
148 | m_bar->hide(); | 148 | m_bar->hide(); |
149 | } | 149 | } |
150 | 150 | ||
151 | void OModalQueuedDialog::setRecord( int record, int count ) { | 151 | void OModalQueuedDialog::setRecord( int record, int count ) { |
152 | if (!record && !count ) { | 152 | if (!record && !count ) { |
153 | hide(); | 153 | hide(); |
154 | return; | 154 | return; |
155 | }else | 155 | }else |
156 | show(); | 156 | show(); |
157 | 157 | ||
158 | if ( count > 1 ) | ||
159 | m_bar->show(); | ||
160 | else | ||
161 | m_bar->hide(); | ||
162 | |||
158 | m_bar->setText( tr("Editing record %1 out of %2", | 163 | m_bar->setText( tr("Editing record %1 out of %2", |
159 | "Shows the current edited record out of an array of records").arg( record ). arg( count ) ); | 164 | "Shows the current edited record out of an array of records").arg( record ). arg( count ) ); |
160 | } | 165 | } |