101 views
in GUI Development by

Hello,

I want to InvalidateStateView() of the Owner Dialog of the present topmost dialog.

for example :

Owner.PresentDialog( new  aDialog, null, null, null, null, null, false );

/*** do things **/

Owner.InvalidateViewState(); // is it referring to the dialog where the present dialog was called right?

Owner.DismissDialog( this, null, null, null, null, null, false );

 

1 Answer

0 votes
by

Hello Riccardo,

Owner.InvalidateViewState(); // is it referring to the dialog where the present dialog was called right?

Owner refers the owner component, the asking component X is actually displayed inside. This is not necessarily the dialog which triggered the PresentDialog( X, .... ) operation.

Well, I'm not sure whether that answers your question. If not, please explain more in detail the relation between the dialogs or components. See also the section Enumerate and search views existing within the component and Enumerate and search for existing Dialogs. Maybe the methods described there provide the desired functionality to find the dialog (= component, = view).

For example, assuming a component X is acting as dialog and you want to access the dialog, which was active in the same Owner just before X was presented, then following could work:

// 'this' represents the actual component X

var int32       index      = Owner.GetIndexOfDialog( this );
var Core::Group prevDialog = Owner.GetDialogAtIndex( index + 1 );

// or, if 'this' dialog is actually the 'active' dialog within Owner:

var Core::Group prevDialog = Owner.GetDialogAtIndex( 1 );

I hope it helps you further.

Best regards

Paul Banach

Ask Embedded Wizard

Welcome to the question and answer site for Embedded Wizard users and UI developers.

Ask your question and receive answers from the Embedded Wizard support team or from other members of the community!

Embedded Wizard Website | Privacy Policy | Imprint

...