#include <uMenu.h>
Public Member Functions | |
history_t (char const *filename) | |
this will load the history from the file | |
~history_t () | |
this will save the history to the file | |
Private Attributes | |
char const * | m_filename |
Definition at line 439 of file uMenu.h.
uMenuItemStringWithHistory::history_t::history_t | ( | char const * | filename | ) |
this will load the history from the file
filename | the name of the file (in var/) to be loaded and saved to |
Definition at line 1179 of file uMenu.cpp.
References tTextFileRecorder::EndOfFile(), tTextFileRecorder::GetLine(), m_filename, and tDirectories::Var().
01181 : std::deque<tString>(), m_filename(filename) { 01182 tTextFileRecorder the_file ( tDirectories::Var(), m_filename ); 01183 while(!the_file.EndOfFile()) { 01184 push_front(the_file.GetLine());
uMenuItemStringWithHistory::history_t::~history_t | ( | ) |
this will save the history to the file
Definition at line 1186 of file uMenu.cpp.
01188 { 01189 std::ofstream the_file; 01190 if(tDirectories::Var().Open( the_file, m_filename)) { 01191 for(reverse_iterator i = rbegin(); i != rend(); ++i) { 01192 the_file << *i << "\n"; 01193 }
char const* uMenuItemStringWithHistory::history_t::m_filename [private] |