Index: src/UIElements/Menu/TextMenu/TextMenu.hpp
===================================================================
--- src/UIElements/Menu/TextMenu/TextMenu.hpp	(revision b5b01e75eba142a4c305c63d6f27f45719579a8a)
+++ src/UIElements/Menu/TextMenu/TextMenu.hpp	(revision d649b7b2e188ba0fcc502541e95e742d7f2182da)
@@ -27,4 +27,5 @@
 #include "Actions/ActionQueue.hpp"
 #include "Actions/ActionTrait.hpp"
+#include "Menu/getLastPosition.hpp"
 #include "Menu/TextMenu/TxMenuLeaveAction.hpp"
 #include "Menu/TextMenu/ActionMenuItem.hpp"
@@ -53,5 +54,6 @@
     MenuInstance(new T(_outputter, _token)),
     outputter(_outputter),
-    deleteMenu(true)
+    deleteMenu(true),
+    lastposition(MoleCuilder::ActionQueue::getInstance().getListOfActions())
   {}
 
@@ -60,5 +62,6 @@
     MenuInstance(_MenuInstance),
     outputter(_MenuInstance->getOutputter()),
-    deleteMenu(false)
+    deleteMenu(false),
+    lastposition(MoleCuilder::ActionQueue::getInstance().getListOfActions())
   {}
 
@@ -110,4 +113,7 @@
   bool deleteMenu;
 
+  //!> internal functor to get last used position in menu of actions
+  getLastPosition lastposition;
+
   typedef std::map <char, std::string> MenuShortcutMap;
   MenuShortcutMap ShortcutMap;
@@ -148,5 +154,5 @@
         MoleCuilder::OptionTrait("leave"+token, &typeid(void), "leave menu "+token),
         token,
-        MoleCuilder::ActionQueue::getInstance().getLastPosition(token)+2); // have a separator in between
+        lastposition(token)+2); // have a separator in between
     new TxMenu::LeaveAction(NewMenu->getMenuInstance(), leaveTrait);
     NewMenu->init();
Index: src/UIElements/Menu/getLastPosition.cpp
===================================================================
--- src/UIElements/Menu/getLastPosition.cpp	(revision d649b7b2e188ba0fcc502541e95e742d7f2182da)
+++ src/UIElements/Menu/getLastPosition.cpp	(revision d649b7b2e188ba0fcc502541e95e742d7f2182da)
@@ -0,0 +1,63 @@
+/*
+ * Project: MoleCuilder
+ * Description: creates and alters molecular systems
+ * Copyright (C)  2013 Frederik Heber. All rights reserved.
+ *
+ *
+ *   This file is part of MoleCuilder.
+ *
+ *    MoleCuilder is free software: you can redistribute it and/or modify
+ *    it under the terms of the GNU General Public License as published by
+ *    the Free Software Foundation, either version 2 of the License, or
+ *    (at your option) any later version.
+ *
+ *    MoleCuilder is distributed in the hope that it will be useful,
+ *    but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *    GNU General Public License for more details.
+ *
+ *    You should have received a copy of the GNU General Public License
+ *    along with MoleCuilder.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+/*
+ * getLastPosition.cpp
+ *
+ *  Created on: Aug 20, 2013
+ *      Author: heber
+ */
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include "CodePatterns/MemDebug.hpp"
+
+#include "getLastPosition.hpp"
+
+#include "Actions/ActionQueue.hpp"
+#include "Actions/ActionTrait.hpp"
+
+getLastPosition::getLastPosition(const ActionTokens_t &_tokens) :
+  tokens(_tokens)
+{}
+
+getLastPosition::~getLastPosition()
+{}
+
+int getLastPosition::operator()(const std::string &menu) const
+{
+  int position = 0;
+  for (ActionTokens_t::const_iterator iter = tokens.begin(); iter != tokens.end(); ++iter) {
+    const MoleCuilder::ActionTrait &trait = MoleCuilder::ActionQueue::getInstance().getActionsTrait(*iter);
+    const std::string &MenuName = trait.getMenuName();
+    const int &MenuPosition = trait.getMenuPosition();
+    if ((MenuName == menu) && (position < MenuPosition))
+      position = MenuPosition;
+  }
+  return position;
+}
+
+
+
Index: src/UIElements/Menu/getLastPosition.hpp
===================================================================
--- src/UIElements/Menu/getLastPosition.hpp	(revision d649b7b2e188ba0fcc502541e95e742d7f2182da)
+++ src/UIElements/Menu/getLastPosition.hpp	(revision d649b7b2e188ba0fcc502541e95e742d7f2182da)
@@ -0,0 +1,41 @@
+/*
+ * getLastPosition.hpp
+ *
+ *  Created on: Aug 20, 2013
+ *      Author: heber
+ */
+
+#ifndef GETLASTPOSITION_HPP_
+#define GETLASTPOSITION_HPP_
+
+// include config.h
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
+#include <string>
+#include <vector>
+
+class getLastPosition
+{
+public:
+  //!> typedef for list of tokens
+  typedef std::vector<std::string> ActionTokens_t;
+
+  getLastPosition(const ActionTokens_t &tokens);
+  ~getLastPosition();
+
+  /** Returns the last present action position in the requested menu.
+   *
+   * \param &menu token of the menu
+   * \return last used position
+   */
+  int operator()(const std::string &menu) const;
+
+private:
+  //!> list of
+  ActionTokens_t tokens;
+};
+
+
+#endif /* GETLASTPOSITION_HPP_ */
