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.

Bug 123410 - Designer recomputes layout unnecessarily
Summary: Designer recomputes layout unnecessarily
Status: RESOLVED FIXED
Alias: None
Product: obsolete
Classification: Unclassified
Component: visualweb (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Peter Zavadsky
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2007-12-05 00:31 UTC by Quy Nguyen
Modified: 2008-01-16 19:15 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Quy Nguyen 2007-12-05 00:31:55 UTC
It appears that the visual designer recomputes page layouts in JsfTopComponent.designerShowing() when it may not be 
needed.  This occurs when the user has not made any modifications and switches to a page from another page or from the 
java/jsp tab to the design window.  Since this layout computation may take several seconds, depending on the 
complexity of the page, avoiding this could provide performance benefits.
Comment 1 Peter Zavadsky 2007-12-05 17:30:43 UTC
I need to investigate this. I know there is this recomputation. I think it is because when the designer is not selected
it doesn't listen on changes on model, and this way assures the changes are reflected. It seems this architecture is not
correct. There should be listening on the changes, and if they didn't happen, no relayout should be processed.
Comment 2 Peter Zavadsky 2008-01-16 19:15:30 UTC
Fixed, according to Sandip's advice (to check the state of the model).

Checking in visualweb/designer/jsf/src/org/netbeans/modules/visualweb/designer/jsf/JsfForm.java;
/cvs/visualweb/designer/jsf/src/org/netbeans/modules/visualweb/designer/jsf/JsfForm.java,v  <--  JsfForm.java
new revision: 1.105; previous revision: 1.104
done
Checking in visualweb/designer/jsf/src/org/netbeans/modules/visualweb/designer/jsf/ui/JsfTopComponent.java;
/cvs/visualweb/designer/jsf/src/org/netbeans/modules/visualweb/designer/jsf/ui/JsfTopComponent.java,v  <-- 
JsfTopComponent.java
new revision: 1.57; previous revision: 1.56
done