From ba664af5f9718534a358acd8ae9be78aaef76865 Mon Sep 17 00:00:00 2001 From: "alex%croczilla.com" Date: Thu, 6 Sep 2007 10:14:41 +0000 Subject: [PATCH] Replace obsolete NS_STATIC_CAST() with static_cast<>. git-svn-id: svn://10.0.0.236/branches/ZAP_20050610_BRANCH@234034 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/zap/zmk/src/zapMediaGraph.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/mozilla/zap/zmk/src/zapMediaGraph.cpp b/mozilla/zap/zmk/src/zapMediaGraph.cpp index cf801d059ca..7dffc44b078 100644 --- a/mozilla/zap/zmk/src/zapMediaGraph.cpp +++ b/mozilla/zap/zmk/src/zapMediaGraph.cpp @@ -192,7 +192,7 @@ zapMediaGraph::ResolveNodeDescriptor(const nsACString& id_or_alias) NS_ASSERTION(t->type == Descriptor::NODE, "corrupt node list"); - return NS_STATIC_CAST(NodeDescriptor*, t); + return static_cast(t); } void @@ -216,8 +216,8 @@ zapMediaGraph::RemoveDescriptor(Descriptor* d) } if (d->type == Descriptor::NODE) { - RemoveNodeDescriptorConnections(NS_STATIC_CAST(NodeDescriptor*, d)); - NS_STATIC_CAST(NodeDescriptor*, d)->node->RemovedFromContainer(); + RemoveNodeDescriptorConnections(static_cast(d)); + static_cast(d)->node->RemovedFromContainer(); } delete d; } @@ -240,9 +240,9 @@ zapMediaGraph::RemoveNodeDescriptorConnections(NodeDescriptor* d) // search for connections pointing to d and remove them: Descriptor* p = mConnections; while((p = p->next)->type != Descriptor::SENTINEL) { - if (NS_STATIC_CAST(ConnectionDescriptor*, p)->src_nd == d || - NS_STATIC_CAST(ConnectionDescriptor*, p)->sink_nd == d) { - RemoveConnection(NS_STATIC_CAST(ConnectionDescriptor*, p)); + if (static_cast(p)->src_nd == d || + static_cast(p)->sink_nd == d) { + RemoveConnection(static_cast(p)); // restart from beginning, because the list might have changed. // this could be made more efficient, but our list should be // relatively small. @@ -472,7 +472,7 @@ zapMediaGraph::Disconnect(const nsACString & connection_id) t = t->next; } - RemoveConnection(NS_STATIC_CAST(ConnectionDescriptor*, t)); + RemoveConnection(static_cast(t)); return NS_OK; }