Closed agarwlGaurav closed 11 years ago
The example is standalone. It depends on ActionBarSherlock because it is the version that is released on the Play Store and should support as many devices as possible. The library itself should not depend on ActionBarSherlock because it is bad practice to have one library depend on another external one. Thanks for you inquiry.
Supose theres a need to put some class in example module that moves ABS dependency to example module only.
Here I got the temporary solution to run an example http://stackoverflow.com/questions/13438657/set-up-slidemenu-example-not-working
Nowtime thats bad. I spent about an hour to understand the need I should modify the library to get example working. There are also other people facing that bug https://github.com/jfeinstein10/SlidingMenu/issues/145
BaseActivity extends SlidingFragmentActivity
and usesgetSupportActionBar().setDisplayHomeAsUpEnabled(true);
inonCreate()
and ActionbarSherlock documentation
When creating an activity to use the action bar on all versions of Android, you must declare your activity to extend any of the activity classes that start with 'Sherlock' (e.g., SherlockActivity, SherlockFragmentActivity). Interaction with the action bar is handled by calling getSupportActionBar() (instead of getActionBar()).
therefore
SlidingFragmentActivity should extend SherlockFragmentActivity instead of FragmentActivity