Question

In my android application option menu should be available in every UI. So I need to separate those codes to a separate class file instead of repeating same code in every Activity. How can I do this in Android ?

Was it helpful?

Solution

One way is to inherit from a custom class that itself derives from 'Activity'. In this base class, you have the common code for the options menu.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top