46 #include <lcwindow.h> |
46 #include <lcwindow.h> |
47 #include <lcaudiocontrol.h> |
47 #include <lcaudiocontrol.h> |
48 #include <lcsession.h> |
48 #include <lcsession.h> |
49 #include <lczoomcontrol.h> |
49 #include <lczoomcontrol.h> |
50 #include <lccameracontrol.h> |
50 #include <lccameracontrol.h> |
|
51 #include <xqsettingsmanager.h> |
|
52 #include <xqsettingskey.h> |
|
53 #include <settingsinternalcrkeys.h> |
|
54 |
51 |
55 |
52 |
56 |
53 #define LC_VTPLUGIN_NAME "Videotelephony"; |
57 #define LC_VTPLUGIN_NAME "Videotelephony"; |
54 |
58 |
55 // ----------------------------------------------------------------------------- |
59 // ----------------------------------------------------------------------------- |
1415 // LcUiEnginePrivate::isAllowedToShareVideo |
1419 // LcUiEnginePrivate::isAllowedToShareVideo |
1416 // ----------------------------------------------------------------------------- |
1420 // ----------------------------------------------------------------------------- |
1417 // |
1421 // |
1418 bool LcUiEnginePrivate::isAllowedToShareVideo() |
1422 bool LcUiEnginePrivate::isAllowedToShareVideo() |
1419 { |
1423 { |
1420 LC_QDEBUG( "livecomms [UI] -> LcUiEnginePrivate::isAllowedToShareVideo()" ) |
1424 LC_QDEBUG( "livecomms [UI] -> LcUiEnginePrivate::isAllowedToShareVideo()" ) |
1421 if( featureSupported( CLcEngine::ELcSendVideoQuery ) && mShareOwnVideoQuery ){ |
1425 if (!featureSupported( CLcEngine::ELcSendVideoQuery )) //outgoing videocall |
1422 mShareOwnVideoQuery->show(); |
1426 return true; |
1423 return false; |
1427 else { //incoming videocall |
1424 } |
1428 int ownVtVideoSendingSetting = vtVideoSendingSetting(); |
|
1429 if (VTSETTING_SHOW_AUTOMATICALLY == ownVtVideoSendingSetting) |
|
1430 return true; |
|
1431 else if (VTSETTING_DO_NOT_SHOW == ownVtVideoSendingSetting) |
|
1432 return false; |
|
1433 else { |
|
1434 if (mShareOwnVideoQuery) |
|
1435 mShareOwnVideoQuery->show(); |
|
1436 return false; |
|
1437 } |
|
1438 } |
1425 LC_QDEBUG( "livecomms [UI] <- LcUiEnginePrivate::isAllowedToShareVideo()" ) |
1439 LC_QDEBUG( "livecomms [UI] <- LcUiEnginePrivate::isAllowedToShareVideo()" ) |
1426 return true; |
1440 } |
|
1441 |
|
1442 // ----------------------------------------------------------------------------- |
|
1443 // LcUiEnginePrivate::vtVideoSendingSetting |
|
1444 // ----------------------------------------------------------------------------- |
|
1445 // |
|
1446 int LcUiEnginePrivate::vtVideoSendingSetting() |
|
1447 { |
|
1448 LC_QDEBUG( "livecomms [UI] -> LcUiEnginePrivate::vtVideoSendingSetting()" ) |
|
1449 XQSettingsManager settings; |
|
1450 XQSettingsKey settingsKey(XQSettingsKey::TargetCentralRepository, |
|
1451 KCRUidTelephonySettings.iUid, |
|
1452 KSettingsVTVideoSending); |
|
1453 QVariant ownVtVideoSendingSetting = settings.readItemValue(settingsKey); |
|
1454 LC_QDEBUG( "livecomms [UI] <- LcUiEnginePrivate::vtVideoSendingSetting()" ) |
|
1455 return ownVtVideoSendingSetting.toInt(); |
1427 } |
1456 } |
1428 |
1457 |
1429 // ----------------------------------------------------------------------------- |
1458 // ----------------------------------------------------------------------------- |
1430 // LcUiEnginePrivate::stopLocalVideo |
1459 // LcUiEnginePrivate::stopLocalVideo |
1431 // ----------------------------------------------------------------------------- |
1460 // ----------------------------------------------------------------------------- |