<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
Hello Germán<br>
<br>
Note that I've already fixed some related problems with
<a class="moz-txt-link-freetext" href="https://github.com/qgis/QGIS/pull/4964">https://github.com/qgis/QGIS/pull/4964</a><br>
<br>
Calling deleteLater should delete the dialog on next events
processing.<br>
Do dialog and child widgets signals should be correctly
disconnected.<br>
<br>
Arnaud<br>
<br>
<br>
<div class="moz-cite-prefix">Le 25/04/2018 à 16:55, Germán Carrillo
a écrit :<br>
</div>
<blockquote type="cite"
cite="mid:CANaz7mwRb4cixCJCdREamjuTifeZ7V_nz_zAvmMW_NS3=8AjXQ@mail.gmail.com">
<div dir="ltr">Hi All, <br clear="all">
<div><br>
</div>
<div><br>
</div>
<div>In the Refactor Fields algorithm dialog there is an "Input
layer" combo box. Each time the user selects one layer a modal
dialog (message box) appears, letting her select whether the
fields <span class="sewzf1v8vfrkot0"></span><span
class="sewtph3g1eh3q9m"></span>mapping should be reset or
not<span class="m_7932735706414457355sew8dr67syp7w6h"></span><span
class="m_7932735706414457355sews58f6dkz5z9l"></span>. See
image: [1].</div>
<div><br>
</div>
<div><br>
</div>
<div>I'd like to ask you if we can get rid of such modal dialog
for these reasons:<br>
</div>
<div><br>
</div>
<div><br>
</div>
<div>1) In general, it's good to avoid modal dialogs as they
block workflows and hamper interaction.<br>
</div>
<div><br>
</div>
<div>2) Other algorithms don't use such dialog to warn users
about potential changes in other widgets (e.g., field combo
boxes dependng on the selected layer). <span
class="m_7932735706414457355sew8dr67syp7w6h"></span><span
class="m_7932735706414457355sews58f6dkz5z9l"></span><br>
</div>
<div><br>
</div>
<div>3) The dialog is only *useful* if the user clicks on the
combo box by accident and wants to avoid resetting the mapping
(a very specific use case). However, in that case the combo
box shows that a new layer is selected, but the mapping won't
correspond to it, which is confusing.</div>
<div><br>
</div>
<div>4) Follow these steps:</div>
<div>
<div><br>
</div>
<div> a. Open QGIS and load a vector layer.</div>
<div> b. Open the Refactor Fields dialog and press ESC to
close it.</div>
<div> c. Add another vector layer to QGIS.</div>
<div> d. Close the QGIS project. </div>
</div>
<div><br>
</div>
<div>As soon as you close the project (e.g., when you want to
start a new one) the modal dialog shows up :( (see this
short video [2]).</div>
<div><br>
</div>
<div>5) The dialog is triggered too many times when using the
"Fields Mapper" widget in a custom Processing model (and
triggering it from a plugin) (see this short video [3]).</div>
<div><br>
</div>
<div><br>
</div>
<div><br>
</div>
<div>So, the question for you is: Can we get rid of it? I've
created a PR for that :D [4]<span class="sewzf1v8vfrkot0"></span><span
class="sewtph3g1eh3q9m"></span>.</div>
<div><br>
</div>
<div><br>
</div>
<div>Regards, </div>
<div><br>
</div>
<div>Germán</div>
<div>-----------</div>
<div>[1] <a
href="http://downloads.tuxfamily.org/tuxgis/tmp/ai/reset_field_mapping.png"
moz-do-not-send="true">http://downloads.tuxfamily.org/tuxgis/tmp/ai/reset_field_mapping.png</a><span
class="sewzf1v8vfrkot0"></span><span class="sewtph3g1eh3q9m"></span></div>
<div>[2] <a
href="http://downloads.tuxfamily.org/tuxgis/tmp/ai/gif_refactor_fields_qgis.mp4"
moz-do-not-send="true">http://downloads.tuxfamily.org/tuxgis/tmp/ai/gif_refactor_fields_qgis.mp4</a><span
class="sewzf1v8vfrkot0"></span><span class="sewtph3g1eh3q9m"></span></div>
<div>[3] <a
href="http://downloads.tuxfamily.org/tuxgis/tmp/ai/gif_refactor_fields_plugin.mp4"
moz-do-not-send="true">http://downloads.tuxfamily.org/tuxgis/tmp/ai/gif_refactor_fields_plugin.mp4</a><span
class="sewzf1v8vfrkot0"></span><span class="sewtph3g1eh3q9m"></span></div>
<div>[4] <a href="https://github.com/qgis/QGIS/pull/6857"
moz-do-not-send="true">https://github.com/qgis/QGIS/pull/6857</a><span
class="sewzf1v8vfrkot0"></span><span class="sewtph3g1eh3q9m"></span></div>
-- <br>
<div class="m_7932735706414457355gmail_signature"
data-smartmail="gmail_signature">
<div dir="ltr">
<div>
<div dir="ltr">
<div dir="ltr">
<div>-----------<br>
</div>
<div> |\__ <br>
(:>__)(<br>
|/ <br>
Soluciones Geoinformáticas Libres
<br>
<a href="http://geotux.tuxfamily.org/"
target="_blank" moz-do-not-send="true">http://geotux.tuxfamily.org/</a><br>
<a href="http://twitter.com/GeoTux2" target="_blank"
moz-do-not-send="true">http://twitter.com/GeoTux2</a></div>
<div><a href="http://about.me/germancarrillo"
target="_blank" moz-do-not-send="true">http://about.me/germancarrillo</a><br>
</div>
<div>
<div><br>
</div>
<div><a
href="http://gis.stackexchange.com/users/4972/germ%c3%a1n-carrillo"
target="_blank" moz-do-not-send="true"><img
src="http://gis.stackexchange.com/users/flair/4972.png"
moz-do-not-send="true"></a></div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
QGIS-Developer mailing list
<a class="moz-txt-link-abbreviated" href="mailto:QGIS-Developer@lists.osgeo.org">QGIS-Developer@lists.osgeo.org</a>
List info: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-developer">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a>
Unsubscribe: <a class="moz-txt-link-freetext" href="https://lists.osgeo.org/mailman/listinfo/qgis-developer">https://lists.osgeo.org/mailman/listinfo/qgis-developer</a></pre>
</blockquote>
<br>
</body>
</html>