r21473 by jghali - #14334: "Unlink Text Frame and Cut Text" function inactive in certain cases

scribus-commit scribus-commit at lists.scribus.net
Fri Oct 28 09:09:24 UTC 2016


Author: jghali
Date: Fri Oct 28 09:09:24 2016
New Revision: 21473

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=21473
Log:
#14334: "Unlink Text Frame and Cut Text" function inactive in certain cases

Modified:
    trunk/Scribus/scribus/canvasmode_framelinks.cpp

Modified: trunk/Scribus/scribus/canvasmode_framelinks.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=21473&path=/trunk/Scribus/scribus/canvasmode_framelinks.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_framelinks.cpp	(original)
+++ trunk/Scribus/scribus/canvasmode_framelinks.cpp	Fri Oct 28 09:09:24 2016
@@ -172,6 +172,8 @@
 			currItem = m_doc->ElemToLink;
 			if (currItem==NULL)
 				break;
+			// #14334: delay selection signals so that (un)link actions get properly enabled/disabled
+			m_doc->m_Selection->delaySignalsOn();
 			SeleItem(m);
 			if (GetItem(&bb) && (bb->asTextFrame()))
 			{
@@ -263,10 +265,13 @@
 			}
 			else
 				m_doc->ElemToLink = NULL;
+			m_doc->m_Selection->delaySignalsOff();
 			break;
 		case modeUnlinkFrames:
 			if (m->button() != Qt::LeftButton)
 				break;
+			// #14334: delay selection signals so that (un)link actions get properly enabled/disabled
+			m_doc->m_Selection->delaySignalsOn();
 			SeleItem(m);
 			if (GetItem(&currItem) && (currItem->asTextFrame()))
 			{
@@ -277,6 +282,7 @@
 				// unlink calls PageItem::update				emit DocChanged();
 				// m_view->updateContents();
 			}
+			m_doc->m_Selection->delaySignalsOff();
 			break;
 	}
 }




More information about the scribus-commit mailing list