Wednesday 15 April 2015

android - Error while using setDisplayHomeAsUpEnabled in FadingActionBarHelper -



android - Error while using setDisplayHomeAsUpEnabled in FadingActionBarHelper -

i want implement fadingactionbar in application to effects latest google play music app. below how using fadingactionbar

@override protected void oncreate(bundle savedinstancestate) { super.oncreate(savedinstancestate); fadingactionbarhelper helper = new fadingactionbarhelper() .actionbarbackground(r.drawable.ab_background) .headerlayout(r.layout.header) .contentlayout(r.layout.activity_listview); setcontentview(helper.createview(this)); helper.initactionbar(this);

here wanted add together button in actionbar using setdisplayhomeasupenabled(true); getting error while adding above code saying no such method found.

my question there way add together setdisplayhomeasupenabled(true); if not, how can add together button fadingactionbar

i had same problem because using appcompat v7 have add together this.

getsupportactionbar().setdisplayhomeasupenabled(true);

or

getactionbar().setdisplayhomeasupenabled(true);

hope helps

android

No comments:

Post a Comment