BrightSide Workbench Full Report + Source Code
org.turro.zkoss.wizard.Wizard Class Reference
Inheritance diagram for org.turro.zkoss.wizard.Wizard:
Collaboration diagram for org.turro.zkoss.wizard.Wizard:

Public Member Functions

void onOK ()
 
void onCancel ()
 
void onClick $wbprior ()
 
void onClick $wbnext ()
 
void onClick $wbfinish ()
 
void onClick $wbcancel ()
 
void nextPanel ()
 
void setPriorStatus (boolean enabled)
 
void setNextStatus (boolean enabled)
 
void setFinishStatus (boolean enabled)
 
void setCancelStatus (boolean enabled)
 
void doFinally () throws Exception
 

Protected Member Functions

void priorPanel ()
 
void updateWizard ()
 
void updateButtons ()
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 37 of file Wizard.java.

Member Function Documentation

◆ $wbcancel()

void onClick org.turro.zkoss.wizard.Wizard.$wbcancel ( )

Definition at line 77 of file Wizard.java.

77  {
78  WizardPanel wp = (WizardPanel) wizardbox.getSelectedPanel();
79  if(wp.doCancel()) {
80  Events.postEvent(new Event(Events.ON_CLOSE, self));
81  //self.detach();
82  }
83  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ $wbfinish()

void onClick org.turro.zkoss.wizard.Wizard.$wbfinish ( )

Definition at line 67 of file Wizard.java.

67  {
68  WizardPanel wp = (WizardPanel) wizardbox.getSelectedPanel();
69  if(wp.doLeave(true)) {
70  if(wp.doFinish()) {
71  Events.postEvent(new Event(Events.ON_CLOSE, self));
72  //self.detach();
73  }
74  }
75  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ $wbnext()

void onClick org.turro.zkoss.wizard.Wizard.$wbnext ( )

Definition at line 63 of file Wizard.java.

63  {
64  nextPanel();
65  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ $wbprior()

void onClick org.turro.zkoss.wizard.Wizard.$wbprior ( )

Definition at line 59 of file Wizard.java.

59  {
60  priorPanel();
61  }
Here is the call graph for this function:

◆ doFinally()

void org.turro.zkoss.wizard.Wizard.doFinally ( ) throws Exception

Definition at line 140 of file Wizard.java.

140  {
141  super.doFinally();
142  Caption caption = new Caption(null, "/_zul/images/wizard.png");
143  self.appendChild(caption);
144  wizardbox.setSclass("wizard");
145  wizardbox.setHflex("true");
146  wizardbox.setVflex("true");
147  wizardbox.getTabs().setSclass("wtabs");
148  for(Iterator it = wizardbox.getTabs().getChildren().iterator(); it.hasNext();) {
149  Tab tab = (Tab) it.next();
150  tab.setDisabled(true);
151  tab.setSclass("wizardtab");
152  }
153  new ComponentIterator<WizardPanel>(self) {
154  @Override
155  protected void doComponent(WizardPanel component) {
156  list.add(component);
157  }
158  };
159  list.getFirst().setAllowPrior(false);
160  list.getLast().setAllowNext(false);
161  updateWizard();
162  wbprior.setLabel(I_.get("<< Previous"));
163  wbnext.setLabel(I_.get("Next >>"));
164  wbfinish.setLabel(I_.get("Finish"));
165  wbcancel.setLabel(I_.get("Cancel"));
166  for(WizardPanel wp : list) {
167  if(!wp.shouldSkip && !wp.checkSkipFirst()) {
168  if(wp.doEnter()) {
169  wizardbox.setSelectedPanel(wp);
170  updateWizard();
171  break;
172  }
173  }
174  }
175  }
Here is the call graph for this function:

◆ nextPanel()

void org.turro.zkoss.wizard.Wizard.nextPanel ( )

Definition at line 104 of file Wizard.java.

104  {
105  int current = wizardbox.getSelectedIndex();
106  if(current > list.size() - 2) return;
107  WizardPanel wpcurrent = list.get(current);
108  if(wpcurrent.doLeave(true)) {
109  current++;
110  for(int i = current; i < list.size(); i++) {
111  WizardPanel wp = list.get(i);
112  if(!wp.isShouldSkip() && !wp.checkSkipFirst()) {
113  if(wp.doEnter()) {
114  wizardbox.setSelectedIndex(i);
115  updateWizard();
116  }
117  break;
118  }
119  }
120  }
121  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ onCancel()

void org.turro.zkoss.wizard.Wizard.onCancel ( )

Definition at line 52 of file Wizard.java.

52  {
53  WizardPanel wp = (WizardPanel) wizardbox.getSelectedPanel();
54  if(wp.isAllowCancel()) {
55  onClick$wbcancel();
56  }
57  }
void onClick $wbcancel()
Definition: Wizard.java:77
Here is the call graph for this function:

◆ onOK()

void org.turro.zkoss.wizard.Wizard.onOK ( )

Definition at line 43 of file Wizard.java.

43  {
44  WizardPanel wp = (WizardPanel) wizardbox.getSelectedPanel();
45  if(wp.isAllowNext()) {
46  onClick$wbnext();
47  } else if(wp.isAllowFinish()) {
48  onClick$wbfinish();
49  }
50  }
void onClick $wbnext()
Definition: Wizard.java:63
void onClick $wbfinish()
Definition: Wizard.java:67
Here is the call graph for this function:

◆ priorPanel()

void org.turro.zkoss.wizard.Wizard.priorPanel ( )
protected

Definition at line 85 of file Wizard.java.

85  {
86  int current = wizardbox.getSelectedIndex();
87  if(current < 1) return;
88  WizardPanel wpcurrent = list.get(current);
89  if(wpcurrent.doLeave(false)) {
90  current--;
91  for(int i = current; i >= 0; i--) {
92  WizardPanel wp = list.get(i);
93  if(!wp.isShouldSkip()) {
94  if(wp.doEnter()) {
95  wizardbox.setSelectedIndex(i);
96  updateWizard();
97  }
98  break;
99  }
100  }
101  }
102  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ setCancelStatus()

void org.turro.zkoss.wizard.Wizard.setCancelStatus ( boolean  enabled)

Definition at line 135 of file Wizard.java.

135  {
136  wbcancel.setDisabled(!enabled);
137  }
Here is the caller graph for this function:

◆ setFinishStatus()

void org.turro.zkoss.wizard.Wizard.setFinishStatus ( boolean  enabled)

Definition at line 131 of file Wizard.java.

131  {
132  wbfinish.setDisabled(!enabled);
133  }
Here is the caller graph for this function:

◆ setNextStatus()

void org.turro.zkoss.wizard.Wizard.setNextStatus ( boolean  enabled)

Definition at line 127 of file Wizard.java.

127  {
128  wbnext.setDisabled(!enabled);
129  }
Here is the caller graph for this function:

◆ setPriorStatus()

void org.turro.zkoss.wizard.Wizard.setPriorStatus ( boolean  enabled)

Definition at line 123 of file Wizard.java.

123  {
124  wbprior.setDisabled(!enabled);
125  }
Here is the caller graph for this function:

◆ updateButtons()

void org.turro.zkoss.wizard.Wizard.updateButtons ( )
protected

Definition at line 195 of file Wizard.java.

195  {
196  WizardPanel wp = (WizardPanel) wizardbox.getSelectedPanel();
197  setPriorStatus(wp.isAllowPrior());
198  setNextStatus(wp.isAllowNext());
199  setFinishStatus(wp.isAllowFinish());
200  setCancelStatus(wp.isAllowCancel());
201  }
void setNextStatus(boolean enabled)
Definition: Wizard.java:127
void setPriorStatus(boolean enabled)
Definition: Wizard.java:123
void setCancelStatus(boolean enabled)
Definition: Wizard.java:135
void setFinishStatus(boolean enabled)
Definition: Wizard.java:131
Here is the call graph for this function:
Here is the caller graph for this function:

◆ updateWizard()

void org.turro.zkoss.wizard.Wizard.updateWizard ( )
protected

Definition at line 177 of file Wizard.java.

177  {
178  WizardPanel wp = (WizardPanel) wizardbox.getSelectedPanel();
179  for(Iterator it = wizardbox.getTabs().getChildren().iterator(); it.hasNext();) {
180  Tab tab = (Tab) it.next();
181  if(tab.getIndex() < wp.getIndex()) {
182  tab.setSclass("wpdone");
183  } else if(tab.getIndex() == wp.getIndex()) {
184  tab.setSclass("wpcurrent");
185  } else {
186  tab.setSclass("wppending");
187  }
188  }
189  if(wp.isFinalSplash()) {
190  wbfinish.setLabel(I_.get("Close"));
191  }
192  updateButtons();
193  }
Here is the call graph for this function:
Here is the caller graph for this function:

The documentation for this class was generated from the following file: