title: Multiple windows in a single project
body: <p>I have a requirement for my project to display two QML <code>Window</code>s each on one of the screen (one sender, one receiver). Both of the <code>.qml</code> requires me to include some Cpp models inside hence, I'm using <code>QQmlApplicationEngine</code> to register the Cpp models.</p>
  
  <p>I found out that using <code>QWidget::createWindowContainer()</code> I'm able to display multiple <code>Window</code>s for a single project. This works perfectly fine for the first QML file. The code snippets looks like this:</p>
  
  <pre><code>QQmlApplicationEngine* engine = new QQmlApplicationEngine(Qurl("main.qml"));
  QmlContext* context = engine.getContextProperty();
  
  //do some Cpp models registering...
  
  QQuickview *view = new QQuickview(engine,0);
  QWidget* container = widget::createWindowContainer(view);  
  //I realized I dont need to do container-&gt;show(); for the main.qml to appear..
  
  //use desktop widget to move the 2nd container to the 2nd screen...
  </code></pre>
  
  <p>I decided to create a 2nd application engine for my <code>receive.qml</code> with a similar method. I soon realized that the <code>receive.qml</code> would never open even with <code>container2-&gt;show()</code>. Now, it is showing an empty page.</p>
  
  <p>My questions are:</p>
  
  <ol>
  <li>Is my approach correct or is there a better solution for this?</li>
  <li>What signal do I need look out for to catch the window close
  event? I cant seem to be able to detect the signal when one of the
  window is closed. as I wanted to close the both when one has been
  detected.</li>
  </ol>