コード例 #1
0
 static void UpdateHeader()
 {
     gameTitle = SharePackageUtils.GetFilteredGameTitle(gameTitle);
     SetupLabel("lblProjectName", gameTitle, new SharePackageUtils.LeftClickManipulator(OnLinkLabelClick));
     SetupLabel("lblUserEmail", string.Format("By {0}", CloudProjectSettings.userName));
     SetupImage("imgThumbnail", SharePackageUtils.GetThumbnailPath());
 }
コード例 #2
0
ファイル: Middleware.cs プロジェクト: ankur25140/DirtRacing
        private static void CopyThumbnail(Store <AppState> store)
        {
            var buildOutputDir    = SharePackageUtils.GetBuildOutputDirectory();
            var thumbnailDestPath = Path.Combine(buildOutputDir, thumbnail);

            File.Delete(thumbnailDestPath);

            string thumbnailDir = SharePackageUtils.GetThumbnailPath();

            if (string.IsNullOrEmpty(thumbnailDir))
            {
                return;
            }

            FileUtil.CopyFileOrDirectory(thumbnailDir, thumbnailDestPath);
        }
コード例 #3
0
        void SetupUploadTab()
        {
            SetupButton("btnShare", OnShareClicked, true);
            SetupButton("btnSelectImage", OnSelectImageClicked, true);
            SetupImage("imgThumbnail", SharePackageUtils.GetThumbnailPath());

            TextField txtProjectName = root.Query <TextField>("txtProjectName");

            txtProjectName.RegisterValueChangedCallback(OnGameTitleChanged);
            txtProjectName.value = gameTitle;

            if (SharePackageUtils.LastBuildIsValid())
            {
                string lastOutputDirectory = SharePackageUtils.GetBuildOutputDirectory();
                SetupLabel(
                    "lblLastBuildInfo",
                    $"Last build located at {lastOutputDirectory}, created {File.GetLastWriteTime(lastOutputDirectory)}"
                    );
                return;
            }

            //[NOTE]: you should never get here
            SetupLabel("lblLastBuildInfo", "No previous build available...");
        }