我有一个相当复杂的安装程序,我在Wix中编写了很多基于您正在安装的组件的自定义对话框选项。一般来说,默认情况很好,因此无人值守的安装会成功,但具有这种自定义功能会有所帮助。Wix UI条件最佳实践
我想知道的是,Wix中做UI条件的最佳实践是什么?我注意到,维克斯评估所有<Publish>
标签,无论是否不是最后一个被评估为真,这是导致很多这样的代码:
<Publish Dialog="Questions" Control="Next" Event="NewDialog" Value="Component1Questions" Order="1">INSTALLCOMPONENT1</Publish>
<Publish Dialog="Questions" Control="Next" Event="NewDialog" Value="Component2Questions" Order="2">NOT INSTALLCOMPONENT1 AND INSTALLCOMPONENT2</Publish>
<Publish Dialog="Questions" Control="Next" Event="NewDialog" Value="Component3Questions" Order="3">NOT INSTALLCOMPONENT1 AND NOT INSTALLCOMPONENT2 AND INSTALLCOMPONENT3</Publish>
<Publish Dialog="Questions" Control="Next" Event="NewDialog" Value="VerifyReadyDlg" Order="4">NOT INSTALLCOMPONENT1 AND NOT INSTALLCOMPONENT2 AND NOT INSTALLCOMPONENT3</Publish>
而且同样也在“后退”节每个对话框都有这个最佳实践吗?有没有一种方法可以对Publish元素进行短路评估,并将第一个元素返回true?
逻辑更简单但稍微不正确。如果我想安装所有3个组件,在这种情况下,下一个按钮将不起作用。 – Jeff 2009-06-25 20:14:45