virtual public void hideWindow() { PluginLogger.logDebug("hideWindow: " + _name); waitingForUnlockEditor = true; waitingForUnlockEditorStartTime = Time.realtimeSinceStartup; this._windowDisplayed = false; if (OnHide != null) { OnHide(); } }
virtual public void displayWindow() { PluginLogger.logDebug("DisplayWindow: " + _name); //float height = getWindowHeight(windowPos); //float windowWidth = getWindowWidth(windowPos); windowPos = new Rect((Screen.width - windowWidthOnScreen) / 2, (Screen.height - windowHeightOnScreen) / 2, windowWidth, windowHeight); _windowDisplayed = true; centered = false; justAfterWindowDisplay = true; waitingForUnlockEditor = false; }
public static Texture2D loadTextureFrom(string file) { Texture2D tex = null; byte[] fileData; if (File.Exists(file)) { fileData = File.ReadAllBytes(file); tex = new Texture2D(2, 2); tex.LoadImage(fileData); } else { PluginLogger.logError("Cannot find " + file); tex = Texture2D.blackTexture; } return(tex); }
virtual public void start() { PluginLogger.logDebug("Start in window: " + _name); }