57 iListBox->CreateScrollBarFrameL( ETrue ); |
57 iListBox->CreateScrollBarFrameL( ETrue ); |
58 iListBox->ScrollBarFrame()->SetScrollBarVisibilityL( |
58 iListBox->ScrollBarFrame()->SetScrollBarVisibilityL( |
59 CEikScrollBarFrame::EOff, CEikScrollBarFrame::EAuto ); |
59 CEikScrollBarFrame::EOff, CEikScrollBarFrame::EAuto ); |
60 iListBox->SetObserver( this ); |
60 iListBox->SetObserver( this ); |
61 iListBox->SetListBoxObserver( this ); |
61 iListBox->SetListBoxObserver( this ); |
|
62 iListBox->SetMarkingModeObserver( this ); |
|
63 |
62 SetIndex( aFocusedIndex ); |
64 SetIndex( aFocusedIndex ); |
63 iListBox->SetFocus( ETrue ); |
65 iListBox->SetFocus( ETrue ); |
64 iListBox->AddSelectionObserverL( this ); |
66 iListBox->AddSelectionObserverL( this ); |
65 SetRect( aRect ); |
67 SetRect( aRect ); |
66 ActivateL(); |
68 ActivateL(); |
356 // ----------------------------------------------------------------------------- |
358 // ----------------------------------------------------------------------------- |
357 // CFileManagerContainerBase::ProcessCommandL |
359 // CFileManagerContainerBase::ProcessCommandL |
358 // |
360 // |
359 // ----------------------------------------------------------------------------- |
361 // ----------------------------------------------------------------------------- |
360 // |
362 // |
361 void CFileManagerContainerBase::ProcessCommandL( TInt aCommandId ) |
363 void CFileManagerContainerBase::ProcessCommandL( TInt /* aCommandId */ ) |
362 { |
364 { |
363 switch ( aCommandId ) |
365 } |
364 { |
366 |
365 case EAknSoftkeyShiftMSK: |
367 // ----------------------------------------------------------------------------- |
366 { |
368 // CFileManagerContainerBase::MarkingModeStatusChanged() |
367 static_cast< CAknAppUi* >( ControlEnv()->AppUi() )-> |
369 // |
368 ProcessCommandL( EFileManagerToggleMark ); |
370 // ----------------------------------------------------------------------------- |
369 break; |
371 // |
370 } |
372 void CFileManagerContainerBase::MarkingModeStatusChanged( TBool aActivated ) |
371 |
373 { |
372 default: |
374 // Set flag to indicate marking model is activated or not |
373 { |
375 iMarkingModeActivated = aActivated; |
374 break; |
376 } |
375 } |
377 |
376 } |
378 // ----------------------------------------------------------------------------- |
|
379 // CFileManagerContainerBase::ExitMarkingMode() |
|
380 // |
|
381 // ----------------------------------------------------------------------------- |
|
382 // |
|
383 TBool CFileManagerContainerBase::ExitMarkingMode() const |
|
384 { |
|
385 return iAllowMarkingModeExit; |
377 } |
386 } |
378 |
387 |
379 // ----------------------------------------------------------------------------- |
388 // ----------------------------------------------------------------------------- |
380 // CFileManagerContainerBase::SelectionModeChanged |
389 // CFileManagerContainerBase::SelectionModeChanged |
381 // |
390 // |
404 TBool CFileManagerContainerBase::SelectionModeEnabled() const |
413 TBool CFileManagerContainerBase::SelectionModeEnabled() const |
405 { |
414 { |
406 return iSelectionModeEnabled; |
415 return iSelectionModeEnabled; |
407 } |
416 } |
408 |
417 |
|
418 // ----------------------------------------------------------------------------- |
|
419 // CFileManagerContainerBase::IsMarkingModeActivated |
|
420 // |
|
421 // ----------------------------------------------------------------------------- |
|
422 // |
|
423 TBool CFileManagerContainerBase::IsMarkingModeActivated() const |
|
424 { |
|
425 return iMarkingModeActivated; |
|
426 } |
409 // ----------------------------------------------------------------------------- |
427 // ----------------------------------------------------------------------------- |
410 // CFileManagerContainerBase::UpdateCba |
428 // CFileManagerContainerBase::UpdateCba |
411 // |
429 // |
412 // ----------------------------------------------------------------------------- |
430 // ----------------------------------------------------------------------------- |
413 // |
431 // |
586 // |
604 // |
587 TInt CFileManagerContainerBase::SearchFieldToListBoxIndex( TInt aIndex ) |
605 TInt CFileManagerContainerBase::SearchFieldToListBoxIndex( TInt aIndex ) |
588 { |
606 { |
589 return 0; |
607 return 0; |
590 } |
608 } |
|
609 |
|
610 // ----------------------------------------------------------------------------- |
|
611 // CFileManagerContainerBase::AllowMarkingModeExit |
|
612 // |
|
613 // ----------------------------------------------------------------------------- |
|
614 // |
|
615 void CFileManagerContainerBase::AllowMarkingModeExit( TBool aAllowExit ) |
|
616 { |
|
617 iAllowMarkingModeExit = aAllowExit; |
|
618 } |
|
619 |
|
620 // ----------------------------------------------------------------------------- |
|
621 // CFileManagerContainerBase::SetMarkingMode |
|
622 // |
|
623 // ----------------------------------------------------------------------------- |
|
624 // |
|
625 void CFileManagerContainerBase::SetMarkingMode( TBool aEnable ) |
|
626 { |
|
627 iListBox->SetMarkingMode( aEnable ); |
|
628 } |
|
629 |
591 // End of File |
630 // End of File |