diff options
author | Izik Eidus <ieidus@redhat.com> | 2009-10-25 14:15:10 +0200 |
---|---|---|
committer | Yaniv Kamay <ykamay@redhat.com> | 2009-10-25 20:15:41 +0200 |
commit | 48535714bfe126331c6eeaae220b4957d49c660a (patch) | |
tree | 8258c44745e09094b02b884d970bc1a949cd2988 | |
parent | 07c1a13fb32ccf0a01ef894d69ac95863813ed20 (diff) | |
download | spice-48535714bfe126331c6eeaae220b4957d49c660a.tar.gz spice-48535714bfe126331c6eeaae220b4957d49c660a.tar.xz spice-48535714bfe126331c6eeaae220b4957d49c660a.zip |
spice: move create and destroy of the canvas to new place
work around for xlib threaded bugs
Signed-off-by: Izik Eidus <ieidus@redhat.com>
-rw-r--r-- | client/display_channel.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/client/display_channel.cpp b/client/display_channel.cpp index 5412e7f2..5d3a7afd 100644 --- a/client/display_channel.cpp +++ b/client/display_channel.cpp @@ -59,7 +59,9 @@ public: virtual void do_responce(Application& application) { + _channel.destroy_canvas(); _channel.screen()->set_mode(_width, _height, _depth); + _channel.create_canvas(application.get_canvas_types(), _width, _height, _depth); } private: @@ -1061,7 +1063,6 @@ void DisplayChannel::handle_mode(RedPeer::InMessage* message) } } #endif - destroy_canvas(); AutoRef<SetModeEvent> event(new SetModeEvent(*this, mode->x_res, mode->y_res, mode->bits)); get_client().push_event(*event); @@ -1074,8 +1075,6 @@ void DisplayChannel::handle_mode(RedPeer::InMessage* message) _y_res = mode->y_res; _depth = mode->bits; - create_canvas(get_client().get_application().get_canvas_types(), _x_res, - _y_res, _depth); #ifdef USE_OGL if (_canvas->get_pixmap_type() == CANVAS_TYPE_GL) { screen()->set_update_interrupt_trigger(&_interrupt_update); |