本文整理汇总了C++中TextureClient::ForceRemove方法的典型用法代码示例。如果您正苦于以下问题:C++ TextureClient::ForceRemove方法的具体用法?C++ TextureClient::ForceRemove怎么用?C++ TextureClient::ForceRemove使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TextureClient
的用法示例。
在下文中一共展示了TextureClient::ForceRemove方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: autoMon
// dispatched function
static void ImageBridgeShutdownStep1(ReentrantMonitor *aBarrier, bool *aDone)
{
ReentrantMonitorAutoEnter autoMon(*aBarrier);
MOZ_ASSERT(InImageBridgeChildThread(),
"Should be in ImageBridgeChild thread.");
MediaSystemResourceManager::Shutdown();
if (sImageBridgeChildSingleton) {
// Force all managed protocols to shut themselves down cleanly
InfallibleTArray<PCompositableChild*> compositables;
sImageBridgeChildSingleton->ManagedPCompositableChild(compositables);
for (int i = compositables.Length() - 1; i >= 0; --i) {
CompositableClient::FromIPDLActor(compositables[i])->Destroy();
}
InfallibleTArray<PTextureChild*> textures;
sImageBridgeChildSingleton->ManagedPTextureChild(textures);
for (int i = textures.Length() - 1; i >= 0; --i) {
TextureClient* client = TextureClient::AsTextureClient(textures[i]);
if (client) {
client->ForceRemove();
}
}
sImageBridgeChildSingleton->SendWillStop();
sImageBridgeChildSingleton->MarkShutDown();
// From now on, no message can be sent through the image bridge from the
// client side except the final Stop message.
}
*aDone = true;
aBarrier->NotifyAll();
}
示例2: ManagedPLayerChild
void
LayerTransactionChild::Destroy()
{
if (!IPCOpen()) {
return;
}
// mDestroyed is used to prevent calling Send__delete__() twice.
// When this function is called from CompositorChild::Destroy(),
// under Send__delete__() call, this function is called from
// ShadowLayerForwarder's destructor.
// When it happens, IPCOpen() is still true.
// See bug 1004191.
mDestroyed = true;
MOZ_ASSERT(0 == ManagedPLayerChild().Length(),
"layers should have been cleaned up by now");
for (size_t i = 0; i < ManagedPTextureChild().Length(); ++i) {
TextureClient* texture = TextureClient::AsTextureClient(ManagedPTextureChild()[i]);
if (texture) {
texture->ForceRemove();
}
}
SendShutdown();
}