equal
deleted
inserted
replaced
62 // --------------------------------------------------------------------------- |
62 // --------------------------------------------------------------------------- |
63 // |
63 // |
64 CCamPreCaptureViewBase::~CCamPreCaptureViewBase() |
64 CCamPreCaptureViewBase::~CCamPreCaptureViewBase() |
65 { |
65 { |
66 PRINT( _L("Camera => ~CCamPreCaptureViewBase") ); |
66 PRINT( _L("Camera => ~CCamPreCaptureViewBase") ); |
|
67 if ( iGestureFw ) |
|
68 { |
|
69 delete iGestureFw; |
|
70 } |
67 PRINT( _L("Camera <= ~CCamPreCaptureViewBase") ); |
71 PRINT( _L("Camera <= ~CCamPreCaptureViewBase") ); |
68 } |
72 } |
69 |
73 |
70 // ----------------------------------------------------------------------------- |
74 // ----------------------------------------------------------------------------- |
71 // CCamPreCaptureViewBase::HandleCommandL |
75 // CCamPreCaptureViewBase::HandleCommandL |
885 // |
889 // |
886 void CCamPreCaptureViewBase::ExitCaptureSetupModeL() |
890 void CCamPreCaptureViewBase::ExitCaptureSetupModeL() |
887 { |
891 { |
888 PRINT( _L("Camera => CCamPreCaptureViewBase::ExitCaptureSetupModeL") ) |
892 PRINT( _L("Camera => CCamPreCaptureViewBase::ExitCaptureSetupModeL") ) |
889 |
893 |
|
894 |
|
895 iController.SetViewfinderWindowHandle( &iContainer->Window() ); |
890 CCamCaptureSetupViewBase::ExitCaptureSetupModeL(); |
896 CCamCaptureSetupViewBase::ExitCaptureSetupModeL(); |
891 |
|
892 iController.SetViewfinderWindowHandle( &iContainer->Window() ); |
|
893 |
897 |
894 if( !iController.IsViewFinding() && !iController.InVideocallOrRinging() ) |
898 if( !iController.IsViewFinding() && !iController.InVideocallOrRinging() ) |
895 { |
899 { |
896 TCamCameraMode mode = iController.CurrentMode(); |
900 TCamCameraMode mode = iController.CurrentMode(); |
897 PRINT1( _L("Camera => CCamPreCaptureViewBase::ExitCaptureSetupModeL - CurrentMode %d"), mode ); |
901 PRINT1( _L("Camera => CCamPreCaptureViewBase::ExitCaptureSetupModeL - CurrentMode %d"), mode ); |
916 { |
920 { |
917 PRINT( _L("Camera => CCamPreCaptureViewBase::ExitCaptureSetupModeL ###") ) |
921 PRINT( _L("Camera => CCamPreCaptureViewBase::ExitCaptureSetupModeL ###") ) |
918 SwitchToCaptureSetupMenuModeL(); |
922 SwitchToCaptureSetupMenuModeL(); |
919 } |
923 } |
920 |
924 |
|
925 UpdateCbaL(); |
921 PRINT( _L("Camera <= CCamPreCaptureViewBase::ExitCaptureSetupModeL") ) |
926 PRINT( _L("Camera <= CCamPreCaptureViewBase::ExitCaptureSetupModeL") ) |
922 } |
927 } |
923 |
928 |
924 // --------------------------------------------------------------------------- |
929 // --------------------------------------------------------------------------- |
925 // CCamPreCaptureViewBase::ExitSceneSettingModeL |
930 // CCamPreCaptureViewBase::ExitSceneSettingModeL |
1761 void CCamPreCaptureViewBase::CreateContainerL() |
1766 void CCamPreCaptureViewBase::CreateContainerL() |
1762 { |
1767 { |
1763 PRINT( _L("Camera => CCamPreCaptureViewBase::CreateContainerL") ); |
1768 PRINT( _L("Camera => CCamPreCaptureViewBase::CreateContainerL") ); |
1764 |
1769 |
1765 // Create gesture fw object, set observer and gesture interest |
1770 // Create gesture fw object, set observer and gesture interest |
|
1771 if ( iGestureFw ) |
|
1772 { |
|
1773 delete iGestureFw; |
|
1774 } |
|
1775 |
1766 iGestureFw = CAknTouchGestureFw::NewL( *this, *iContainer ); |
1776 iGestureFw = CAknTouchGestureFw::NewL( *this, *iContainer ); |
1767 iGestureFw->SetGestureInterestL( EAknTouchGestureFwGroupPinch ); |
1777 iGestureFw->SetGestureInterestL( EAknTouchGestureFwGroupPinch | EAknTouchGestureFwGroupTap ); |
1768 |
1778 |
1769 PRINT( _L("Camera <= CCamPreCaptureViewBase::CreateContainerL") ); |
1779 PRINT( _L("Camera <= CCamPreCaptureViewBase::CreateContainerL") ); |
1770 } |
1780 } |
1771 |
1781 |
1772 // --------------------------------------------------------------------------- |
1782 // --------------------------------------------------------------------------- |
1777 void CCamPreCaptureViewBase::HandleTouchGestureL( MAknTouchGestureFwEvent& aEvent ) |
1787 void CCamPreCaptureViewBase::HandleTouchGestureL( MAknTouchGestureFwEvent& aEvent ) |
1778 { |
1788 { |
1779 PRINT( _L("Camera => CCamPreCaptureViewBase::HandleTouchGestureL") ); |
1789 PRINT( _L("Camera => CCamPreCaptureViewBase::HandleTouchGestureL") ); |
1780 |
1790 |
1781 // Skipped modes here |
1791 // Skipped modes here |
1782 if ( ( iController.ActiveCamera() == ECamActiveCameraSecondary ) || |
1792 if ( iController.ActiveCamera() == ECamActiveCameraSecondary ) |
1783 ( ECamNoOperation != iController.CurrentOperation() ) ) |
1793 { |
1784 { |
1794 PRINT( _L("Camera <= CCamPreCaptureViewBase::HandleTouchGestureL - skipped") ); |
1785 PRINT( _L("Camera <= CCamPreCaptureViewBase::HandleTouchGestureL") ); |
|
1786 return; |
1795 return; |
1787 } |
1796 } |
1788 |
1797 |
1789 MAknTouchGestureFwPinchEvent *pinch = AknTouchGestureFwEventPinch( aEvent ); |
1798 MAknTouchGestureFwPinchEvent *pinch = AknTouchGestureFwEventPinch( aEvent ); |
1790 if ( pinch ) |
1799 if ( pinch && (ECamNoOperation == iController.CurrentOperation()) ) |
1791 { |
1800 { |
1792 // Determine the direction of pinch: +ve -> pinch outward / zoom / widen VF |
1801 // Determine the direction of pinch: +ve -> pinch outward / zoom / widen VF |
1793 TInt currMove = pinch->Movement(); |
1802 TInt currMove = pinch->Movement(); |
1794 TBool wide = (currMove > 0) ? ETrue : EFalse; |
1803 TBool wide = (currMove > 0) ? ETrue : EFalse; |
1795 PRINT1( _L("Camera <> CCamPreCaptureViewBase::HandleTouchGestureL - pinch, movement:%d"), currMove ); |
1804 PRINT1( _L("Camera <> CCamPreCaptureViewBase::HandleTouchGestureL - pinch, movement:%d"), currMove ); |
1815 // if the quality level wasn't changed, then disable the blinking |
1824 // if the quality level wasn't changed, then disable the blinking |
1816 container->BlinkResolutionIndicatorOnChange( EFalse ); |
1825 container->BlinkResolutionIndicatorOnChange( EFalse ); |
1817 } |
1826 } |
1818 } |
1827 } |
1819 } |
1828 } |
|
1829 else if ( EAknTouchGestureFwDoubleTap == aEvent.Type() ) |
|
1830 { |
|
1831 PRINT( _L("Camera <> *** double tap event") ); |
|
1832 CCamAppUi* appUi = static_cast<CCamAppUi*>( iEikonEnv->AppUi() ); |
|
1833 CCamZoomPane *zoomPane = appUi->ZoomPane(); |
|
1834 |
|
1835 CCamPreCaptureContainerBase* container = static_cast<CCamPreCaptureContainerBase*>( iContainer ); |
|
1836 container->ShowZoomPaneWithTimer(); |
|
1837 |
|
1838 // Zoom to max (if not already at max) zoom level, otherwise zoom out to min level |
|
1839 if ( !zoomPane->IsZoomAtMaximum() ) |
|
1840 { |
|
1841 PRINT( _L("Camera <> Zooming to max level") ); |
|
1842 zoomPane->ZoomToMaximum(); |
|
1843 } |
|
1844 else |
|
1845 { |
|
1846 PRINT( _L("Camera <> Zooming out to min level") ); |
|
1847 zoomPane->ZoomToMinimum(); |
|
1848 } |
|
1849 } |
|
1850 else |
|
1851 { |
|
1852 PRINT1( _L("Camera <> HandleTouchGestureL - gesture not used, type:%d"), aEvent.Type() ); |
|
1853 } |
1820 |
1854 |
1821 PRINT( _L("Camera <= CCamPreCaptureViewBase::HandleTouchGestureL") ); |
1855 PRINT( _L("Camera <= CCamPreCaptureViewBase::HandleTouchGestureL") ); |
1822 } |
1856 } |
1823 |
1857 |
1824 // End of File |
1858 // End of File |