This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

View | Details | Raw Unified | Return to bug 46606
Collapse All | Expand All

(-)core/windows/src/org/netbeans/core/windows/persistence/GroupParser.java (-8 / +2 lines)
Lines 47-54 Link Here
47
    /** Local parent folder */
47
    /** Local parent folder */
48
    private FileObject localParentFolder;
48
    private FileObject localParentFolder;
49
    
49
    
50
    private PropertyHandler propertyHandler;
51
    
52
    private InternalConfig internalConfig;
50
    private InternalConfig internalConfig;
53
    
51
    
54
    private Map tcGroupParserMap = new HashMap(19);
52
    private Map tcGroupParserMap = new HashMap(19);
Lines 87-95 Link Here
87
    
85
    
88
    private void readProperties (GroupConfig sc) throws IOException {
86
    private void readProperties (GroupConfig sc) throws IOException {
89
        if (DEBUG) Debug.log(GroupParser.class, "readProperties ENTER" + " group:" + getName());
87
        if (DEBUG) Debug.log(GroupParser.class, "readProperties ENTER" + " group:" + getName());
90
        if (propertyHandler == null) {
88
        PropertyHandler propertyHandler = new PropertyHandler();
91
            propertyHandler = new PropertyHandler();
92
        }
93
        InternalConfig internalCfg = getInternalConfig();
89
        InternalConfig internalCfg = getInternalConfig();
94
        internalCfg.clear();
90
        internalCfg.clear();
95
        propertyHandler.readData(sc, internalCfg);
91
        propertyHandler.readData(sc, internalCfg);
Lines 236-244 Link Here
236
    
232
    
237
    private void writeProperties (GroupConfig sc) throws IOException {
233
    private void writeProperties (GroupConfig sc) throws IOException {
238
        if (DEBUG) Debug.log(GroupParser.class, "writeProperties ENTER" + " group:" + getName());
234
        if (DEBUG) Debug.log(GroupParser.class, "writeProperties ENTER" + " group:" + getName());
239
        if (propertyHandler == null) {
235
        PropertyHandler propertyHandler = new PropertyHandler();
240
            propertyHandler = new PropertyHandler();
241
        }
242
        InternalConfig internalCfg = getInternalConfig();
236
        InternalConfig internalCfg = getInternalConfig();
243
        propertyHandler.writeData(sc, internalCfg);
237
        propertyHandler.writeData(sc, internalCfg);
244
        if (DEBUG) Debug.log(GroupParser.class, "writeProperties LEAVE" + " group:" + getName());
238
        if (DEBUG) Debug.log(GroupParser.class, "writeProperties LEAVE" + " group:" + getName());
(-)core/windows/src/org/netbeans/core/windows/persistence/ModeParser.java (-8 / +2 lines)
Lines 67-74 Link Here
67
    /** Local parent folder */
67
    /** Local parent folder */
68
    private FileObject localParentFolder;
68
    private FileObject localParentFolder;
69
    
69
    
70
    private PropertyHandler propertyHandler;
71
    
72
    private InternalConfig internalConfig;
70
    private InternalConfig internalConfig;
73
    
71
    
74
    /** Map of TCRefParser instances. Used for fast access. */
72
    /** Map of TCRefParser instances. Used for fast access. */
Lines 113-121 Link Here
113
    
111
    
114
    private void readProperties (ModeConfig mc) throws IOException {
112
    private void readProperties (ModeConfig mc) throws IOException {
115
        if (DEBUG) Debug.log(ModeParser.class, "readProperties ENTER" + " mo:" + getName());
113
        if (DEBUG) Debug.log(ModeParser.class, "readProperties ENTER" + " mo:" + getName());
116
        if (propertyHandler == null) {
114
        PropertyHandler propertyHandler = new PropertyHandler();
117
            propertyHandler = new PropertyHandler();
118
        }
119
        InternalConfig internalCfg = getInternalConfig();
115
        InternalConfig internalCfg = getInternalConfig();
120
        internalCfg.clear();
116
        internalCfg.clear();
121
        propertyHandler.readData(mc, internalCfg);
117
        propertyHandler.readData(mc, internalCfg);
Lines 340-348 Link Here
340
    
336
    
341
    private void writeProperties (ModeConfig mc) throws IOException {
337
    private void writeProperties (ModeConfig mc) throws IOException {
342
        if (DEBUG) Debug.log(ModeParser.class, "writeProperties ENTER" + " mo:" + getName());
338
        if (DEBUG) Debug.log(ModeParser.class, "writeProperties ENTER" + " mo:" + getName());
343
        if (propertyHandler == null) {
339
        PropertyHandler propertyHandler = new PropertyHandler();
344
            propertyHandler = new PropertyHandler();
345
        }
346
        InternalConfig internalCfg = getInternalConfig();
340
        InternalConfig internalCfg = getInternalConfig();
347
        propertyHandler.writeData(mc, internalCfg);
341
        propertyHandler.writeData(mc, internalCfg);
348
        if (DEBUG) Debug.log(ModeParser.class, "writeProperties LEAVE" + " mo:" + getName());
342
        if (DEBUG) Debug.log(ModeParser.class, "writeProperties LEAVE" + " mo:" + getName());
(-)core/windows/src/org/netbeans/core/windows/persistence/TCGroupParser.java (-8 / +2 lines)
Lines 48-55 Link Here
48
    /** Local parent folder */
48
    /** Local parent folder */
49
    private FileObject localParentFolder;
49
    private FileObject localParentFolder;
50
    
50
    
51
    private PropertyHandler propertyHandler;
52
    
53
    private InternalConfig internalConfig;
51
    private InternalConfig internalConfig;
54
    
52
    
55
    /** true if wstcgrp file is present in module folder */
53
    /** true if wstcgrp file is present in module folder */
Lines 65-73 Link Here
65
    TCGroupConfig load () throws IOException {
63
    TCGroupConfig load () throws IOException {
66
        if (DEBUG) Debug.log(TCGroupParser.class, "load ENTER" + " tcGrp:" + tc_id);
64
        if (DEBUG) Debug.log(TCGroupParser.class, "load ENTER" + " tcGrp:" + tc_id);
67
        TCGroupConfig tcGroupCfg = new TCGroupConfig();
65
        TCGroupConfig tcGroupCfg = new TCGroupConfig();
68
        if (propertyHandler == null) {
66
        PropertyHandler propertyHandler = new PropertyHandler();
69
            propertyHandler = new PropertyHandler();
70
        }
71
        InternalConfig internalCfg = getInternalConfig();
67
        InternalConfig internalCfg = getInternalConfig();
72
        internalCfg.clear();
68
        internalCfg.clear();
73
        propertyHandler.readData(tcGroupCfg, internalCfg);
69
        propertyHandler.readData(tcGroupCfg, internalCfg);
Lines 78-86 Link Here
78
    /** Save tcGroup configuration. */
74
    /** Save tcGroup configuration. */
79
    void save (TCGroupConfig tcGroupCfg) throws IOException {
75
    void save (TCGroupConfig tcGroupCfg) throws IOException {
80
        if (DEBUG) Debug.log(TCGroupParser.class, "save ENTER" + " tcGrp:" + tc_id);
76
        if (DEBUG) Debug.log(TCGroupParser.class, "save ENTER" + " tcGrp:" + tc_id);
81
        if (propertyHandler == null) {
77
        PropertyHandler propertyHandler = new PropertyHandler();
82
            propertyHandler = new PropertyHandler();
83
        }
84
        InternalConfig internalCfg = getInternalConfig();
78
        InternalConfig internalCfg = getInternalConfig();
85
        propertyHandler.writeData(tcGroupCfg, internalCfg);
79
        propertyHandler.writeData(tcGroupCfg, internalCfg);
86
        if (DEBUG) Debug.log(TCGroupParser.class, "save LEAVE" + " tcGrp:" + tc_id);
80
        if (DEBUG) Debug.log(TCGroupParser.class, "save LEAVE" + " tcGrp:" + tc_id);
(-)core/windows/src/org/netbeans/core/windows/persistence/TCRefParser.java (-8 / +2 lines)
Lines 52-59 Link Here
52
    /** Local parent folder */
52
    /** Local parent folder */
53
    private FileObject localParentFolder;
53
    private FileObject localParentFolder;
54
    
54
    
55
    private PropertyHandler propertyHandler;
56
    
57
    private InternalConfig internalConfig;
55
    private InternalConfig internalConfig;
58
    
56
    
59
    /** true if wstcref file is present in module folder */
57
    /** true if wstcref file is present in module folder */
Lines 69-77 Link Here
69
    TCRefConfig load () throws IOException {
67
    TCRefConfig load () throws IOException {
70
        if (DEBUG) Debug.log(TCRefParser.class, "load ENTER" + " tcRef:" + tc_id);
68
        if (DEBUG) Debug.log(TCRefParser.class, "load ENTER" + " tcRef:" + tc_id);
71
        TCRefConfig tcRefCfg = new TCRefConfig();
69
        TCRefConfig tcRefCfg = new TCRefConfig();
72
        if (propertyHandler == null) {
70
        PropertyHandler propertyHandler = new PropertyHandler();
73
            propertyHandler = new PropertyHandler();
74
        }
75
        InternalConfig internalCfg = getInternalConfig();
71
        InternalConfig internalCfg = getInternalConfig();
76
        internalCfg.clear();
72
        internalCfg.clear();
77
        propertyHandler.readData(tcRefCfg, internalCfg);
73
        propertyHandler.readData(tcRefCfg, internalCfg);
Lines 82-90 Link Here
82
    /** Save tcref configuration. */
78
    /** Save tcref configuration. */
83
    void save (TCRefConfig tcRefCfg) throws IOException {
79
    void save (TCRefConfig tcRefCfg) throws IOException {
84
        if (DEBUG) Debug.log(TCRefParser.class, "save ENTER" + " tcRef:" + tc_id);
80
        if (DEBUG) Debug.log(TCRefParser.class, "save ENTER" + " tcRef:" + tc_id);
85
        if (propertyHandler == null) {
81
        PropertyHandler propertyHandler = new PropertyHandler(); // XXX cut off  writing from property handler
86
            propertyHandler = new PropertyHandler();
87
        }
88
        InternalConfig internalCfg = getInternalConfig();
82
        InternalConfig internalCfg = getInternalConfig();
89
        propertyHandler.writeData(tcRefCfg, internalCfg);
83
        propertyHandler.writeData(tcRefCfg, internalCfg);
90
        if (DEBUG) Debug.log(TCRefParser.class, "save LEAVE" + " tcRef:" + tc_id);
84
        if (DEBUG) Debug.log(TCRefParser.class, "save LEAVE" + " tcRef:" + tc_id);
(-)core/windows/src/org/netbeans/core/windows/persistence/WindowManagerParser.java (-8 / +2 lines)
Lines 58-65 Link Here
58
    
58
    
59
    private PersistenceManager pm;
59
    private PersistenceManager pm;
60
    
60
    
61
    private PropertyHandler propertyHandler;
62
    
63
    private InternalConfig internalConfig;
61
    private InternalConfig internalConfig;
64
    
62
    
65
    private Map modeParserMap = new HashMap(19);
63
    private Map modeParserMap = new HashMap(19);
Lines 322-330 Link Here
322
    
320
    
323
    private void readProperties (WindowManagerConfig wmc) throws IOException {
321
    private void readProperties (WindowManagerConfig wmc) throws IOException {
324
        if (DEBUG) Debug.log(WindowManagerParser.class, "readProperties ENTER");
322
        if (DEBUG) Debug.log(WindowManagerParser.class, "readProperties ENTER");
325
        if (propertyHandler == null) {
323
        PropertyHandler propertyHandler = new PropertyHandler();
326
            propertyHandler = new PropertyHandler();
327
        }
328
        internalConfig = new InternalConfig();
324
        internalConfig = new InternalConfig();
329
        propertyHandler.readData(wmc, internalConfig);
325
        propertyHandler.readData(wmc, internalConfig);
330
        if (DEBUG) Debug.log(WindowManagerParser.class, "readProperties LEAVE");
326
        if (DEBUG) Debug.log(WindowManagerParser.class, "readProperties LEAVE");
Lines 573-581 Link Here
573
    
569
    
574
    private void writeProperties (WindowManagerConfig wmc) throws IOException {
570
    private void writeProperties (WindowManagerConfig wmc) throws IOException {
575
        if (DEBUG) Debug.log(WindowManagerParser.class, "writeProperties ENTER");
571
        if (DEBUG) Debug.log(WindowManagerParser.class, "writeProperties ENTER");
576
        if (propertyHandler == null) {
572
        PropertyHandler propertyHandler = new PropertyHandler();
577
            propertyHandler = new PropertyHandler();
578
        }
579
        propertyHandler.writeData(wmc);
573
        propertyHandler.writeData(wmc);
580
        if (DEBUG) Debug.log(WindowManagerParser.class, "writeProperties LEAVE");
574
        if (DEBUG) Debug.log(WindowManagerParser.class, "writeProperties LEAVE");
581
    }
575
    }

Return to bug 46606