summaryrefslogtreecommitdiffstats
path: root/kate/app/kateviewspace.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <[email protected]>2012-05-23 18:20:09 -0500
committerTimothy Pearson <[email protected]>2012-05-23 18:20:09 -0500
commitde4e7b41598b4c8db0948e4c2c216d73e952f7bb (patch)
treeb8772c60b0b57c16d2e0055697ca95bff623d2eb /kate/app/kateviewspace.cpp
parentc281f8a59d6d1cc7d72d6fed23a11ee785988e1c (diff)
downloadtdebase-de4e7b41598b4c8db0948e4c2c216d73e952f7bb.tar.gz
tdebase-de4e7b41598b4c8db0948e4c2c216d73e952f7bb.zip
Add support to Kate for saving/restoring manual document placement
Make absolutely sure that kdesktop_lock reads recently changed configuration files when starting up
Diffstat (limited to 'kate/app/kateviewspace.cpp')
-rw-r--r--kate/app/kateviewspace.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/kate/app/kateviewspace.cpp b/kate/app/kateviewspace.cpp
index 4df741fdf..73ca6a097 100644
--- a/kate/app/kateviewspace.cpp
+++ b/kate/app/kateviewspace.cpp
@@ -244,7 +244,7 @@ void KateViewSpace::saveConfig ( KConfig* config, int myIndex ,const TQString& v
if (currentView())
config->writeEntry( "Active View", currentView()->getDoc()->url().prettyURL() );
- // Save file list, includeing cursor position in this instance.
+ // Save file list, including cursor position in this instance.
TQPtrListIterator<Kate::View> it(mViewList);
int idx = 0;
@@ -252,8 +252,9 @@ void KateViewSpace::saveConfig ( KConfig* config, int myIndex ,const TQString& v
{
if ( !it.current()->getDoc()->url().isEmpty() )
{
+ long docListPos = it.current()->getDoc()->documentListPosition();
config->setGroup( group );
- config->writeEntry( TQString("View %1").arg( idx ), it.current()->getDoc()->url().prettyURL() );
+ config->writeEntry( TQString("View %1").arg( (docListPos<0)?idx:docListPos ), it.current()->getDoc()->url().prettyURL() );
// view config, group: "ViewSpace <n> url"
TQString vgroup = TQString("%1 %2").arg(group).arg(it.current()->getDoc()->url().prettyURL());