equal
deleted
inserted
replaced
306 { |
306 { |
307 TX_ENTRY_ARGS( "Current name=" << currentName ); |
307 TX_ENTRY_ARGS( "Current name=" << currentName ); |
308 mPermanentData->mOriginalName = currentName; |
308 mPermanentData->mOriginalName = currentName; |
309 getText( hbTrId( "txt_mus_dialog_enter_name" ), |
309 getText( hbTrId( "txt_mus_dialog_enter_name" ), |
310 currentName, |
310 currentName, |
311 hbTrId( "txt_common_button_ok" ), //TODO:replace for "rename" when string is available |
311 hbTrId( "txt_mus_button_rename" ), |
312 SLOT( handleRenamePlaylistContainer( HbAction* ) ) ); |
312 SLOT( handleRenamePlaylistContainer( HbAction* ) ) ); |
313 TX_EXIT |
313 TX_EXIT |
314 } |
314 } |
315 |
315 |
316 /*! |
316 /*! |
320 { |
320 { |
321 TX_ENTRY_ARGS( "Current name=" << currentName ); |
321 TX_ENTRY_ARGS( "Current name=" << currentName ); |
322 mPermanentData->mOriginalName = currentName; |
322 mPermanentData->mOriginalName = currentName; |
323 getText( hbTrId( "txt_mus_dialog_enter_name" ), |
323 getText( hbTrId( "txt_mus_dialog_enter_name" ), |
324 currentName, |
324 currentName, |
325 hbTrId( "txt_common_button_ok" ),//TODO:replace for "rename" when string is available |
325 hbTrId( "txt_mus_button_rename" ), |
326 SLOT( handleRenamePlaylistItem( HbAction* ) ) ); |
326 SLOT( handleRenamePlaylistItem( HbAction* ) ) ); |
327 TX_EXIT |
327 TX_EXIT |
328 } |
328 } |
329 |
329 |
330 /*! |
330 /*! |
331 Request to select songs to add to the playlist |
331 Request to select songs to add to the playlist |
332 */ |
332 */ |
333 void MpCollectionPopupHandler::openAddSongsToPlaylist( QAbstractItemModel* model ) |
333 void MpCollectionPopupHandler::openAddSongsToPlaylist( QAbstractItemModel* model ) |
334 { |
334 { |
335 TX_ENTRY |
335 TX_ENTRY |
336 getModelIndexes( hbTrId( "txt_mus_title_select_songs" ),//TODO:replace for "add songs" when string is available |
336 getModelIndexes( hbTrId( "txt_mus_title_add_songs" ), |
337 hbTrId( "txt_common_button_add_dialog" ), |
337 hbTrId( "txt_common_button_add_dialog" ), |
338 model, |
338 model, |
339 SLOT( handleAddSongsToPlayList( HbAction* ) ) ); |
339 SLOT( handleAddSongsToPlayList( HbAction* ) ) ); |
340 TX_EXIT |
340 TX_EXIT |
341 } |
341 } |
349 MpCollectionTBoneListDataModel *model; |
349 MpCollectionTBoneListDataModel *model; |
350 model = new MpCollectionTBoneListDataModel( mMpEngine->collectionData() ); |
350 model = new MpCollectionTBoneListDataModel( mMpEngine->collectionData() ); |
351 //this item will be deleted when clearing permanent data. |
351 //this item will be deleted when clearing permanent data. |
352 model->setParent(mPermanentData); |
352 model->setParent(mPermanentData); |
353 model->refreshModel(); |
353 model->refreshModel(); |
354 getModelIndexes( hbTrId( "txt_mus_title_select_songs" ),//TODO:replace for "add songs" when string is available |
354 getModelIndexes( hbTrId( "txt_mus_title_add_songs" ), |
355 hbTrId( "txt_common_button_add_dialog" ), |
355 hbTrId( "txt_common_button_add_dialog" ), |
356 model, |
356 model, |
357 SLOT( handleAddSongsToPlayList( HbAction* ) ) ); |
357 SLOT( handleAddSongsToPlayList( HbAction* ) ) ); |
358 TX_EXIT |
358 TX_EXIT |
359 } |
359 } |
385 //this item will be deleted when clearing permanent data. |
385 //this item will be deleted when clearing permanent data. |
386 collectionDataModel->setParent( mPermanentData ); |
386 collectionDataModel->setParent( mPermanentData ); |
387 collectionDataModel->refreshModel(); |
387 collectionDataModel->refreshModel(); |
388 mPermanentData->mAbstractItemModel = collectionDataModel; |
388 mPermanentData->mAbstractItemModel = collectionDataModel; |
389 |
389 |
390 getModelIndexes( hbTrId( "txt_mus_title_select_songs" ),//TODO:replace for "add songs" when string is available |
390 getModelIndexes( hbTrId( "txt_mus_title_add_songs" ), |
391 hbTrId( "txt_common_button_add_dialog" ), |
391 hbTrId( "txt_common_button_add_dialog" ), |
392 collectionDataModel, |
392 collectionDataModel, |
393 SLOT( handleAddToCurrentPlaylist( HbAction* ) ) ); |
393 SLOT( handleAddToCurrentPlaylist( HbAction* ) ) ); |
394 TX_EXIT |
394 TX_EXIT |
395 } |
395 } |
748 |
748 |
749 if ( selectedAction && selectedAction->objectName() == KOk) { |
749 if ( selectedAction && selectedAction->objectName() == KOk) { |
750 QString newPlaylistName = dialog->value().toString(); |
750 QString newPlaylistName = dialog->value().toString(); |
751 //Store the new playlist name and query for the items to be added |
751 //Store the new playlist name and query for the items to be added |
752 mPermanentData->mOriginalName = newPlaylistName; |
752 mPermanentData->mOriginalName = newPlaylistName; |
753 getModelIndexes( hbTrId( "txt_mus_title_select_songs" ),//TODO:replace for "add songs" when string is available |
753 getModelIndexes( hbTrId( "txt_mus_title_add_songs" ), |
754 hbTrId( "txt_common_button_add_dialog" ), |
754 hbTrId( "txt_common_button_add_dialog" ), |
755 mPermanentData->mAbstractItemModel, |
755 mPermanentData->mAbstractItemModel, |
756 SLOT( handleCreateNewPlaylistGetModelIndexesFinished( HbAction* ) ) ); |
756 SLOT( handleCreateNewPlaylistGetModelIndexesFinished( HbAction* ) ) ); |
757 } |
757 } |
758 else { |
758 else { |