Class defining all Publish declarations associated with the WixUI_Common dialogs. This class is used as a starting point for UI customization with injection of CLR Dialog (WinForms).
Inheritance: CustomUI
Example #1
0
        public static CustomUI InjectPostLicenseClrDialog(string showAction, string clrDialogGoNextCondition = null)
        {
            var customUI   = new CommomDialogsUI();
            var prevDialog = NativeDialogs.LicenseAgreementDlg;
            var nextDialog = NativeDialogs.InstallDirDlg;

            //disconnect prev and next dialogs
            customUI.UISequence.RemoveAll(x => (x.Dialog == prevDialog && x.Control == Buttons.Next) ||
                                          (x.Dialog == nextDialog && x.Control == Buttons.Back));

            //create new dialogs connection with showAction in between
            customUI.On(prevDialog, Buttons.Next, new ExecuteCustomAction(showAction));
            customUI.On(prevDialog, Buttons.Next, new ShowDialog(nextDialog, Condition.ClrDialog_NextPressed + " AND " + (clrDialogGoNextCondition ?? "\"1\"")));
            customUI.On(prevDialog, Buttons.Next, new CloseDialog("Exit", Condition.ClrDialog_CancelPressed)
            {
                Order = 2
            });

            customUI.On(nextDialog, Buttons.Back, new ExecuteCustomAction(showAction));
            customUI.On(nextDialog, Buttons.Back, new ShowDialog(prevDialog, Condition.ClrDialog_BackPressed));

            return(customUI);
        }
Example #2
0
        public static CustomUI InjectPostLicenseClrDialog(string showAction, string clrDialogGoNextCondition = null)
        {
            var customUI = new CommomDialogsUI();
            var prevDialog = NativeDialogs.LicenseAgreementDlg;
            var nextDialog = NativeDialogs.InstallDirDlg;

            //disconnect prev and next dialogs
            customUI.UISequence.RemoveAll(x => (x.Dialog == prevDialog && x.Control == Buttons.Next) ||
                                             (x.Dialog == nextDialog && x.Control == Buttons.Back));

            //create new dialogs connection with showAction in between
            customUI.On(prevDialog, Buttons.Next, new ExecuteCustomAction(showAction));
            customUI.On(prevDialog, Buttons.Next, new ShowDialog(nextDialog, Condition.ClrDialog_NextPressed + " AND " + (clrDialogGoNextCondition ?? "\"1\"")));
            customUI.On(prevDialog, Buttons.Next, new CloseDialog("Exit", Condition.ClrDialog_CancelPressed) { Order = 2 });

            customUI.On(nextDialog, Buttons.Back, new ExecuteCustomAction(showAction));
            customUI.On(nextDialog, Buttons.Back, new ShowDialog(prevDialog, Condition.ClrDialog_BackPressed));

            return customUI;
        }