title: Pass UI in parameter in Qt
body: <p>I have an windows ui in a Qt project and I want pass this ui in parameter to another function, like that:</p>
  
  <pre><code>ConfWindows::ConfWindows(QWidget *parent) :
  QDialog(parent),
  ui(new Ui::ConfWindows)
  {
      ui-&gt;setupUi(this);
  
      connect(ui-&gt;add_button, SIGNAL(clicked()), this, SLOT(add_elem(ui-&gt;name_edit)));
  }
  
  void        add_elem(QLabel test)
  {
      qDebug() &lt;&lt; test.text();
  }
  </code></pre>
  
  <p>But I get an error when I try to do that:</p>
  
  <pre><code>'QLabel::QLabel(const QLabel&amp;)' is private
   Q_DISABLE_COPY(QLabel)
  </code></pre>
  
  <p>It's impossible to pass an ui element in parameters ?</p>
  
  <p>Thank for you help.</p>