This is a migrated thread and some comments may be shown as answers.

Multiple Windows Using MVVM

1 Answer 114 Views
Window
This is a migrated thread and some comments may be shown as answers.
Toby
Top achievements
Rank 1
Toby asked on 23 Jul 2012, 08:23 PM
I'm trying to create an application which has two windows.  I am using the MVVM framework, so I'm trying to create my windows declaratively using the data-role="window" syntax.  I'm not sure if I'm doing something wrong, but I am running into two issues:

  1. Windows appear to ignore the data-visible="false" attribute
  2. Windows declared after the first window fail to be initialized correctly - eg: Only one of my windows is created correctly.
I created a jsfiddle to demonstrate:
http://jsfiddle.net/rKeR5/


Also:
I should probably point out that I also tried working around this by manually creating the windows using the .kendoWindow() method, but it seems like this breaks the MVVM bindings to fields I have bound inside of the window (to my view model.)

Update:
It seems that the problem only exists if the windows are declared as siblings in the DOM.

1 Answer, 1 is accepted

Sort by
0
David
Top achievements
Rank 1
answered on 19 Dec 2012, 04:53 PM
In our application we get around the sibling problem by simply having an empty <div></div> between each declaratively bound window.
Tags
Window
Asked by
Toby
Top achievements
Rank 1
Answers by
David
Top achievements
Rank 1
Share this question
or