blob: d20e7750f8e5f9e8f2e6129c33924bcb8e6ef15b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
diff -u -r libabiword-2.6.0.svn20071127.orig/src/wp/ap/unix/abiwidget.cpp libabiword-2.6.0.svn20071127/src/wp/ap/unix/abiwidget.cpp
--- libabiword-2.6.0.svn20071127.orig/src/wp/ap/unix/abiwidget.cpp 2007-11-24 20:19:03.000000000 +0100
+++ libabiword-2.6.0.svn20071127/src/wp/ap/unix/abiwidget.cpp 2008-03-22 21:42:22.000000000 +0100
@@ -890,6 +890,19 @@
{
case APF_ReplaceDocument:
UT_DEBUGMSG(("Replace document signalled\n"));
+ //
+ // Not sure what got broken for us to need this.
+ // Views should be deleted before their documents
+ // Nonetheless this fixes bug 11421 crash in sugar
+ // when changing document with a shared session.
+ //
+ //
+ if (m_pWidget->priv->m_pFrame->getCurrentView())
+ {
+ FV_View * pView = static_cast<FV_View *>(m_pWidget->priv->m_pFrame->getCurrentView());
+ m_pWidget->priv->m_pDoc = pView->getDocument();
+ }
+
break;
case APF_ReplaceView:
UT_DEBUGMSG(("Replace view signalled\n"));
|