title: How to update a QStringListModel?
body: <p>I have the following code:</p>
  
  <pre><code>QStringListModel* m=new QStringListModel(gc.get_lista_file());
  ui-&gt;lista_immagini_listView-&gt;setModel(m);
  </code></pre>
  
  <p>where <code>gc.get_lista_file()</code> returns a <code>QStringList</code> object and <code>lista_immagini_listView</code> is a <code>QListView</code>.</p>
  
  <p>I need to update my <code>lista_immagini_listView</code> adding a string when I press a button, but if I add my new string to my <code>QStringList</code> object it doesn't update my model (I read the <code>QStringList</code> is passed by copy, so it isn't connected to the model). So, I have to update my <code>QStringListModel</code> but in this way I have to update 2 object (<code>QStringList</code> and <code>QStringListModel</code>) and doesn't seem a good practice.</p>
  
  <p>What is the best way (if exists) to resolve it?</p>