- Temporarily solve synchronization problem. A more correct

and complete solution is of course using a mutex.


git-svn-id: svn://svn.gna.org/svn/sgpemv2/trunk@397 3ecf2c5c-341e-0410-92b4-d18e462d057c
This commit is contained in:
tchernobog 2006-02-23 12:12:43 +00:00
parent ec5d813a7c
commit 1a1c9b943a
2 changed files with 6 additions and 6 deletions

View File

@ -89,9 +89,9 @@ uint
GraphicalTerminalIO::write_buffer(const Glib::ustring& buffer) GraphicalTerminalIO::write_buffer(const Glib::ustring& buffer)
{ {
Gtk::TextBuffer::iterator i = _text_output.get_buffer()->end(); Gtk::TextBuffer::iterator i = _text_output.get_buffer()->end();
_text_output.get_buffer()->insert( i, buffer); _text_output.get_buffer()->insert(i, buffer);
i = _text_output.get_buffer()->end(); i = _text_output.get_buffer()->end();
_text_output.scroll_to(i); //_text_output.scroll_to(i); // would need a mutex!
return buffer.size(); return buffer.size();
} }

View File

@ -58,10 +58,10 @@ namespace sgpem {
void onSend(); void onSend();
private: private:
TextSimulation* _sim; TextSimulation* _sim;
Gtk::TextView _text_output; Gtk::TextView _text_output;
mutable Gtk::Entry _text_input; mutable Gtk::Entry _text_input;
Gtk::Button* _send; Gtk::Button* _send;
}; };
} }