Using genericMenu with Items from variable

Community based support for the Digium Phone Application Programming Interface (API).

Moderators: jwitt, sruffell, malcolmd, Moderator

Using genericMenu with Items from variable

Postby timo » Wed Sep 25, 2013 10:50 pm

Hi,
as the Digium Phones are missing the pickupgroup notification like the snom phones do I'm building one using the API and AMI.

That's how it works:
Everytime a new call in the pickupgroup arrives I send an action from ami to the phones belonging to that group and a menu pops up.

And the problem:
Once the menu was shown it displays the first initial items from first show every next time although the items from my variable have changed.

One solution is changing the id of the menu everytime I show it.
But I don't know if it will result in an overflow when the app is in business...

Is there a way to dispose this menu after it was sent to background?

Exit the application everytime after showing is no option cause I need the observe to catch the action from the ami...

Best regards,
Timo
timo
Newsterisk
 
Posts: 7
Joined: Wed Sep 25, 2013 6:07 am

Re: Using genericMenu with Items from variable

Postby sruffell » Thu Sep 26, 2013 12:06 pm

If I'm following, I think what you are looking for is the 'forceRedraw' parameter to genericMenu.show().
sruffell
Oldsterisk
 
Posts: 200
Joined: Fri Jan 07, 2011 2:02 pm

Re: Using genericMenu with Items from variable

Postby timo » Thu Sep 26, 2013 9:50 pm

Thank you very much!!! That is exactly what I was looking for!
Didn't knew it is working for the genericMenu, too, because it's not mentioned in the api-reference...
timo
Newsterisk
 
Posts: 7
Joined: Wed Sep 25, 2013 6:07 am

Re: Using genericMenu with Items from variable

Postby sruffell » Thu Sep 26, 2013 10:54 pm

Ahh...I didn't even notice that I linked the wrong documentation page after I checked in the code.

So, now to see about updating that documentation page.... Thanks for pointing that out.
sruffell
Oldsterisk
 
Posts: 200
Joined: Fri Jan 07, 2011 2:02 pm


Return to Digium Phone API

Who is online

Users browsing this forum: No registered users and 1 guest