コード例 #1
0
	bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata)
	{
		LLInventoryModel* model = mPtr->getPanel()->getModel();
		if(!model) return false;
		LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
		model->purgeDescendentsOf(trash_id);
		model->notifyObservers();
		return true;
	}
コード例 #2
0
	static void callback_empty_lost_and_found(S32 option, void* userdata)
	{
		LLEmptyLostAndFound* empty_lost_and_found = (LLEmptyLostAndFound*)userdata;
		if (option == 0) // YES
		{
			LLInventoryModel* model = empty_lost_and_found->mPtr->getModel();
			LLUUID lost_and_found_id = model->findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
			model->purgeDescendentsOf(lost_and_found_id);
			model->notifyObservers();
		}
	}
コード例 #3
0
	static void callback_empty_trash(S32 option, void* userdata)
	{
		LLEmptyTrash* empty_trash = (LLEmptyTrash*)userdata;
		if (option == 0) // YES
		{
			LLInventoryModel* model = empty_trash->mPtr->getModel();
			LLUUID trash_id = model->findCategoryUUIDForType(LLAssetType::AT_TRASH);
			model->purgeDescendentsOf(trash_id);
			model->notifyObservers();
		}
	}
コード例 #4
0
	bool callback_empty_lost_and_found(const LLSD& notification, const LLSD& response)
	{
		S32 option = LLNotification::getSelectedOption(notification, response);
		if (option == 0) // YES
		{
			LLInventoryModel* model = mPtr->getModel();
			LLUUID lost_and_found_id = model->findCategoryUUIDForType(LLAssetType::AT_LOST_AND_FOUND);
			model->purgeDescendentsOf(lost_and_found_id);
			model->notifyObservers();
		}
		return false;
	}
コード例 #5
0
	bool callback_empty_trash(const LLSD& notification, const LLSD& response)
	{
		S32 option = LLNotification::getSelectedOption(notification, response);
		if (option == 0) // YES
		{
			LLInventoryModel* model = mPtr->getModel();
			LLUUID trash_id = model->findCategoryUUIDForType(LLFolderType::FT_TRASH);
			model->purgeDescendentsOf(trash_id);
			model->notifyObservers();
		}
		return false;
	}