12-27-2012 10:28 AM
Hi,
I'd like to open context menu on button press, not on long press. Best from qml. Is this possible? I couldn't find any API calls to do this but I hope I'm just overlooking some way...
Michal
12-31-2012 11:19 AM
* bump *
So I assume it's imossible and I'll have to create my own custom context menu. Anyone from RIM around here?
Happy new year ![]()
Thanks
12-31-2012 12:17 PM
Its currently not possible
You can use the BPS native functions to create a "system" context menu:
but you are limited to system-defined icons such as cut/copy/paste etc.
12-31-2012 07:16 PM
01-02-2013 05:25 PM
I do realize that I'm breaking some UI guidelines with my design, but sometimes you can't go by the book. Basically I have a landscape app, and I need to use whole available space. Using normal actions would make nav bar be always visible in the bottom, which takes a lot of space in landscape orientation, and also would ruin my design.
So what I did was place a "..." (more) button, which upon pressing presents extra options for current screen. I wanted to use context-menu facility as it comes out from right side (makes sense in landscape), and can hold actions. Perfect match for my needs, except it only works on long-press.
I ended up implementing my own fake menu that slides in from right upon button press, but it would be nice if I could have utilize built-in features, even if not in their intended way.
01-02-2013 05:41 PM
fyi - I believe it should be possible to auto-hide the actionbar, if that makes a difference to your design.
I know what you mean about the context-menu - I was in a similar scenario myself. I ended up implementing my own custom dialog instead (based on the SystemToast with buttons design) that prompts for user input that way. It actually turned out pretty well, but I can see how in some circumstances it'd be nice to pop open the context menu as well
01-02-2013 07:26 PM
Agreed, and something I'd like to see for the browser...
01-03-2013 01:49 AM
Here is the example of opening the context menu with the system-defined icons:
https://github.com/blackberry/Cascades-Samples/blo