void BuildComponents()
        {
            mOpenSubmenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen));
            mOpenMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    string.Format("{0} {1}",
                                  PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                                  GetPlasticShortcut.ForOpen())));
            mOpenWithMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpenWith)));
            mOpenInExplorerMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    PlasticLocalization.GetString(PlasticLocalization.Name.OpenInExplorerMenuItem)));
            mOpenMetaMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    PlasticLocalization.GetString(PlasticLocalization.Name.OpenMeta)));
            mOpenMetaWithMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    PlasticLocalization.GetString(PlasticLocalization.Name.OpenMetaWith)));
            mOpenMetaInExplorerMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    PlasticLocalization.GetString(PlasticLocalization.Name.OpenMetaInExplorer)));
            mDiffMenuItemContent = new GUIContent(string.Format("{0} {1}",
                                                                PlasticLocalization.GetString(PlasticLocalization.Name.DiffMenuItem),
                                                                GetPlasticShortcut.ForDiff()));
            mDiffMetaMenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.DiffMetaMenuItem));
            mUndoChangesMenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.PendingChangesMenuItemUndoChanges));
            mCheckoutMenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.PendingChangesMenuItemCheckout));
            mDeleteMenuItemContent = new GUIContent(string.Format("{0} {1}",
                                                                  PlasticLocalization.GetString(PlasticLocalization.Name.PendingChangesMenuItemDelete),
                                                                  GetPlasticShortcut.ForDelete()));
            mViewHistoryMenuItemContent = new GUIContent(string.Format("{0} {1}",
                                                                       PlasticLocalization.GetString(PlasticLocalization.Name.ViewHistoryMenuItem),
                                                                       GetPlasticShortcut.ForHistory()));
            mViewHistoryMetaMenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.ViewHistoryMetaMenuItem));

            mFilterMenuBuilder.BuildIgnoredSubmenuItem();
            mFilterMenuBuilder.BuildHiddenChangesSubmenuItem();
        }
        void BuildComponents()
        {
            mOpenSubmenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen));
            mOpenMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen))
                + " #o");
            mOpenWithMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpenWith)));
            mOpenInExplorerMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    PlasticLocalization.GetString(PlasticLocalization.Name.OpenInExplorerMenuItem)));
            mOpenMetaMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    "Open .meta"));
            mOpenMetaWithMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    "Open .meta with..."));
            mOpenMetaInExplorerMenuItemContent = new GUIContent(
                UnityMenuItem.GetText(
                    PlasticLocalization.GetString(PlasticLocalization.Name.ItemsMenuItemOpen),
                    "Open .meta in explorer"));
            mDiffMenuItemContent        = new GUIContent("Diff %d");
            mDiffMetaMenuItemContent    = new GUIContent("Diff .meta");
            mUndoChangesMenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.PendingChangesMenuItemUndoChanges));
            mCheckoutMenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.PendingChangesMenuItemCheckout));
            mDeleteMenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.Name.PendingChangesMenuItemDelete)
                + " _Del");
            mViewHistoryMenuItemContent     = new GUIContent("View file history %h");
            mViewHistoryMetaMenuItemContent = new GUIContent("View .meta file history");

            mFilterMenuBuilder.BuildIgnoredSubmenuItem();
            mFilterMenuBuilder.BuildHiddenChangesSubmenuItem();
        }
Beispiel #3
0
        void BuildComponents()
        {
            mMergeSelectedFilesMenuItemContent = new GUIContent(
                PlasticLocalization.GetString(PlasticLocalization.
                                              Name.MergeSelectedFiles));

            mMergeKeepingSourceChangesMenuItemContent = new GUIContent(
                UnityMenuItem.EscapedText(
                    PlasticLocalization.GetString(PlasticLocalization.
                                                  Name.IncomingChangesMenuItemMergeKeepingSourceChanges)));

            mMergeKeepingWorkspaceChangesMenuItemContent = new GUIContent(
                UnityMenuItem.EscapedText(
                    PlasticLocalization.GetString(PlasticLocalization.
                                                  Name.IncomingChangesMenuItemMergeKeepingWorkspaceChanges)));

            string diffYoursWithIncomingText = UnityMenuItem.EscapedText(
                PlasticLocalization.GetString(PlasticLocalization.
                                              Name.IncomingChangesMenuItemDiffYoursWithIncoming));

            string diffIncomingChangesText = UnityMenuItem.EscapedText(
                PlasticLocalization.GetString(PlasticLocalization.
                                              Name.IncomingChangesMenuItemDiffIncomingChanges));

            mDiffYoursWithIncomingMenuItemContent = new GUIContent(
                diffYoursWithIncomingText);

            mDiffIncomingChangesMenuItemContent = new GUIContent(
                diffIncomingChangesText);

            mDiffMetaYoursWithIncomingMenuItemContent = new GUIContent(
                string.Format(
                    "{0}/{1}",
                    MetaPath.META_EXTENSION,
                    diffYoursWithIncomingText));
            mDiffMetaIncomingChangesMenuItemContent = new GUIContent(
                string.Format(
                    "{0}/{1}",
                    MetaPath.META_EXTENSION,
                    diffIncomingChangesText));
        }
 static string GetSubMenuText(string menuName, string subMenuName)
 {
     return(UnityMenuItem.GetText(
                menuName,
                UnityMenuItem.EscapedText(subMenuName)));
 }
 string GetHiddenChangesMenuItemName(string filterPattern)
 {
     return(UnityMenuItem.GetText(
                mHiddenChangesSubmenuItem,
                UnityMenuItem.EscapedText(filterPattern)));
 }
 string GetIgnoredMenuItemName(string filterPattern)
 {
     return(UnityMenuItem.GetText(
                mIgnoredSubmenuItem,
                UnityMenuItem.EscapedText(filterPattern)));
 }