Example #1
0
        public bool ContinueWithPendingChanges()
        {
            bool result = false;

            GUIActionRunner.RunGUIAction(() =>
            {
                result = ConfirmContinueWithPendingChangesDialog.ConfirmContinue(
                    mTitle,
                    mExplanation,
                    mViewSwitcher,
                    mParentWindow);
            });

            return(result);
        }
Example #2
0
        internal static bool ConfirmContinue(
            string title,
            string explanation,
            IViewSwitcher viewSwitcher,
            EditorWindow parentWindow)
        {
            ConfirmContinueWithPendingChangesDialog dialog = Create(
                title,
                explanation,
                viewSwitcher);

            if (dialog.RunModal(parentWindow) != ResponseType.Ok)
            {
                return(false);
            }

            if (dialog.mIsSwitchToConfirmationChecked)
            {
                SavePreference();
            }

            return(true);
        }