r16194 by fschmid - Fixed Bug #9065: "Group flowaround"

scribus-commit scribus-commit at lists.scribus.net
Sat Jan 1 20:10:11 CET 2011


Author: fschmid
Date: Sat Jan  1 19:10:11 2011
New Revision: 16194

URL: http://scribus.info/websvn/listing.php?repname=Scribus&sc=1&rev=16194
Log:
Fixed Bug #9065: "Group flowaround"

Modified:
    branches/Version135/Scribus/scribus/propertiespalette.cpp

Modified: branches/Version135/Scribus/scribus/propertiespalette.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16194&path=/branches/Version135/Scribus/scribus/propertiespalette.cpp
==============================================================================
--- branches/Version135/Scribus/scribus/propertiespalette.cpp (original)
+++ branches/Version135/Scribus/scribus/propertiespalette.cpp Sat Jan  1 19:10:11 2011
@@ -1680,7 +1680,25 @@
 		return;
 	// fix for #5991: Property Palette text input box focus stays even when on another tab
 	// Disable widgets in all pages except current one - PV
-	bool enable;
+	foreach (QObject *o, TabStack->widget(t)->children())
+	{
+		// Layouts, boxes etc aren't widgets at all
+		// so let's skip them silently...
+		QWidget *w = qobject_cast<QWidget*>(o);
+		if (w)
+		{
+			QWidget *i = TabStack->widget(t);
+			while ((i = i->nextInFocusChain()) != TabStack->widget(t))
+			{
+				if (((i->focusPolicy() & Qt::TabFocus) == Qt::TabFocus) && !i->focusProxy() && i->isEnabled())
+				{
+					i->setFocus();
+					break;
+				}
+			}
+		}
+	}
+/*	bool enable;
 	for (int i = 0; i < TabStack->count(); ++i)
 	{
 		enable = (i == t);
@@ -1817,7 +1835,7 @@
 			KnockOut->setChecked(!CurItem->doOverprint);
 			Overprint->setChecked(CurItem->doOverprint);
 		}
-	}
+	} */
 }
 
 void PropertiesPalette::setDoc(ScribusDoc *d)




More information about the scribus-commit mailing list