changeset 15775:a1d1386daeed

struct2hdl.m: Set the "*.mode" properties last. (Bug # 37645)
author Ben Abbott <bpabbott@mac.com>
date Wed, 12 Dec 2012 18:07:55 -0500
parents eddc68c5e85e
children 169a47c5e254
files scripts/plot/struct2hdl.m
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/plot/struct2hdl.m	Wed Dec 12 14:32:59 2012 -0800
+++ b/scripts/plot/struct2hdl.m	Wed Dec 12 18:07:55 2012 -0500
@@ -92,6 +92,14 @@
     p = p(1:2, 1:(tst(end)-1));
   endif
 
+  ## Place the "*mode" properties as the end to avoid have the updaters
+  ## change the mode to "manual" when the value is "auto"
+  names = fieldnames (s.properties);
+  n = strncmp (cellfun (@fliplr, names, "uniformoutput", false), "edom", 4);
+  n = (n | strcmp (names, "activepositionproperty"));
+  names = [names(!n); names(n)];
+  s.properties = orderfields (s.properties, names);
+
   ## create object
   if (strcmp (s.type, "root"))
     h = 0;