private void Construct(GitManager gitManager, GitReflectionHelper reflectionHelper, UniGitData data, ILogger logger, GitSettingsJson gitSettings, GitCallbacks gitCallbacks, GitInitializer initializer, GitSettingsManager settingsManager, UniGitPaths paths, IGitResourceManager resourceManager) { this.resourceManager = resourceManager; this.paths = paths; this.settingsManager = settingsManager; this.logger = logger; this.gitSettings = gitSettings; this.initializer = initializer; if (gitManager == null) { logger.Log(LogType.Error, "Git manager cannot be null."); return; } if (this.gitCallbacks != null) { Unsubscribe(this.gitCallbacks); } this.data = data; this.gitManager = gitManager; this.gitManager.AddWatcher(this); this.reflectionHelper = reflectionHelper; Subscribe(gitCallbacks); }
public GitOverlay(IGitResourceManager resourceManager) { m_icons = new Icons() { validIcon = new GUIContent(resourceManager.GetTexture("success")), validIconSmall = new GUIContent(resourceManager.GetTexture("success_small")), modifiedIcon = new GUIContent(resourceManager.GetTexture("error")), modifiedIconSmall = new GUIContent(resourceManager.GetTexture("error_small")), addedIcon = new GUIContent(resourceManager.GetTexture("add")), addedIconSmall = new GUIContent(resourceManager.GetTexture("add_small")), untrackedIcon = new GUIContent(resourceManager.GetTexture("info")), untrackedIconSmall = new GUIContent(resourceManager.GetTexture("info_small")), ignoredIcon = new GUIContent(resourceManager.GetTexture("minus")), ignoredIconSmall = new GUIContent(resourceManager.GetTexture("minus_small")), conflictIcon = new GUIContent(resourceManager.GetTexture("warning")), conflictIconSmall = new GUIContent(resourceManager.GetTexture("warning_small")), deletedIcon = new GUIContent(resourceManager.GetTexture("deleted")), deletedIconSmall = new GUIContent(resourceManager.GetTexture("deleted_small")), renamedIcon = new GUIContent(resourceManager.GetTexture("renamed")), renamedIconSmall = new GUIContent(resourceManager.GetTexture("renamed_small")), loadingIconSmall = new GUIContent(resourceManager.GetTexture("loading")), objectIcon = new GUIContent(resourceManager.GetTexture("object")), objectIconSmall = new GUIContent(resourceManager.GetTexture("object_small")), metaIcon = new GUIContent(resourceManager.GetTexture("meta")), metaIconSmall = new GUIContent(resourceManager.GetTexture("meta_small")), fetch = new GUIContent(resourceManager.GetTexture("GitFetch")), merge = new GUIContent(resourceManager.GetTexture("GitMerge")), checkout = new GUIContent(resourceManager.GetTexture("GitCheckout")), loadingCircle = new GUIContent(resourceManager.GetTexture("loading_circle")), stashIcon = new GUIContent(resourceManager.GetTexture("stash")), unstashIcon = new GUIContent(resourceManager.GetTexture("unstash")), lfsObjectIcon = new GUIContent(resourceManager.GetTexture("lfs_object")), lfsObjectIconSmall = new GUIContent(resourceManager.GetTexture("lfs_object_small")), donateSmall = new GUIContent(resourceManager.GetTexture("donate"), "Donate"), starSmall = new GUIContent(resourceManager.GetTexture("star")), trashIconSmall = new GUIContent(resourceManager.GetTexture("trash")), submoduleIcon = new GUIContent(resourceManager.GetTexture("file_submodule")), submoduleIconSmall = new GUIContent(resourceManager.GetTexture("file_submodule_small")), submoduleTagIcon = new GUIContent(resourceManager.GetTexture("submodule_tag")), submoduleTagIconSmall = new GUIContent(resourceManager.GetTexture("submodule_tag_small")), }; }