Esempio n. 1
0
        static void DrawEmptyState(
            Rect rect,
            bool isCheckedInSuccessful,
            PlasticNotification.Status notificationStatus,
            string notificationInfoText,
            string notificationActionText,
            Action notificationAction)
        {
            if (isCheckedInSuccessful)
            {
                DrawTreeViewEmptyState.For(
                    rect,
                    PlasticLocalization.GetString(PlasticLocalization.Name.CheckinCompleted),
                    Images.Name.StepOk);
                return;
            }

            if (notificationStatus != PlasticNotification.Status.None)
            {
                DrawTreeViewEmptyState.For(
                    rect,
                    PlasticLocalization.GetString(PlasticLocalization.Name.NoPendingChanges),
                    notificationInfoText,
                    notificationActionText,
                    Images.Name.IconOutOfSync,
                    notificationAction);
                return;
            }

            DrawTreeViewEmptyState.For(
                rect,
                PlasticLocalization.GetString(PlasticLocalization.Name.NoPendingChanges));
        }
Esempio n. 2
0
        static void DrawEmptyState(
            Rect rect,
            bool isCheckedInSuccessful)
        {
            if (isCheckedInSuccessful)
            {
                DrawTreeViewEmptyState.For(
                    rect,
                    PlasticLocalization.GetString(PlasticLocalization.Name.CheckinCompleted),
                    Images.Name.StepOk);
                return;
            }

            DrawTreeViewEmptyState.For(
                rect,
                PlasticLocalization.GetString(PlasticLocalization.Name.NoPendingChanges));
        }
Esempio n. 3
0
        static void DrawEmptyState(
            Rect rect,
            bool isUpdateSuccessful)
        {
            if (isUpdateSuccessful)
            {
                DrawTreeViewEmptyState.For(
                    rect,
                    PlasticLocalization.GetString(PlasticLocalization.Name.WorkspaceUpdateCompleted),
                    Images.Name.StepOk);

                return;
            }

            DrawTreeViewEmptyState.For(
                rect,
                PlasticLocalization.GetString(PlasticLocalization.Name.NoIncomingChanges));
        }
Esempio n. 4
0
        static void DoConflictsTree(
            IncomingChangesTreeView incomingChangesTreeView,
            bool isOperationRunning,
            bool hasNothingToDownload)
        {
            GUI.enabled = !isOperationRunning;

            Rect rect = GUILayoutUtility.GetRect(0, 100000, 0, 100000);

            incomingChangesTreeView.OnGUI(rect);

            if (hasNothingToDownload)
            {
                DrawTreeViewEmptyState.For(
                    rect,
                    PlasticLocalization.GetString(PlasticLocalization.Name.NoIncomingChanges),
                    PlasticLocalization.GetString(PlasticLocalization.Name.WorkspaceIsUpToDate),
                    Images.Name.StepOk);
            }

            GUI.enabled = true;
        }