summaryrefslogtreecommitdiff
path: root/gtk2_ardour
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2010-04-05 17:38:54 +0000
committerCarl Hetherington <carl@carlh.net>2010-04-05 17:38:54 +0000
commitad5bcfaa0bde60a12d5a1a7512bfcb9479e69829 (patch)
tree2b9f6935e8693adca40f32510d90060000f40816 /gtk2_ardour
parent60158fd2b47107bfc2663ad06c5a30eb96780177 (diff)
Save and restore the selected tab and its width in the editor list.
git-svn-id: svn://localhost/ardour2/branches/3.0@6860 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour')
-rw-r--r--gtk2_ardour/editor.cc13
1 files changed, 13 insertions, 0 deletions
diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc
index 730b6e0fab..70a3c047b8 100644
--- a/gtk2_ardour/editor.cc
+++ b/gtk2_ardour/editor.cc
@@ -2399,6 +2399,13 @@ Editor::set_state (const XMLNode& node, int /*version*/)
}
}
+ if ((prop = node.property (X_("editor-list-page")))) {
+ the_notebook.set_current_page (atoi (prop->value ()));
+ }
+
+ if ((prop = node.property (X_("editor-pane-position")))) {
+ edit_pane.set_position (atoi (prop->value ()));
+ }
return 0;
}
@@ -2482,6 +2489,12 @@ Editor::get_state ()
node->add_property (X_("show-editor-list"), tact->get_active() ? "yes" : "no");
}
+ snprintf (buf, sizeof (buf), "%d", the_notebook.get_current_page ());
+ node->add_property (X_("editor-list-page"), buf);
+
+ snprintf (buf, sizeof (buf), "%d", edit_pane.get_position ());
+ node->add_property (X_("editor-pane-position"), buf);
+
return *node;
}