Skip to main content
oe2
Associate III
December 1, 2020
Solved

How can I make an modal window over custom keyboard widget

  • December 1, 2020
  • 3 replies
  • 1500 views

I have a screen with some pictures, buttons and a custom keyboard widget. I want to show a modal window on this window.

But when I do "view" on my modal window, it only covers the things defined in gfxdesigner not the custom keyboard widget.

How can I include custom keyboard to so that it becomes part of the "main window" or is there perhaps an better / other way?

This topic has been closed for replies.
Best answer by Michael K

To move your modal to the top, simply

remove(modalElement);
add(modalElement);

at the end of your setupScreen() method. This should be done after you add() your keyboard widget, if that is not done in the base class.

3 replies

oe2
oe2Author
Associate III
December 3, 2020

Does anyone know if it's the drawing order, I have tried to change the "add order" by moving my kybord code the the base file (I know that it will be overritten next time I generate the code for designer) but It dosent seems to do any change the keyboard is still "on-top". Mybe the keyboard itself i "modal" (I can't find anythning in the code that supports that theory).

Michael K
Michael KBest answer
Senior III
December 4, 2020

To move your modal to the top, simply

remove(modalElement);
add(modalElement);

at the end of your setupScreen() method. This should be done after you add() your keyboard widget, if that is not done in the base class.

Embedded UI/UX Consulting: cadenza.design
oe2
oe2Author
Associate III
December 4, 2020

Thanks Michael,

Works like a charm! Easy when you know how to do it, but hard do find out how to do it...

BR Ola

Michael K
Senior III
December 4, 2020

You're welcome, happy to help! You were 90% of the way there yourself with your draw-order suspicion.

Embedded UI/UX Consulting: cadenza.design