Search Issue Tracker
Fixed
Votes
0
Found in
5.3.4f1
Issue ID
787983
Regression
No
[MenuItem]New menu item with very long name is broken
Steps to reproduce:
1. Create a new project.
2. Create a new script inside of "Assets" folder and name it "Test".
3. Copy-paste these lines of code to the script and save it:
using UnityEngine;
using UnityEditor;
public class Test : MonoBehaviour
{
[MenuItem ("AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA/Do Something")]
static void DoSomething ()
{
Debug.Log ("Doing Something...");
}
}
4. Notice the first bug: in the main menu there are visible several new unnamed menu items instead of one.
5. Click on one of them and select "Do Something" option.
6. Notice the second bug: after clicking on that option "Unity Bug Reporter" window appears.
(if you cannot reproduce it at first, try repeating the fifth step several times with different new menu items).
7. Re-import assets ("Assets->"Reimport All") or open the project again.
8. Notice that the sixth step is not reproducible anymore.
9. Delete script named "Test".
10. Notice the third bug: the main menu is not updated and new menu items are still visible.
(you have to repeat the seventh step to make it disappear).
Expected result:
New menu item with very long name should be visible as one item. Clicking on it should not invoke "Unity Bug Reporter". After deleting it, the main menu should be updated and this new menu item should disappear automatically.
Reproduced with:
5.1.0f3, 5.2.4f1, 5.3.4f1, 5.3.4p3, 5.4.0b14.
(This bug is not reproducible with new menu item that has a short name).
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Shader Graph Asset icon is not shown on creation unless you confirm the name
- APV Sky occlusion doesn't consider the terrain
- [iOS] "EXC_BAD_ACCESS" Player crash when Script Debugging is enabled
- Cursor skips input fields when tabbing between two sets of input fields
- "Shader error redefinition of 'Varyings'" error appears when selecting the shader
Add comment