Page 1 of 1

Is it possible to remove/delete entries on the item menu

Posted: Sat Mar 09, 2019 3:34 pm
by brunoisa10
As it's possible to add using menu.addMainItem

Is it possible to add menu.removeMainItem ?

How are you doing for Chronometer or Clock ? Where there is only Reset and Settings

Re: Is it possible to remove/delete entries on the item menu

Posted: Sat Mar 09, 2019 3:41 pm
by TrianguloY
There isn't, no. However if you don't want an entry, just don't add it.

Unless you want to remove the lightning existing entries.

You can use this to remove all of them:
menu.getMainItemsView().removeAllViews();

But removing only a specific one...that's harder.

Re: Is it possible to remove/delete entries on the item menu

Posted: Sat Mar 09, 2019 4:03 pm
by brunoisa10
All is a very good start for me. Thanks

Re: Is it possible to remove/delete entries on the item menu

Posted: Sat Mar 09, 2019 5:01 pm
by brunoisa10
I think it's fine with remove all.
Thanks a ton