private void OnEnable() { Rect subPos = GetSubWindowArea(); manageTab = new AssetBundleWindowConfigureTab(); manageTab.OnEnable(subPos, this); buildTab = new AssetBundleWindowBuildTab(); buildTab.OnEnable(this); inspectTab = new AssetBundleWindowInspectTab(); inspectTab.OnEnable(subPos); m_TextureRefresh = EditorGUIUtility.FindTexture("Refresh"); InitDataSources(); }
internal void SetBundle(AssetBundle bundle, string path = "", AssetBundleWindowInspectTab.InspectTabData inspectTabData = null, AssetBundleWindowInspectTab assetBundleInspectTab = null) { //static var... currentPath = path; m_InspectTabData = inspectTabData; m_AssetBundleInspectTab = assetBundleInspectTab; //members if (bundle != null) { m_Editor = Editor.CreateEditor(bundle); } else { m_Editor = null; } }
internal void OnEnable(EditorWindow parent) { m_InspectTab = (parent as AssetBundleWindow).inspectTab; #region Load Data var dataPath = System.IO.Path.GetFullPath("."); dataPath = dataPath.Replace("\\", "/"); dataPath += "/Library/AssetBundleBrowserBuild.dat"; if (File.Exists(dataPath)) { BinaryFormatter bf = new BinaryFormatter(); FileStream file = File.Open(dataPath, FileMode.Open); var data = bf.Deserialize(file) as BuildTabData; if (data != null) { m_UserData = data; } file.Close(); } #endregion Load Data #region Advanced Settings Options m_ToggleDatas = new List <ToggleData>(); m_ToggleDatas.Add(new ToggleData( false, "Exclude Type Information", "Do not include type information within the asset bundle (don't write type tree).", m_UserData.m_OnToggles, BuildAssetBundleOptions.DisableWriteTypeTree)); m_ToggleDatas.Add(new ToggleData( false, "Force Rebuild", "Force rebuild the asset bundles", m_UserData.m_OnToggles, BuildAssetBundleOptions.ForceRebuildAssetBundle)); m_ToggleDatas.Add(new ToggleData( false, "Ignore Type Tree Changes", "Ignore the type tree changes when doing the incremental build check.", m_UserData.m_OnToggles, BuildAssetBundleOptions.IgnoreTypeTreeChanges)); m_ToggleDatas.Add(new ToggleData( false, "Append Hash", "Append the hash to the assetBundle name.", m_UserData.m_OnToggles, BuildAssetBundleOptions.AppendHashToAssetBundleName)); m_ToggleDatas.Add(new ToggleData( false, "Strict Mode", "Do not allow the build to succeed if any errors are reporting during it.", m_UserData.m_OnToggles, BuildAssetBundleOptions.StrictMode)); m_ToggleDatas.Add(new ToggleData( false, "Dry Run Build", "Do a dry run build.", m_UserData.m_OnToggles, BuildAssetBundleOptions.DryRunBuild)); #endregion Advanced Settings Options m_ForceRebuild = new ToggleData( false, "Clear Folders", "Will wipe out all contents of build directory as well as StreamingAssets/AssetBundles if you are choosing to copy build there.", m_UserData.m_OnToggles); m_ResetAssetBundleName = new ToggleData( false, "Reset All AssetBundle Name", "Will Reset All resource AssetBundle Name", m_UserData.m_OnToggles); m_CheckRedundant = new ToggleData( false, "Check Redundant", "", m_UserData.m_OnToggles); m_CopyToStreaming = new ToggleData( false, "Copy to StreamingAssets", "After build completes, will copy all build content to " + m_streamingPath + " for use in stand-alone player.", m_UserData.m_OnToggles); m_Reporter = new ToggleData( false, "AssetBundle Report", "After Build completes, Report assetbundle into excel", m_UserData.m_OnToggles); m_TargetContent = new GUIContent("Build Target", "Choose target platform to build for."); m_CompressionContent = new GUIContent("Compression", "Choose no compress, standard (LZMA), or chunk based (LZ4)"); if (m_UserData.m_UseDefaultPath) { ResetPathToDefault(); } }
internal InspectBundleTree(TreeViewState s, AssetBundleWindowInspectTab parent) : base(s) { m_InspectTab = parent; showBorder = true; }