Selecting an element which has another element as direct child
<p>I need to select all <code>div</code>s which contain <code>object</code> as their direct child. <code>:has</code> just checks for descendants of any kind, so now I'm using:</p>

<pre><code>$('div &gt; object').parent().css('text-align', 'center');
</code></pre>

<p>is there a more direct way?</p>
