omassot vor 7 Jahren
Ursprung
Commit
9e7e4f306a
5 geänderte Dateien mit 25 neuen und 70 gelöschten Zeilen
  1. 0 1
      README.md
  2. 2 2
      core/constants.py
  3. 4 4
      metadata.txt
  4. 9 10
      ui/dlg_main.py
  5. 10 53
      ui/dlg_main.ui

+ 0 - 1
README.md

@@ -8,7 +8,6 @@
 
 * QGis 3.0+
 
-
 ### Installer MnCheck
 
 Depuis l'interface de QGis: `Menu > Extension > Installer/Gérer des extensions > Installer depuis un ZIP`

+ 2 - 2
core/constants.py

@@ -6,9 +6,9 @@
 '''
 from path import Path
 
-VERSION = "0.4.0"
+VERSION = "0.6.0"
 
-DEBUG = True
+DEBUG = False
 
 MAIN = Path(__file__).parent.parent.abspath()
 

+ 4 - 4
metadata.txt

@@ -10,14 +10,14 @@
 name=MnCheck
 qgisMinimumVersion=3.0
 description=Contrôle des données FTTH format MN
-version=0.4
+version=0.6
 author=Manche Numérique 2019
-email=olivier.massot@manchenumerique.fr
+email=sig@manchenumerique.fr
 
 about=Auto-contrôle des livrables FTTH aux formats Manche Numérique
 
-tracker=http://lxc-p-web-2:8001/omassot/mncheck
-repository=http://lxc-p-web-2:8001/omassot/mncheck
+tracker=
+repository=
 # End of mandatory metadata
 
 # Recommended items:

+ 9 - 10
ui/dlg_main.py

@@ -36,6 +36,7 @@ class DlgMain(QtWidgets.QDialog):
         super().__init__(parent)
         self.available_schemas = mncheck.list_schemas()        
         self.iface = iface
+        self._contact_dlg = None
         self.schema_lib = None
         self.user_conf = {}
         
@@ -53,10 +54,7 @@ class DlgMain(QtWidgets.QDialog):
         
         self.ui.btn_run.setIcon(QIcon(RSCDIR / "play.png"))
         self.ui.btn_run.clicked.connect(self.run)
-        
-        self.ui.btn_help.setIcon(QIcon(RSCDIR / "question.png"))
-        self.ui.btn_help.clicked.connect(self.show_help)
-        
+
         self.ui.btn_contact.clicked.connect(self.show_contact)
 
         for i, schema_name in enumerate(self.available_schemas):
@@ -259,12 +257,13 @@ class DlgMain(QtWidgets.QDialog):
         layer.select(feature.id())
         
     def show_contact(self):
-        dlg = DlgContact()
-        dlg.show()
-        dlg.exec_()
-    
-    def show_help(self):
-        pass
+        try:
+            self._contact_dlg.close()
+        except:
+            pass
+        self._contact_dlg = DlgContact()
+        self._contact_dlg.show()
+        self._contact_dlg.exec_()
     
     def store_config(self):
         user_conf = mncheck.get_user_data()

+ 10 - 53
ui/dlg_main.ui

@@ -6,7 +6,7 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>532</width>
+    <width>477</width>
     <height>537</height>
    </rect>
   </property>
@@ -24,58 +24,6 @@
     <normaloff>rsc/network.png</normaloff>rsc/network.png</iconset>
   </property>
   <layout class="QVBoxLayout" name="verticalLayout">
-   <item>
-    <layout class="QHBoxLayout" name="horizontalLayout">
-     <property name="topMargin">
-      <number>0</number>
-     </property>
-     <item>
-      <widget class="QLabel" name="label">
-       <property name="text">
-        <string>Sélectionnez le schéma à appliquer:</string>
-       </property>
-      </widget>
-     </item>
-     <item>
-      <spacer name="horizontalSpacer">
-       <property name="orientation">
-        <enum>Qt::Horizontal</enum>
-       </property>
-       <property name="sizeHint" stdset="0">
-        <size>
-         <width>40</width>
-         <height>20</height>
-        </size>
-       </property>
-      </spacer>
-     </item>
-     <item>
-      <widget class="QPushButton" name="btn_help">
-       <property name="enabled">
-        <bool>false</bool>
-       </property>
-       <property name="minimumSize">
-        <size>
-         <width>28</width>
-         <height>28</height>
-        </size>
-       </property>
-       <property name="font">
-        <font>
-         <pointsize>9</pointsize>
-        </font>
-       </property>
-       <property name="text">
-        <string/>
-       </property>
-       <property name="icon">
-        <iconset>
-         <normaloff>rsc/question.png</normaloff>rsc/question.png</iconset>
-       </property>
-      </widget>
-     </item>
-    </layout>
-   </item>
    <item>
     <layout class="QHBoxLayout" name="horizontalLayout_2">
      <property name="leftMargin">
@@ -92,6 +40,9 @@
          <height>30</height>
         </size>
        </property>
+       <property name="toolTip">
+        <string>Schéma de contrôle à utiliser pour les tests</string>
+       </property>
       </widget>
      </item>
      <item>
@@ -102,6 +53,9 @@
          <height>32</height>
         </size>
        </property>
+       <property name="toolTip">
+        <string>Lancer les tests</string>
+       </property>
        <property name="text">
         <string/>
        </property>
@@ -230,6 +184,9 @@
          <underline>true</underline>
         </font>
        </property>
+       <property name="toolTip">
+        <string/>
+       </property>
        <property name="text">
         <string>Signaler un problème ou suggérer une amélioration</string>
        </property>