Ejemplo n.º 1
0
        private void refreshBoardInfo()
        {
            // don't refresh current board if there aren't any feedback boards on the account
            if (boards.Length == 0)
            {
                return;
            }

            setBoardProgressBar(boards[selectedBoard].name, "Setting board info", 0f);

            config.Board.Id = boards[selectedBoard].id;

            setBoardProgressBar(boards[selectedBoard].name, "Getting lists and categories", 0.3f);

            // update lists and categories
            updateLists();

            setBoardProgressBar(boards[selectedBoard].name, "Getting labels", 0.6f);

            // set board priority labels
            config.Board.Labels = trello.GetLabels(boards[selectedBoard].id);

            // sort labels by id
            config.Board.Labels = config.Board.Labels.OrderBy(l => l.id).ToArray();

            setBoardProgressBar(boards[selectedBoard].name, "Checking subscribed state", 0.9f);

            // update subscribed checkbox
            updateSubscribed();

            EditorUtility.ClearProgressBar();

            // save asset
            EditorUtility.SetDirty(config);
            AssetDatabase.SaveAssets();
        }