Пример #1
0
        public void DrawSettingsActions(Rect position)
        {
            float fullWindowWidth = position.width + 30;
            float controlHeight   = position.height * 0.16f;
            Rect  newPosition     = position;

            newPosition.width  = fullWindowWidth;
            newPosition.height = controlHeight;
            GUI.Label(newPosition, "Настройки", EditorStyles.boldLabel);        //Settings
            if (GUI.Button(newPosition, "Создать новую культуру"))
            {
                CreateLanguageWindow.ShowWindow(this);
            }
            newPosition.y += controlHeight;

            if (GUI.Button(newPosition, "Экспортировать все языки"))
            {
                BulkUpdateWindow.ShowWindow(BulkUpdateWindow.BulkUpdateMethod.Export, this);
            }
            newPosition.y += controlHeight;

            if (GUI.Button(newPosition, "Импортировать все языки"))
            {
                BulkUpdateWindow.ShowWindow(BulkUpdateWindow.BulkUpdateMethod.Import, this);
            }
        }
Пример #2
0
        public static BulkUpdateWindow ShowWindow(BulkUpdateMethod updateMethod, SmartLocalizationWindow parentWindow)
        {
            BulkUpdateWindow thisWindow = (BulkUpdateWindow)EditorWindow.GetWindow <BulkUpdateWindow>("Обновить языки");    //Update Languages

            thisWindow.Initialize(updateMethod, parentWindow);

            return(thisWindow);
        }