Automatic cache clearing when reordering custom element type I've developed a custom menus plugin which has been working great

https://github.com/familiar-studio/craft-menus

Im trying to get it work with the build in template caching and realizing the reorder actions are not triggering the caches to clear properly?

The template is using the "getNodes(menuHandle)" variable
https://github.com/familiar-studio/craft-menus/blob/master/menus/variables/MenusVariable.php

which just uses standard element criteria? We are also using native structures so is there some way to specifically tell it to clear on reordering as well?

UPDATE: here is the code thats in my _layout that im hoping will clear when i reorder or add new elements

{% cache %}
  &lt;ul class="nav navbar-nav navbar-right"&gt;
      {% nav node in craft.menus.getNodes('utilityMenu') %}
         &lt;li class="{{ node.children|length ? 'dropdown' }}
            {{ node.active ? 'active' }}"&gt;

            &lt;a href="{{node.link}}"
                {% if node.children|length %}
                   class="dropdown-toggle" data-toggle="dropdown"
                {% endif %}&gt;

                {{ node.title }}
            &lt;/a&gt;

            {% ifchildren %}

                &lt;ul class="dropdown-menu" role="menu"&gt;
                    &lt;div class="arrow"&gt;&lt;/div&gt;
                    {% children %}
                &lt;/ul&gt;

            {% endifchildren %}
        &lt;/li&gt;
     {% endnav %}
&lt;/ul&gt;


{% endcache %}

UPDATE 2: So on deeper investivation it appears that the issue is only that it doesnt clear the cache when the structure is reordered, editing and saving nodes seems to clear it after all.
So i found an answer, was a little more manual but it works. 

I added a call back to the onMoveElement to automatically more manually clear the cache.  This was added to my plugins init() function

craft()-&gt;structures-&gt;onMoveElement = function(Event $event) {
      $element = $event-&gt;params['element'];
      craft()-&gt;templateCache-&gt;deleteCachesByElementId($element['id']);
};


Was interesting to me that i only had to do this for reordering sturctures while adding/deleting elements automatically cleared the cache with no event code.

Not sure if this was a bug or by design?