当前位置: 首页>>代码示例>>C++>>正文


C++ TCalTime::SetTimeLocalFloatingL方法代码示例

本文整理汇总了C++中TCalTime::SetTimeLocalFloatingL方法的典型用法代码示例。如果您正苦于以下问题:C++ TCalTime::SetTimeLocalFloatingL方法的具体用法?C++ TCalTime::SetTimeLocalFloatingL怎么用?C++ TCalTime::SetTimeLocalFloatingL使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在TCalTime的用法示例。


在下文中一共展示了TCalTime::SetTimeLocalFloatingL方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: SetCalTimeL

/**
  * Converts the TTime to TCalTime based on the time mode given
  @param aTimeData TTime variable to be set in the specified time mode
  @param aCalTimeData time that is set in the specified time mode
  @param aTimeMode time mode of the entry
  */
void CTestCalInterimApiSuiteStepBase::SetCalTimeL(const TTime& aTimeData, TCalTime& aCalTimeData, TCalTime::TTimeMode aTimeMode)
	{
	if(aTimeMode == TCalTime::EFloating)
		{
		aCalTimeData.SetTimeLocalFloatingL(aTimeData);
		}
	else if(aTimeMode == TCalTime::EFixedTimeZone)
		{
		aCalTimeData.SetTimeLocalL(aTimeData);
		}
	else
		{
		aCalTimeData.SetTimeUtcL(aTimeData);
		}
	}
开发者ID:cdaffara,项目名称:symbiandump-ossapps,代码行数:21,代码来源:TestCalInterimApiSuiteStepBase.cpp

示例2: NonRptEntryInstanceTimeL

TCalTime CCalInstanceIteratorUid::NonRptEntryInstanceTimeL(const CAgnSimpleEntry& aEntry)
	{	
	// The entry does not have a repeat rule so it is just a single instance
	TCalTime entryInstanceTime;
	if (aEntry.Type() == CCalEntry::ETodo)
		{
		TTime completionDate = aEntry.CompletedDateUtc();
		if (completionDate == Time::NullTTime())
			{
			if (!aEntry.EntryTime().IsSet())
				{
				entryInstanceTime = iUndatedTodoTime;
				}
			else
				{
				entryInstanceTime = CalUtils::TAgnCalendarTimeToTCalTimeL(aEntry.EntryTime());
				}
			}
		else
			{
			if (aEntry.TimeMode() == MAgnCalendarTimeMode::EFloating)
				{
				entryInstanceTime.SetTimeLocalFloatingL(AgnDateTime::ConvertToLocalTimeL(completionDate));
				}
			else
				{
				entryInstanceTime.SetTimeUtcL(completionDate);
				}
			}
		}
	else
		{
		entryInstanceTime = CalUtils::TAgnCalendarTimeToTCalTimeL(aEntry.EntryTime());
		}
	
	return entryInstanceTime;
	}
开发者ID:cdaffara,项目名称:symbiandump-ossapps,代码行数:37,代码来源:calinstanceiteratoruid.cpp

示例3: DeleteEntriesByTimeRangeL

/**
* Delete entries in the calendar file over a wider time Range
*/
void CTestCalInterimApiModifier::DeleteEntriesByTimeRangeL()
	{
	TPtrC timeMode;
	GetStringFromConfig(ConfigSection(), KFilterTimeMode, timeMode);

	TPtrC deleteFilterStartTime;
	GetStringFromConfig(ConfigSection(), KDeleteFilterStartTime, deleteFilterStartTime);
	TCalTime	calStartDateTime;

	if(deleteFilterStartTime != KNullDesC())
		{
		// Convert TPtrC to TTime
		TTime	startTTime;
		startTTime.Set(deleteFilterStartTime);

		if(!timeMode.Compare(KFilterTimeModeLocal))
			{
			calStartDateTime.SetTimeLocalL(startTTime);
			}
		else if (!timeMode.Compare(KFilterTimeModeLocalFloating))
			{
			calStartDateTime.SetTimeLocalFloatingL(startTTime);
			}
		else
			{
			calStartDateTime.SetTimeUtcL(startTTime);
			}
		}
	else
		{
		calStartDateTime.SetTimeLocalL(TCalTime::MinTime());
		}


	TCalTime	calEndDateTime;
	TPtrC  deleteFilterEndTime;
	GetStringFromConfig(ConfigSection(), KDeleteFilterEndTime, deleteFilterEndTime);

	if(deleteFilterEndTime != KNullDesC())
		{
		// Convert TPtrC to TTime
		TTime	endTTime;
		endTTime.Set(deleteFilterEndTime);

		if(!timeMode.Compare(KFilterTimeModeLocal))
			{
			calEndDateTime.SetTimeLocalL(endTTime);
			}
		else if (!timeMode.Compare(KFilterTimeModeLocalFloating))
			{
			calEndDateTime.SetTimeLocalFloatingL(endTTime);
			}
		else
			{
			calEndDateTime.SetTimeUtcL(endTTime);
			}
		}
	else
		{
		calEndDateTime.SetTimeLocalL(TCalTime::MaxTime());
		}

	CalCommon::TCalTimeRange	calTimeRange(calStartDateTime, calEndDateTime);
	TRAPD(err, iEntryView->DeleteL(calTimeRange, CalCommon::EIncludeAll, *this));
	CActiveScheduler::Start();

	if(err != KErrNone)
		{
		iTestStep->ERR_PRINTF2(KErrDeleteOperation,err);
		iTestStep->SetTestStepResult(EFail);
		}
	}
开发者ID:cdaffara,项目名称:symbiandump-ossapps,代码行数:75,代码来源:TestCalInterimApiModifier.cpp


注:本文中的TCalTime::SetTimeLocalFloatingL方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。