tinyMCE - Check which tab is currently selected
<p>Does tinyMCE have a function to check the currently active tab between "Visual" and "Text"? I have external buttons that add source into the textarea..</p>

<pre><code>tinyMCE.execInstanceCommand("template-source","mceInsertRawHTML", false, $(select).val());
</code></pre>

<p>This function only adds text to the "Visual" tab, but not the source. I want to be able to add HTML source to the textarea regardless of which tab is currently selected..</p>
