Skip to content

Commit fe40d49

Browse files
author
charcolle
committed
UnityEditorMemo ver2.2 Release
1 parent d0450c8 commit fe40d49

14 files changed

Lines changed: 33 additions & 36 deletions

Assets/Plugins.meta

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Assets/Plugins/UnityEditorMemo/Editor/SaveData.meta

Lines changed: 0 additions & 9 deletions
This file was deleted.
Binary file not shown.

Assets/Plugins/UnityEditorMemo/Editor/SaveData/UnityEditorMemoData.asset.meta

Lines changed: 0 additions & 9 deletions
This file was deleted.
Binary file not shown.

Assets/Plugins/UnityEditorMemo/Editor/SaveData/UnitySceneMemoData.asset.meta

Lines changed: 0 additions & 9 deletions
This file was deleted.

Assets/Plugins/UnityEditorMemo/Editor/Scripts/Core/UnitySceneMemoClass.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@ public static implicit operator int( UnitySceneMemo memo ) {
6868
//=======================================================
6969
// Drawer
7070
//=======================================================
71+
7172
[NonSerialized]
7273
public bool IsContextClick = false;
7374
private Rect rect = Rect.zero;

Assets/Plugins/UnityEditorMemo/Editor/Scripts/GUI/UnityEditorMemoGUIHelper.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ static Styles() {
5858
LabelWordWrap.wordWrap = true;
5959
LabelWordWrap.richText = true;
6060

61-
LargeDropdown = new GUIStyle( "LargeDropDown" );
61+
LargeDropdown = new GUIStyle( "DropDown" );
6262
LargeDropdown.richText = true;
6363

6464
TextAreaWordWrap = new GUIStyle( GUI.skin.textArea );

Assets/Plugins/UnityEditorMemo/Editor/Scripts/Slack/UnityEditorMemoSlackHelper.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ public static bool Post( UnityEditorMemo memo, string categoryName ) {
4747

4848
private static IEnumerator postCo( string url ) {
4949
var req = UnityWebRequest.Get( url );
50-
#if UNITY_2017_1_OR_NEWER
50+
#if UNITY_2017_2_OR_NEWER
5151
yield return req.SendWebRequest();
5252
#else
5353
yield return req.Send();

Assets/Plugins/UnityEditorMemo/Editor/Scripts/System/UnitySceneMemoHelper.cs

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,28 @@ public static int GetLocalIdentifierInFile( Object obj ) {
138138
localId = localIdProp.intValue;
139139
//if( localId != 0 )
140140
// return localId;
141+
#if UNITY_2018_3_OR_NEWER
142+
PrefabAssetType prefabType = PrefabUtility.GetPrefabAssetType( obj );
143+
if( prefabType != PrefabAssetType.MissingAsset ) {
144+
var o = PrefabUtility.GetPrefabInstanceHandle( obj );
145+
if( o == null )
146+
o = obj;
147+
serializedObject = new SerializedObject( o );
148+
inspectorModeInfo.SetValue( serializedObject, InspectorMode.Debug, null );
149+
localIdProp = serializedObject.FindProperty( "m_LocalIdentfierInFile" );
150+
localId = localIdProp.intValue;
141151

152+
if( obj != PrefabUtility.GetOutermostPrefabInstanceRoot( obj as GameObject ) ) {
153+
o = PrefabUtility.GetCorrespondingObjectFromSource( obj );
154+
if( o != null ) {
155+
serializedObject = new SerializedObject( o );
156+
inspectorModeInfo.SetValue( serializedObject, InspectorMode.Debug, null );
157+
localIdProp = serializedObject.FindProperty( "m_LocalIdentfierInFile" );
158+
localSubId = localIdProp.intValue;
159+
}
160+
}
161+
}
162+
#else
142163
PrefabType prefabType = PrefabUtility.GetPrefabType( obj );
143164
if ( prefabType != PrefabType.None ) {
144165
var o = PrefabUtility.GetPrefabObject( obj );
@@ -159,6 +180,7 @@ public static int GetLocalIdentifierInFile( Object obj ) {
159180
}
160181
}
161182
}
183+
#endif
162184
return localId + localSubId;
163185
}
164186

0 commit comments

Comments
 (0)