private static EditModeListener getListener(ContentNode node) {
   ContentElement e = node.asElement();
   return e.asElement() != null ? e.getProperty(EDIT_MODE_LISTENER_PROP) : null;
 }
 /**
  * Notify the node that the edit mode has changed.
  *
  * @param node
  * @param isEditing
  */
 public static void onEditModeChange(ContentNode node, boolean isEditing) {
   EditModeListener listener = getListener(node);
   if (node.asElement() != null && listener != null) {
     listener.onEditModeChange(node.asElement(), isEditing);
   }
 }