本文整理汇总了C++中LLNotificationPtr::getDate方法的典型用法代码示例。如果您正苦于以下问题:C++ LLNotificationPtr::getDate方法的具体用法?C++ LLNotificationPtr::getDate怎么用?C++ LLNotificationPtr::getDate使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类LLNotificationPtr
的用法示例。
在下文中一共展示了LLNotificationPtr::getDate方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: onNewNotification
//static
bool LLGroupNotifyBox::onNewNotification(const LLSD& notify)
{
LLNotificationPtr notification = LLNotifications::instance().find(notify["id"].asUUID());
if (notification)
{
const LLSD& payload = notification->getPayload();
// Get the group data
LLGroupData group_data;
if (!gAgent.getGroupData(payload["group_id"].asUUID(),group_data))
{
llwarns << "Group notice for unkown group: " << payload["group_id"].asUUID() << llendl;
return false;
}
LLGroupNotifyBox* self;
self = new LLGroupNotifyBox(payload["subject"].asString(),
payload["message"].asString(),
payload["sender_name"].asString(),
payload["group_id"].asUUID(),
group_data.mInsigniaID,
group_data.mName,
notification->getDate(),
payload["inventory_offer"].isDefined(),
payload["inventory_name"].asString(),
payload["inventory_offer"]);
gNotifyBoxView->addChild(self);
}
return false;
}
示例2: update
bool LLNotificationChannelPanel::update(const LLSD& payload, bool passed_filter)
{
LLNotificationPtr notification = LLNotifications::instance().find(payload["id"].asUUID());
if (notification)
{
LLSD row;
row["columns"][0]["value"] = notification->getName();
row["columns"][0]["column"] = "name";
row["columns"][1]["value"] = notification->getMessage();
row["columns"][1]["column"] = "content";
row["columns"][2]["value"] = notification->getDate();
row["columns"][2]["column"] = "date";
row["columns"][2]["type"] = "date";
LLScrollListItem* sli = passed_filter ?
getChild<LLScrollListCtrl>("notifications_list")->addElement(row) :
getChild<LLScrollListCtrl>("notification_rejects_list")->addElement(row);
sli->setUserdata(&(*notification));
}
return false;
}
示例3: filterOldNotifications
bool GrowlManager::filterOldNotifications(LLNotificationPtr pNotification)
{
// *HACK: I don't see any better way to avoid getting old, persisted messages...
return (pNotification->getDate().secondsSinceEpoch() >= LLDate::now().secondsSinceEpoch() - 10);
}