Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
给定一个 Activity 对象,有没有办法确定它是否有选项菜单?
You could put a flag in the "onCreateOptionsMenu" method that you could check for to see it had ever been called.