equal
deleted
inserted
replaced
1532 static_cast <MCameraUIOrientationOverride*>( |
1532 static_cast <MCameraUIOrientationOverride*>( |
1533 iCamera->CustomInterface( KCameraUIOrientationOverrideUid ) ); |
1533 iCamera->CustomInterface( KCameraUIOrientationOverrideUid ) ); |
1534 #endif // CAMERAAPP_CAE_FOR_VIDEO |
1534 #endif // CAMERAAPP_CAE_FOR_VIDEO |
1535 |
1535 |
1536 PRINT1( _L("Camera <> OrientationOverride custom i/f pointer:%d"), iCustomInterfaceUIOrientationOverride ); |
1536 PRINT1( _L("Camera <> OrientationOverride custom i/f pointer:%d"), iCustomInterfaceUIOrientationOverride ); |
1537 iCustomInterfaceUIOrientationOverride->SetOrientationModeL( aOrientation ); |
1537 TRAP_IGNORE(iCustomInterfaceUIOrientationOverride->SetOrientationModeL( aOrientation )); |
1538 |
1538 |
1539 PRINT( _L("Camera <= CCamCameraController::SetOrientationModeL") ); |
1539 PRINT( _L("Camera <= CCamCameraController::SetOrientationModeL") ); |
1540 } |
1540 } |
1541 |
1541 |
1542 // --------------------------------------------------------------------------- |
1542 // --------------------------------------------------------------------------- |
2414 CheckNonNullL( iCustomInterfaceOrientation, KErrNotSupported ); |
2414 CheckNonNullL( iCustomInterfaceOrientation, KErrNotSupported ); |
2415 MCameraOrientation::TOrientation |
2415 MCameraOrientation::TOrientation |
2416 orientation( MCameraOrientation::EOrientation0 ); |
2416 orientation( MCameraOrientation::EOrientation0 ); |
2417 iSettingProvider.ProvideCameraSettingL( aSettingId, &orientation ); |
2417 iSettingProvider.ProvideCameraSettingL( aSettingId, &orientation ); |
2418 |
2418 |
|
2419 if ( iInfo.iCurrentCamera != KPrimaryCameraIndex && |
|
2420 orientation == MCameraOrientation::EOrientation90 ) |
|
2421 { |
|
2422 PRINT( _L("Camera <> Rotate portrait secondary camera image 270 degrees") ); |
|
2423 orientation = MCameraOrientation::EOrientation270; |
|
2424 } |
|
2425 |
2419 PRINT1( _L("Camera <> setting camera orientation to [0x%02x]"), orientation ); |
2426 PRINT1( _L("Camera <> setting camera orientation to [0x%02x]"), orientation ); |
2420 iCustomInterfaceOrientation->SetOrientationL( orientation ); |
2427 iCustomInterfaceOrientation->SetOrientationL( orientation ); |
2421 break; |
2428 break; |
2422 } |
2429 } |
2423 // ------------------------------- |
2430 // ------------------------------- |
2526 { |
2533 { |
2527 CheckFlagOffL( iInfo.iState, ECamReserved, KErrInUse ); |
2534 CheckFlagOffL( iInfo.iState, ECamReserved, KErrInUse ); |
2528 |
2535 |
2529 CAMERAAPP_PERF_CONTROLLER_START( ECamRequestReserve ); |
2536 CAMERAAPP_PERF_CONTROLLER_START( ECamRequestReserve ); |
2530 iCamera->Reserve(); |
2537 iCamera->Reserve(); |
|
2538 // If UIOrientationOverrideAPI is used, ui construction is completed while |
|
2539 // waiting for Reserve to complete, event sent here to continue ui construction |
|
2540 CCamAppUi* appUi = static_cast<CCamAppUi*>( CEikonEnv::Static()->AppUi() ); |
|
2541 if ( appUi->AppController().UiConfigManagerPtr()->IsUIOrientationOverrideSupported() ) |
|
2542 { |
|
2543 NotifyObservers( KErrNone, |
|
2544 ECamCameraEventReserveRequested, |
|
2545 ECamCameraEventClassBasicControl ); |
|
2546 } |
2531 } |
2547 } |
2532 // ------------------------------------------------------- |
2548 // ------------------------------------------------------- |
2533 // Power on |
2549 // Power on |
2534 else if( ECamRequestPowerOn == aRequestId ) |
2550 else if( ECamRequestPowerOn == aRequestId ) |
2535 { |
2551 { |
2537 CheckFlagOffL( iInfo.iState, ECamPowerOn, KErrInUse ); |
2553 CheckFlagOffL( iInfo.iState, ECamPowerOn, KErrInUse ); |
2538 |
2554 |
2539 CAMERAAPP_PERF_CONTROLLER_START( ECamRequestPowerOn ); |
2555 CAMERAAPP_PERF_CONTROLLER_START( ECamRequestPowerOn ); |
2540 |
2556 |
2541 iCamera->PowerOn(); |
2557 iCamera->PowerOn(); |
2542 CCamAppUi* appUi = static_cast<CCamAppUi*>( CEikonEnv::Static()->AppUi() ); |
|
2543 if ( appUi->AppController().UiConfigManagerPtr()->IsUIOrientationOverrideSupported() ) |
|
2544 { |
|
2545 NotifyObservers( KErrNone, |
|
2546 ECamCameraEventPowerOnRequested, |
|
2547 ECamCameraEventClassBasicControl ); |
|
2548 } |
|
2549 |
|
2550 } |
2558 } |
2551 // ------------------------------------------------------- |
2559 // ------------------------------------------------------- |
2552 // Unknown |
2560 // Unknown |
2553 else |
2561 else |
2554 { |
2562 { |