From 80ca159b47f5923466301bc9a5f5e042c1c47ca1 Mon Sep 17 00:00:00 2001 From: Alexander Volkov Date: Fri, 12 Sep 2014 17:49:59 +0400 Subject: Fix saving handle width in QSplitter::saveState() QSplitter::handleWidth() returns either a style dependent value if d->handleWidth is negative or the value of d->handleWidth itself. So to preserve this choice after calling saveState()/restoreState() we should save and restore the value of d->handleWidth rather than a result of handleWidth() which is non-negative. Change-Id: Idc11f8063d34b6c4a5f9b0a0032868679766dfb9 Reviewed-by: Marc Mutz --- src/widgets/widgets/qsplitter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/widgets/widgets/qsplitter.cpp') diff --git a/src/widgets/widgets/qsplitter.cpp b/src/widgets/widgets/qsplitter.cpp index 1f29af319a..9713af1a7a 100644 --- a/src/widgets/widgets/qsplitter.cpp +++ b/src/widgets/widgets/qsplitter.cpp @@ -1609,7 +1609,7 @@ QByteArray QSplitter::saveState() const } stream << list; stream << childrenCollapsible(); - stream << qint32(handleWidth()); + stream << qint32(d->handleWidth); stream << opaqueResize(); stream << qint32(orientation()); stream << d->opaqueResizeSet; -- cgit v1.2.3